Piotr Kliczewski has uploaded a new change for review.

Change subject: asyncore: remove misleading log entry
......................................................................

asyncore: remove misleading log entry

From time to time I can see misleading warning in the logs:

betterAsyncore::144::vds.dispatcher::(log_info) unhandled close event

In order to get rid of it we make sure that we handle close event for
all the dispatchers that we have and we call close on dispatcher.


Change-Id: Ib35eb35c7ffe52b090c329136041bc21694fbdaf
Signed-off-by: pkliczewski <piotr.kliczew...@gmail.com>
---
M lib/vdsm/sslutils.py
M vdsm/protocoldetector.py
2 files changed, 9 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/75/48375/1

diff --git a/lib/vdsm/sslutils.py b/lib/vdsm/sslutils.py
index 443ae8c..3b52a81 100644
--- a/lib/vdsm/sslutils.py
+++ b/lib/vdsm/sslutils.py
@@ -297,6 +297,9 @@
             self.want_read = self.want_write = True
             self._is_handshaking = False
 
+    def handle_close(self, dispatcher):
+        dispatcher.close()
+
 
 def create_ssl_context():
         sslctx = None
diff --git a/vdsm/protocoldetector.py b/vdsm/protocoldetector.py
index 0bcc7a6..af7818d 100644
--- a/vdsm/protocoldetector.py
+++ b/vdsm/protocoldetector.py
@@ -72,6 +72,9 @@
                           *client.getpeername())
             self._dispatcher_factory(client)
 
+    def handle_close(self, dispatcher):
+        dispatcher.close()
+
 
 class _ProtocolDetector(object):
     log = logging.getLogger("ProtocolDetector.Detector")
@@ -128,6 +131,9 @@
     def has_expired(self):
         return monotonic_time() >= self._give_up_at
 
+    def handle_close(self, dispatcher):
+        dispatcher.close()
+
 
 class MultiProtocolAcceptor:
     """


-- 
To view, visit https://gerrit.ovirt.org/48375
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib35eb35c7ffe52b090c329136041bc21694fbdaf
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Piotr Kliczewski <piotr.kliczew...@gmail.com>
_______________________________________________
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to