|Summary:||ASTERISK-09627: Responses to Manager Commands Should Be Called 'Responses' and not 'Events'|
|Date Opened:||2007-06-08 15:43:12||Date Closed:||2008-04-01 13:05:34|
|Environment:||Attachments:||( 0) ActionResponses.patch|
|Description:||In developing a new Ruby library for AMI, it became clear that separating AMI Event handling from AMI Actions by using two sockets was a good idea. With this in place, it also became evident that there are several Manager Actions which generate blocks called "Events", but which are not in fact sent to Event subscribers.|
This is because these "Event" responses are not in fact true Events (utilizing the Eventing calls) but are really a string of Responses sent to whatever user generated the matching "Action".
For this reason I propose changing these incorrectly-labeled "Event:" blocks to "Response:" blocks. This change also makes sense since objects like SipPeers are ostensibly not "Events" and are not being sent as a result of anything "happening" in the system.
Actions affected include: ZapShowChannels, SipShowPeers, Agents, VoicemailUsers, Queues, QueueStatus, WaitEvent, Status, DBGet, ListDialplan, ParkedCalls
|Comments:||By: Russell Bryant (russell) 2007-06-08 16:07:00|
oej: This patch looks good to me. It sounds like it would be good to merge it into your "moremanager" branch, so that it is included with your other large batch of changes.
By: Brandon Kruse (bkruse) 2007-10-30 09:31:40
This looks great!
And more standardized.
By: Olle Johansson (oej) 2007-11-05 03:08:21.000-0600
Yes, this is something I've always been upset on. Naming it "Events" just doesn't make any sense.
Let's merge this into moremanager.
By: Olle Johansson (oej) 2007-11-05 08:19:35.000-0600
From the CHANGES:moremanager in the moremanager branch:
- Response: headers are now either
"Success" - Action OK, this message contains response
"Error" - Action failed, reason in Message: header
"Follows" - Action OK, response follows in following Events.
We need to define something like "Response: ListItem" and have a type indicating the type of response or something...
By: Olle Johansson (oej) 2007-12-16 03:43:23.000-0600
So do we go for
Or a new type, like
What do you think?
By: davetroy (davetroy) 2007-12-17 10:49:04.000-0600
Olle - good thought.
I am partial to to your ListItem idea. Response to begin and end and ListItem (with type, as you suggest) for stuff in between. Whatever is chosen should be transformable into XML or any other format and be relatively straightforward to parse.
By: Brandon Kruse (bkruse) 2007-12-17 16:16:45.000-0600
Either way, I am going to keep an eye on this, and pitch in, because this could potentially break the way the GUI communicates to manager.
Will try with OEJ's moremanager branch (if it has this patch in it now) along with a few other things.
Looking good, I agree with OEJ, this needed to happen.
By: Olle Johansson (oej) 2007-12-18 00:48:42.000-0600
I haven't changed the moremanager branch or trunk yet, but may do any time now.
By: Tilghman Lesher (tilghman) 2008-03-04 17:13:28.000-0600
The problem is that this destroys the nice 1:1 correspondence between Actions and Responses. The reason the Event is used is to keep a single response for each Action and generate additional information as Events.
By: Tilghman Lesher (tilghman) 2008-04-01 13:05:33
After careful consideration with other developers, we're going to close this out with no action. The reason is, it's purely a textual change, has no real benefit, and would break almost every Manager application out there for no good reason. For this, and the reasons outlined before (breaking 1:1 correspondence between Actions and Responses), we're rejecting this change.