diff options
author | David M. Lee <dlee@digium.com> | 2013-08-06 14:44:45 +0000 |
---|---|---|
committer | David M. Lee <dlee@digium.com> | 2013-08-06 14:44:45 +0000 |
commit | c79084879427750dc848834a8390bb0c8468f24b (patch) | |
tree | 2e6c4371cda2c73172642b267aa54dea469d600d /res/res_ari_recordings.c | |
parent | b97d318b7bc31b47fbd4b74421e351095f05139d (diff) |
ARI: Add recording controls
This patch implements the controls from ARI recordings. The controls
are:
* DELETE /recordings/live/{recordingName} - stop recording and
discard it
* POST /recordings/live/{recordingName}/stop - stop recording
* POST /recordings/live/{recordingName}/pause - pause recording
* POST /recordings/live/{recordingName}/unpause - resume recording
* POST /recordings/live/{recordingName}/mute - mute recording (record
silence to the file)
* POST /recordings/live/{recordingName}/unmute - unmute recording.
Since this underlying functionality did not already exist, is was
added to app.c by a set of control frames, similar to how playback
control works. The pause/mute control frames are toggles, even though
the ARI controls are idempotent, to be consistent with the playback
control frames.
(closes issue ASTERISK-22181)
Review: https://reviewboard.asterisk.org/r/2697/
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396331 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_ari_recordings.c')
-rw-r--r-- | res/res_ari_recordings.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/res/res_ari_recordings.c b/res/res_ari_recordings.c index 01ad49a65..77fc830cf 100644 --- a/res/res_ari_recordings.c +++ b/res/res_ari_recordings.c @@ -295,6 +295,7 @@ static void ast_ari_get_live_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ is_valid = 1; break; default: @@ -351,6 +352,7 @@ static void ast_ari_cancel_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ is_valid = 1; break; default: @@ -407,6 +409,7 @@ static void ast_ari_stop_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ is_valid = 1; break; default: @@ -463,6 +466,8 @@ static void ast_ari_pause_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ + case 409: /* Recording not in session */ is_valid = 1; break; default: @@ -519,6 +524,8 @@ static void ast_ari_unpause_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ + case 409: /* Recording not in session */ is_valid = 1; break; default: @@ -575,6 +582,8 @@ static void ast_ari_mute_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ + case 409: /* Recording not in session */ is_valid = 1; break; default: @@ -631,6 +640,8 @@ static void ast_ari_unmute_recording_cb( break; case 500: /* Internal Server Error */ case 501: /* Not Implemented */ + case 404: /* Recording not found */ + case 409: /* Recording not in session */ is_valid = 1; break; default: |