Revision history for Perl extension Asterisk::AMI.
0.2.1 - Fixed some errors in the documentation
- Fixed a bug where we would leave an empty value in callbacks on a get_response if the response was already in the
buffer. Only error message for this happend once the Asterisk::AMI object went away and attempted to flush all
pending callbacks.
- Require AnyEvent 5.2 or newer, as a feature we rely on was introduced in that release. Note, I have only tested as far back
as version 5.26.
0.2.0
- Added new syntax for using callbacks with the send_action method. Old syntax still works.
Check documentation for this method for more details.
- Changed method of parsing from a regex to a simple split. This was possible due to previous
changes in the order that we parsed input. Results are more accurate parsing and better performance.
- Removed the need for the 'DATA' key due to above parsing improvements. All input now creates a key
in the appropriate hash.
- Manager lines with empty values ( e.g. 'Account: ' in an event) are no longer placed
in 'DATA' and are instead parsed properly and contain the null string as a value ( test for '' ).
- Added documentation examples for the Originate Action
- Update documenation
- Switch to the Artistic License 2
- Improved Package for CPAN, META.yml now included
0.1.10
- Added exception for the 'Originate' command while using the 'Async' option.
- Added option 'OriginateHack', which makes changes to allow using the 'Originate' action with the 'Async'
option.
- Added new subroutine 'loop', calls an event loop via AnyEvent.
0.1.9
- Fixed a bug when the cli command 'database show' was used with a small asterisk database (single entry)
that would cause the response to not be parsed correctly, causing it to never complete. Also affected
AMI::Common::db_show();
- Fixing some of our OO implementation to make it more correct and to properly isolate seperate
instances of our object from each other
- Now after calling destroy() any further calls to methods on that object will simple fail
- Optimized the regex and method used for splitting 'Action: Command' output
- Cleaned up some logic in a few subroutines
- Fixed some more typos in the documentation
0.1.8
- Added support for 'MD5' challenge authenticaiton
- Added SSL support
- Internal changes to how we keep track of active actions
- Fixed some bad grammar/spelling/typos in documentation,
most likely added a few more as well
0.1.7
- Removed Asterisk::AMI::completed(). Seemed pointless with callbacks.
- Added TCP_Keepalive option, enables socket level TCP keepalive for detecting dead connections.
- Fixed possible undefined value for timeout when sending a keepalive.
- We were being a bit overzealous when we encounted an error on the socket (during connect or otherwise).
We now callback any outstanding actions (as if they had timed out) before we issue the on_error callbacks
and do internal cleanup. This bug was causing the a hang during login if a socket connection could not
be made.
- Fixed a bug with older version of ExtUtils::MakeMaker
- Fix to properly us \v when perl >=5.10, we were only doing it when perl >5.10. This only affects performance.
- 'Keepalive' was not being set if Blocking was set to 1. Now 'Keepalive' is always set if configured,
it just may not be helpful if you are not running an event loop.
- Updated Dependancy to AnyEvent version 5.0 or greater
- Switch to AE interface for AnyEvent for timers and condvars. Lowers overhead when using alot of timers.
- Some general code cleanups
0.1.6
- Fixes calling wrong modules (leftover from name change)
- Adds backwards compatability for perl 5.8
0.1.5
- Bad test, which broken installing from cpan
0.1.4
- Changed namespace from AMI to Asterisk::AMI
- Massive Internal changes. Entire core re-written to use AnyEvent. This module is still usuable without an event loop, but now can integrate
easily into any event loop supported by AnyEvent.
- Out put from cli commands (from issueing Action: Command) is now placed in $response->{'CMD'}.
As a bonus from rewriting how we parse packets (to work with anyevent) we can now very easily identify all lines
associated with command output.
- Object is no longer also a filehandle. No longer required because of the use of AnyEvent
- Event handling from AMI::Event merged into Core.
- Add more advance options for error handling, check the documentation for the constructor.
- Removed number of 'useless' functions. You should check the documentation.
- Fixed a memory 'leak' (total consumtion was still capped by our ring buffer) that could happen when many responses were timeing out.
Essentially we were still buffering the subsequent packets even if they action had already timed out. Now we properly discard them.
- AMI::get_action is now AMI::get_response. Behavior is the same, only the name has changed.
- Re-wrote event_proxy.pl example to utilize the new integration with AnyEvent.
- New example server called 'cmd_server.pl' which allows for a few basic commands. It demonstrates the use of callbacks.
0.1.3
- Changed version requirements from 5.10 to 5.8. Those running 5.8 may need to install the 'version' and 'parent'
pragmas. (install version and install parent in cpan).
- Now using "\015\012" as the end of line delimiter, more portable and better practice than "\r\n"
- AMI::Common::channels() was not accepting timeouts
- Changed AMI::Common::channels() to use the status command, which has changed the information it returns (more is better).
- New key {'GOOD'} added to the Response Obj. It is 1 when an object is complete and had no errors and 0 if it
had an error or never finished. Should make it very easy to check if a response is usuable.
- AMI::check_response() now also removes the action from the buffer
- We were not properly returning undef on error for several AMI::Common functions. These should now properly
return undef if the action failed.
- Added Callbacks on for Actions to core AMI, read the documentation for more information.
- New code example 'cmd_server.pl', a simple server, gives examples on how to use callbacks.
- New Module AMI::Common:Dev contains additional functions for working with Asterisk 1.6+
0.1.2
- All AMI Objects can now also be used a normal IO Handles. It is not recommended
that you read and write directly to them. This was added so you can add the AMI
object to something like IO::Select for single threaded server applications
- New module AMI::Common::Dev, which is currently empty. This will be where new functions
specific to Asterisk 1.6+ will go. When the next LTS of Asterisk is released these will then
be merged back into AMI::Common and new functions will be added here.
- Cleaned up option handling
- Fixed a bug in reading packets that could lead to 100% cpu usage when
a remote end disconnected.
- action() and get_action now return the response so long as the action completed
and undef if an error happened or if it timed out.
- check_response() and simple_action now return 0 on a failure, 1 on success, and
undef on error or timeout.
- get_event() now returns undef on error or timeout.
- send_action now returns undef on error.
- The above changes filter through to many AMI::Common functions as well.
(If you get undef you should check the connection.)
- check_connection changed to connected()
- New Method process_packet(). Tells AMI to process input from asterisk.
- 'EventPreempt' changed to 'FastEvents', behavior changed to immeditly proccess any events
after processing a packet.
- Added 'Timeout' option to constructor. Allows setting a default timeout on function calls.
- Removed AutoAge and AutoClear settings and added 'BufferSize', which is the max number of Actions to hold
in memory. We basically use a ring buffer now for actions. Default is 30000.
- Fixed a bug in AMI::Common where we were accidnetly using the channel name for positions for Queue Entries
- Added AMI::Common::play_digits() which plays a series of DTMF tones on a channel.
- Restructued the logic for sorting events and responses
- Added key 'Handlers' to AMI::Events constructor which accepts a hash containing event handlers
- Removed AMI::Events::event_mask() and AMI::Events::handlers(), instead use the constructor.
- Events are now discarded if they are not enabled at object creation. (If you don't set 'Events' to something
other than 'off' then we will discard any events not associated with an action that we get in for that object)
- Useing AMI::Common or AMI::Common::Dev before AMI::Events will allow the AMI::Events object to use the methods
in AMI::Common or AMI::Common:Dev
- Various other code cleanups
0.1.1 Thu Jan 27 2010
- Initial Release