style: fix whitespaces
This commit is contained in:
committed by
David Arthur
parent
f833050f0a
commit
e87cddef1b
@@ -22,7 +22,7 @@ class KafkaClient(object):
|
|||||||
|
|
||||||
def __init__(self, host, port, bufsize=4096, client_id=CLIENT_ID):
|
def __init__(self, host, port, bufsize=4096, client_id=CLIENT_ID):
|
||||||
# We need one connection to bootstrap
|
# We need one connection to bootstrap
|
||||||
self.bufsize = bufsize
|
self.bufsize = bufsize
|
||||||
self.client_id = client_id
|
self.client_id = client_id
|
||||||
self.conns = { # (host, port) -> KafkaConnection
|
self.conns = { # (host, port) -> KafkaConnection
|
||||||
(host, port): KafkaConnection(host, port, bufsize)
|
(host, port): KafkaConnection(host, port, bufsize)
|
||||||
|
|||||||
@@ -69,14 +69,18 @@ class ErrorMapping(object):
|
|||||||
# Exceptions #
|
# Exceptions #
|
||||||
#################
|
#################
|
||||||
|
|
||||||
|
|
||||||
class BufferUnderflowError(Exception):
|
class BufferUnderflowError(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
class ChecksumError(Exception):
|
class ChecksumError(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
class ConsumerFetchSizeTooSmall(Exception):
|
class ConsumerFetchSizeTooSmall(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
class ConsumerNoMoreData(Exception):
|
class ConsumerNoMoreData(Exception):
|
||||||
pass
|
pass
|
||||||
|
|||||||
@@ -3,8 +3,10 @@ import socket
|
|||||||
import struct
|
import struct
|
||||||
from threading import local
|
from threading import local
|
||||||
|
|
||||||
|
|
||||||
log = logging.getLogger("kafka")
|
log = logging.getLogger("kafka")
|
||||||
|
|
||||||
|
|
||||||
class KafkaConnection(local):
|
class KafkaConnection(local):
|
||||||
"""
|
"""
|
||||||
A socket connection to a single Kafka broker
|
A socket connection to a single Kafka broker
|
||||||
|
|||||||
Reference in New Issue
Block a user