cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
254
Views
0
Helpful
0
Comments
cdnadmin
Level 11
Level 11
This document was generated from CDN thread

Created by: Cesar Arguello on 12-07-2012 07:41:48 PM
i'm removing some session with mediasense query and optain response 2000 for each one, but if search by the session id  get all session deleted whitout any change.
 
what i'm doing wrong?

Subject: RE: Delete Pruned session
Replied by: Cesar Arguello on 18-07-2012 05:44:21 PM
To see the session i'm searching with api getSessionBySessionId

i'm doing exactly this...

search session 4ed31387d58902d1
{"responseMessage":"Success: Your request was successfully completed.","responseCode":2000,"responseBody":{"sessions":[{"sessionState":"CLOSED_NORMAL","callControllerType":"Cisco-CUCM","sessionId":"4ed31387d58902d1","urls":{"httpUrl":"http://172.30.210.19:8080/common/oramedia/mp4/4ed31387d58902d1.mp4","rtspUrl":"rtsp://172.30.210.19/archive/4ed31387d58902d1"},"sessionStartDate":1342132752692,"tracks":[{"trackStartDate":1342132752692,"trackDuration":223973,"downloadUrl":"http://172.30.210.19:8081/ExportRaw?recording=4ed31387d58902d1-TRACK1","trackNumber":1,"trackMediaType":"AUDIO","participants":[{"participantStartDate":1342132752692,"deviceRef":"201","isConference":false,"xRefCi":"33752792","participantDuration":223973,"deviceId":"ICT_DosPinos"}]},{"trackStartDate":1342132752692,"trackDuration":223973,"downloadUrl":"http://172.30.210.19:8081/ExportRaw?recording=4ed31387d58902d1-TRACK0","trackNumber":0,"trackMediaType":"AUDIO","participants":[{"participantStartDate":1342132752692,"deviceRef":"1772","isConference":false,"xRefCi":"33752797","participantDuration":223973,"deviceId":"SEP001FCA369B71"}]}],"sessionDuration":223973,"callControllerIP":"172.30.210.13"}]}}


delete session 4ed31387d58902d1
{"responseMessage":"Success: Your request was successfully completed.","responseCode":2000,"jobId":"e1b1389be7e0f7ac1ed213"}

according with job use api  getJobById
{"responseMessage":"Success: Your request was successfully completed.","responseCode":2000,"responseBody":{"jobs":[{"jobType":"BULK_SESSION_DELETE","jobDuration":53,"jobStartTime":1342645461239,"jobId":"e1b1389be7e0f7ac1ed213","jobState":"COMPLETED"}],"operationsRemaining":0,"operationsCompleted":1}}

at this point should not exist Sesion, but when is executed getSessionBySessionId session appear normally

{"responseMessage":"Success: Your request was successfully completed.","responseCode":2000,"responseBody":{"sessions":[{"sessionState":"CLOSED_NORMAL","callControllerType":"Cisco-CUCM","sessionId":"4ed31387d58902d1","urls":{"httpUrl":"http://172.30.210.19:8080/common/oramedia/mp4/4ed31387d58902d1.mp4","rtspUrl":"rtsp://172.30.210.19/archive/4ed31387d58902d1"},"sessionStartDate":1342132752692,"tracks":[{"trackStartDate":1342132752692,"trackDuration":223973,"downloadUrl":"http://172.30.210.19:8081/ExportRaw?recording=4ed31387d58902d1-TRACK1","trackNumber":1,"trackMediaType":"AUDIO","participants":[{"participantStartDate":1342132752692,"deviceRef":"201","isConference":false,"xRefCi":"33752792","participantDuration":223973,"deviceId":"ICT_DosPinos"}]},{"trackStartDate":1342132752692,"trackDuration":223973,"downloadUrl":"http://172.30.210.19:8081/ExportRaw?recording=4ed31387d58902d1-TRACK0","trackNumber":0,"trackMediaType":"AUDIO","participants":[{"participantStartDate":1342132752692,"deviceRef":"1772","isConference":false,"xRefCi":"33752797","participantDuration":223973,"deviceId":"SEP001FCA369B71"}]}],"sessionDuration":223973,"callControllerIP":"172.30.210.13"}]}}
 
 
PD:
that occur with all session including pruned sesion

Subject: RE: Delete Pruned session
Replied by: David Lender on 18-07-2012 02:41:34 PM
Does the session returned by the search show the sessionState ACTIVE or DELETED?

Subject: RE: Delete Pruned session
Replied by: Jeffrey Wolfeld on 18-07-2012 07:46:49 PM
Cesar,

Is this an automated client which is issuing the subsequent getSessonBySessionId request?  In other words, is it being requested immediately or has some time elapsed?  If you wait a minute and request the session again do you get the same result?

I'm just wondering whether it's a race condition.

Subject: RE: Delete Pruned session
Replied by: Cesar Arguello on 18-07-2012 08:03:36 PM

Cesar,

Is this an automated client which is issuing the subsequent getSessonBySessionId request?  In other words, is it being requested immediately or has some time elapsed?  If you wait a minute and request the session again do you get the same result?

I'm just wondering whether it's a race condition.




 
thanks for you reply
 
not, it's a manual process and i try to do same process some time later
 
in fact few minutes before publish this post,  try to search and session appear again
 
 
Regards...

Subject: RE: Delete Pruned session
Replied by: Mark Clark on 19-07-2012 08:38:31 PM
Cesar,
         You need to run the "getJobResult" query with the above job id. Bulk session delete was designed to delete multiple sessions in one job. However, it is also designed so that if one session fails to delete, the other ones can still go on. For that reason, the job status will always return a value of 2000 OK even if there are some sessions that failed to delete. The job response code only indicates that the job was submitted properly.

In order to see what, if any, sessions failed to delete, use the "getJobResult" query. Along with the Job information, you should get a list of job operations (In your case, it will be a list of one). Within each job operation there is a separate response code indicating the success or failure of deleting that specific session. The session id will be found in the "operation data" field.

Let us know what you find there.

Subject: RE: Delete Pruned session
Replied by: Mark Clark on 20-07-2012 02:17:56 PM
Cesar,
       The convention in our documentation is: Anything surrounded by < > is a placeholder that explains what should go in this place. It should be replaced by the real data. The < > are NOT part of the real data.

Subject: RE: Delete Pruned session
Replied by: Cesar Arguello on 20-07-2012 01:19:35 PM
Thanks Mark...

Follow your advice use api getJobResult, and found something interesting from about delete job

"Failure: Cannot find value in database."

checking delete process found my mistake
{"requestParameters": {"sessionIds": ["<4ed31387d58902d1>"]}}
that's wrong, because <> not should be included, i was do that because mediasense guide says:


{
"requestParameters": {
"sessionIds": [
"<Session ID of the recording to be deleted>",
"<Session ID of the recording to be deleted>"
]
}
}

thanks a lot...
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Quick Links