Summary:ASTERISK-11333: [patch] VoicemailUsersList AMI action does not always send VoicemailUserEntryComplete event
Reporter:Stefan Reuter (srt)Labels:
Date Opened:2008-01-29 19:44:52.000-0600Date Closed:2008-01-30 10:51:29.000-0600
Versions:Frequency of
Environment:Attachments:( 0) voicemail_ami-11847.patch
Description:All manager actions that send their response as a series of events send a corresponding "complete" event on success.
VoicemailUsersList only sends the comlete event if there are more than 0 voicemail users. In Asterisk-Java this results in a timeout as the library does not know if events will still follow or not.
The attached patch always sends the complete event. Additionally it removes a superfluous "\r\n" in the ack message.
The patch is against trunk but the problem is also present in 1.6.0-beta1
Comments:By: Tilghman Lesher (tilghman) 2008-01-30 09:40:35.000-0600

Isn't this actually a bug in the Java library, that it does not pay attention to the response?

By: Stefan Reuter (srt) 2008-01-30 10:28:46.000-0600

The problem is that there is no general way to decide whether events will follow or not as they very across the different actions that generate responses.
Status sends "Channel status will follow"
CoreShowChannels sends "Channels will follow"
MeetmeList sends "Meetme user list will follow"
All these actions send a corresponding XXXComplete event if a success response is returned even if the there are no active channels, meetme rooms, etc.

So if there are no voicemail users we could either send an error response that can be parsed (without checking for a specific message text) or send a success message followed by a VoicemailUserEntryComplete event. As it is not really an error if there are no voicemail users and the other actions already behave this way I prefer the second option.

By: Digium Subversion (svnbot) 2008-01-30 10:51:29.000-0600

Repository: asterisk
Revision: 101269

U   trunk/apps/app_voicemail.c

r101269 | tilghman | 2008-01-30 10:51:28 -0600 (Wed, 30 Jan 2008) | 6 lines

Make the VoicemailUsersList AMI command consistent with other manager list functions.
(closes issue ASTERISK-11333)
Reported by: srt
      voicemail_ami-11847.patch uploaded by srt (license 378)