summaryrefslogtreecommitdiffstats
path: root/events
diff options
context:
space:
mode:
Diffstat (limited to 'events')
-rw-r--r--events/src/glustereventsd.py5
-rw-r--r--events/src/utils.py5
2 files changed, 8 insertions, 2 deletions
diff --git a/events/src/glustereventsd.py b/events/src/glustereventsd.py
index 32fb6c52aa9..014f5a0009d 100644
--- a/events/src/glustereventsd.py
+++ b/events/src/glustereventsd.py
@@ -13,7 +13,10 @@
from __future__ import print_function
import sys
import signal
-import SocketServer
+try:
+ import socketserver
+except ImportError:
+ import SocketServer as socketserver
import socket
from argparse import ArgumentParser, RawDescriptionHelpFormatter
diff --git a/events/src/utils.py b/events/src/utils.py
index 7d9b7b51d95..c1c0bccfe66 100644
--- a/events/src/utils.py
+++ b/events/src/utils.py
@@ -16,7 +16,10 @@ import fcntl
from errno import EBADF
from threading import Thread
import multiprocessing
-from Queue import Queue
+try:
+ from queue import Queue
+except ImportError:
+ from Queue import Queue
from datetime import datetime, timedelta
import base64
import hmac