Switch branches/tags
Find file
Fetching contributors…
Cannot retrieve contributors at this time
115 lines (103 sloc) 5.45 KB
== 0.5.1 / 2011-05-03
* Added Reactor#oneshot_timer_at for scheduling a timer to fire at
an exact time.
* Changed Reactor#next_tick to use #shift instead of #pop for running
blocks. Originally it was running the blocks in the reverse order
that #next_tick was called. Blocks are now run in the *same* order
as they were created by a call to #next_tick.
* Added a timestamp to all messages created using Reactor#log.
== 0.5.0 / 2011-03-3
* Changed the constructor for the ZM::Reactor class. It now takes
an optional third hash argument. One of the keys that it uses
is :zeromq_context. This allows a user to create a master 0mq
context and share it with multiple reactors. The point of that is
to allow the use of the :inproc transport. That transport is
somewhat misnamed since it only allows "inprocess" communication
between sockets created by the same context. I needed :inproc to
work around a 0mq memory leak (still unfixed) and discovered this
A second key is :log_transport which is used by the logging
In the future, the first two arguments to ZM::Reactor will likely
be rolled into the hash argument. That will be a backwards-
incompatible change, so I'm hoping folks read these notes and
start preparing.
* Many fixes to ZM::Timers. Cancellation is more intelligent about
matching timers. Inspection of timers also provides better detail
about their contents. Lastly, expired timer removal is much clearer
in how it functions *and* it is faster by an order of magnitude.
(Note: Array#shift is *way faster* than Array#delete_at(0)).
* Timer expiration has changed. Originally, timers fired only when
the current time was *greater than* its firing time. Now timers
fire when the current time is *greater than or equal to* its firing
* Modified how arguments are passed to the Forwarder and Queue
* Devices now default to a ZMQ::LINGER of 0 (drop messages
immediately upon socket close) and a ZMQ::HWM of 1 (only allow
1 outstanding message between senders and receivers). These
parameters can be modified using the new argument hash.
* ZM::Address now supports the :inproc transport.
* Fixed a memory leak where a message was not released when an
internal recv operation returned EAGAIN. The code was leaking an
empty ZMQ::Message every time.
* Added a facility for logging. When a Reactor is instantiated a
user may pass in a transport string that indicates where the
reactor may *connect* and publish log messages. Part of the
contract is that this transport already has a listener bound
to it before the connection is attempted (e.g. for inproc
transports). If inproc is used, then the user also needs to
pass in the shared context via :zeromq_context.
* Fixed a bug in Socket#send_messages where EAGAIN was not always
properly detected and bubbled up to its caller.
* Refactored socket deletion. Hopefully it is easier to understand.
== 0.4.1 / Unreleased
== 0.4.0 / 2010-12-16
* Replaced SortedSet in Timers with an Array and a custom routine
for finding the in-order index for an insert. The routine
uses a binary search algo so it can find the proper index in
O(nlog n) time. This resulted in a 2 order of magnitude perf
increase when using more than a handful of timers.
* Modified the default reactor poll interval to 10ms from 100usec.
Also, fixed the poll routine so that it sleeps for poll_interval
when there are no procs scheduled and there are no sockets
registered. With no sockets, the call to Poller#poll returns
immediately. This was showing as a busy loop and pushing CPU
to 100% for some users.
With this change, timers now have a minimum *default* resolution
of 10 milliseconds. The poll interval can be overridden and set to
a minimum of 1ms for better timing controls.
== 0.3.2 / 2010-08-25
* Fixed a bug in Timers where the timers were never getting removed
after they fired. Bug was caused by a Ruby bug with #delete_if. While
deleting each fired timer, the delete_if loop was exited early via
a call to #break as an optimization. The #break caused all deletes to
be ignored.
See bug
* Minor fixes to the ping-pong examples. Was missing some calls to
register/deregister for read/write events. The socket semantics have
changed since earlier revisions; those changes didn't get caught until
== 0.3.1 / 2010-08-16
* Forgot to load the xreq/xrep files during startup
* Added support for resetting a timer's firing schedule. Useful for when
the time source has been overridden; let's existing timers
reschedule themselves using the new time source.
* Fixed a logic bug with delivery of multi-part messages
== 0.3.0 / 2010-08-15
* Added XREQ/XREP socket types
* Moved the time functions for ZM::Timers into a pair of
class methods. Instead of accessing Time directly, it should
be accessed via and ZM::Timers.now_converted.
Doing so allows the programmer to reopen the ZM::Timers class and
redefine how time is procured if necessary (e.g. every second of
wall clock time should translate to 1 minute of time inside the
* Still needs specs!
== 0.2.0 / 2010-06-06
* Updated internals to conform to the 0mq api as of
release 2.0.7.
* Minor api enhancements.
== 0.1.0 / 2010-06-02
* 1 major enhancement
* Birthday!