BIND 10 #852: boost::msgq as possible replacement of MSGQ

BIND 10 Development do-not-reply at isc.org
Thu Apr 14 10:35:42 UTC 2011


#852: boost::msgq as possible replacement of MSGQ
-------------------------------------+-------------------------------------
                 Reporter:  vorner   |                Owner:  UnAssigned
                     Type:  task     |               Status:  reviewing
                 Priority:  major    |            Milestone:
                Component:           |           Resolution:
  Unclassified                       |            Sensitive:  0
                 Keywords:           |  Add Hours to Ticket:  0
Estimated Number of Hours:  0.0      |          Total Hours:  0
                Billable?:  1        |
                Internal?:  0        |
-------------------------------------+-------------------------------------
Changes (by vorner):

 * owner:  vorner => UnAssigned
 * status:  new => reviewing


Comment:

 Hello

 I can't find anything else than just `boost::interprocess::message_queue`.
 `boost::msgq` seems not to exist.

 And the `message_queue` seems to be something different than what we need.
 It allows creation of a message queue that is shared between processes (it
 is in shared memory, so it has the same problem with staying there for
 ever if not deleted, etc.). Then a message can be put into it and taken
 out (with blocking/non-blocking/timeouting mode). Anybody is allowed to
 put in and to take out. The first message just falls out (it has priority,
 but no addressing).

 So, if we wanted to use it, we could rewrite our msgq using this, there
 could be a message queue for messages going into the router (msgq) and
 then one message queue for each connected process where msgq would put the
 messages for it. It could solve some of our problems (read and write of
 single message is atomic, we are told when the queue is full, etc.), but
 it would bring new ones (we need to make sure we remove the shared memory,
 if a process crashes, msgq wouldn't get a closed file descriptor, we would
 need to handle naming somehow ourself, the length of single message is
 limited (we set the limit at construction, but the maximum size is set in
 stone since then)). And we would need to write python bindings.

 The interprocess library is header only, but might need some date-time
 library that is built. It uses the mutexes which gave us some trouble.

 Some people on the forums seem to note stuff about rough edges and slight
 immaturity, but that might be older.

 So, if everything else fails, we probably should look into if we want to
 replace our sockets with this, but it's not a complete solution.

 Or, did I look at something else? Did anybody know of anything that could
 be noted as `boost::msgq`?

 Thanks

-- 
Ticket URL: <http://bind10.isc.org/ticket/852#comment:1>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list