BIND 10 #2790: Lettuce tests timing & missed messages

BIND 10 Development do-not-reply at isc.org
Fri Mar 15 21:34:35 UTC 2013


#2790: Lettuce tests timing & missed messages
-------------------------------------+-------------------------------------
            Reporter:  vorner        |                        Owner:
                Type:  defect        |                       Status:  new
            Priority:  medium        |                    Milestone:
           Component:  Unclassified  |  Sprint-20130319
            Keywords:                |                   Resolution:
           Sensitive:  0             |                 CVSS Scoring:
         Sub-Project:  Core          |              Defect Severity:  N/A
Estimated Difficulty:  9             |  Feature Depending on Ticket:
         Total Hours:  0             |          Add Hours to Ticket:  0
                                     |                    Internal?:  0
-------------------------------------+-------------------------------------

Comment (by jinmei):

 Replying to [comment:13 jelte]:
 > e.g. as a very quick suggestion (no doubt I'm missing 15 error cases
 here):
 >
 > {{{
 > diff --git a/src/bin/zonemgr/zonemgr.py.in
 b/src/bin/zonemgr/zonemgr.py.in
 > index 59900c4..b85b60e 100755
 > --- a/src/bin/zonemgr/zonemgr.py.in
 > +++ b/src/bin/zonemgr/zonemgr.py.in
 > @@ -667,7 +667,14 @@ class Zonemgr:
 >          self.running = True
 >          try:
 >              while not self._shutdown_event.is_set():
 > -                self._module_cc.check_command(False)
 > +                fileno = self._module_cc.get_socket().fileno()
 > +                try:
 > +                    (reads, _, _) = select.select([fileno], [], [])
 > +                except select.error as se:
 > +                    if se.args[0] != errno.EINTR:
 > +                        raise
 > +                if fileno in reads:
 > +                    self._module_cc.check_command(True)
 >          finally:
 >              self._module_cc.send_stopping()
 > }}}

 As you probably know, technically this is not a complete solution
 because exiting from select does not guarantee all data are available.

 Also, I suspect we should still prevent `Session.recvmsg()` (and
 `sendmsg`, too, while less critical in practice) from blocking with
 an acquired lock.  Otherwise same type of locking issue can happen on
 other modules.

 But that doesn't seem to be an easy task (probably requires
 fundamental changes to the `Session` class), and that's probably why
 you suggested this point-fix patch.  If so, I think we can apply it
 for now, but I'd like to add some comments about its limitation.

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


More information about the bind10-tickets mailing list