summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
43d40c9)
The usage of ascii encode sometimes appends an extra "/" or an
additional space. This patch replaces ascii encoding with string
encoding.
Signed-off-by: prithiv <prithiv.mohan@intel.com>
broker = "localhost:9092"
'''
broker = "localhost:9092"
'''
- If the broker URI is not set in the env, by default,
+ If the broker URI is not set in the env by default,
localhost container is taken as the host because an instance of
is already running.
'''
self.producer = kaf(
key_serializer=str.encode,
localhost container is taken as the host because an instance of
is already running.
'''
self.producer = kaf(
key_serializer=str.encode,
- value_serializer=lambda v: json.dumps(v).encode('ascii'),
+ value_serializer=lambda v: json.dumps(v).str.encode,
bootstrap_servers=broker, api_version=(0, 10))
def publish(self, key, value, topic=None):
bootstrap_servers=broker, api_version=(0, 10))
def publish(self, key, value, topic=None):