Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

220 lines (186 sloc) 10.037 kb
== 2013-01-09
* Project has been abandoned by author. Use celluloid, dcell
or celluloid-io instead.
== 0.8.1 / 2012-02-03
* Move socket close functionality into Socket::Base module.
No longer exposes internal socket structure to outside
objects. Also, sets internal raw socket to nil after closing.
This can be checked by #resume_read & #resume_write so that
we don't try to read/write to a socket that has been closed.
This can happen if we close a socket during another socket's
callback; the closed socket may have data on it that we
haven't yet processed in Reactor#poll, but by closing it we
have already determined we don't want the data.
* Add some sugar to the Socket::Sub class for adding and
removing subscription filters. We no longer default to
subscribing to *all* data when creating one of these sockets.
== 0.8.0 / 2012-01-19
* Fixed some issues so this gem is compatible with ffi-rzmq
version 0.9.5 at a minimum.
* Enforce some common-sense defaults in the Configuration
objects.
* Modify how Queue and Forwarder print their verbose output.
Uses STDERR.print now so it is 1) thread-safe, and 2) all
output is printed as a single unit. Prior to this, printing
data out could get confused because #puts is not thread-safe.
* Saves the reactor name in the thread. This is used for enforcing
that operations *all* happen on the reactor-thread. Attempts
to modify the reactor from non-reactor threads will fail
and print a warning.
* Makes sure to start the logging client from the reactor thread
to avoid race conditions at startup.
* The exception handler is now passed to Timer objects. If code
running during a timer execution throws an exception, it is
caught right away.
* Rescues *all* Exceptions now rather than just StandardError.
* Timer comparison is done via #object_id now rather than its
former methodology.
== 0.7.1 / 2011-12-9
* Updated the Devices to use a Device::Configuration instance
for configuration rather than that long method signature.
Makes all components conform to this new configuration
mechanism consistently.
* Removed responsibility for saving XREQ/XREP/DEALER/ROUTER
routing information from the Server modules. The envelope
is passed to the callback, so it's the receiver's
responsibility to save that routing information if they need
it.
* Fixed a potential bug where we could call #resume_read or
#resume_write on a nil socket. A little extra sanity checking
never hurt anyone.
* Fixed ZM::Configuration so that subclasses can still see
and set the parent class' variables when iterating over the
accessor fields. Took a while to figure out the correct
metaprogramming techniques, but I learned quite a bit about
Ruby inheritance, inheritance visibility, etc.
== 0.7.0 / 2011-10-28
* Created a class for holding Reactor and Server configurations.
This is much nicer than passing in individual args or a hash.
* Added the ZM::Servers module to make building servers a little
easier. The biggest improvement is for making servers that
utilize XREP/ROUTER sockets since the module handles the
splitting of the routing envelope messages from the body.
* Fixed a bug where a timer that raises an exception prevented
other periodical timers from renewing. Thanks to Tim
Carey-Smith for the bug report!
== 0.6.0 / 2011-10-04
* Compatibility with ffi-rzmq 0.9.0 and added some conditional
logic to support 0mq 2.1.x and 3.x APIs.
* Removed all exceptions and replaced them with return codes.
* Added :exception_handler key to Reactor#new so exceptions can
be managed by user code.
== 0.5.2 / 2011-07-21
* Added PUSH and PULL socket types. Never needed them until now.
* Added a +context+ reader to the Reactor class.
* Changed default behavior for all sockets to use ZMQ:LINGER 1
as a socket option. By default, this prevents a call to
#close from hanging forever if there are unsent messages in
queue.
* Expose #logger accessor (read-only).
* Refactored Reactor#log so that most of the work is performed in
the LogClient (tell, don't ask!).
* Added LogClient#puts so that a logger instance can be passed to
other objects who expect an IO-like object that responds to #puts.
== 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
issue.
A second key is :log_transport which is used by the logging
facility.
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
time.
* Modified how arguments are passed to the Forwarder and Queue
devices.
* 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 http://redmine.ruby-lang.org/issues/show/2545
* 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
now.
== 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 ZM::Timers.now 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
reactor).
* 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!
Jump to Line
Something went wrong with that request. Please try again.