Parsely/pykafka

SASL Support

Open

#651 建立於 2017年1月27日

在 GitHub 查看
 (11 留言) (1 反應) (0 負責人)Python (1,114 star) (231 fork)batch import
enhancementhelp wanted

描述

I would like to use pykafka to connect to IBM Bluemix Message Hub with is a Kafka implementation. There is a kafka-python example in this thread. https://stackoverflow.com/questions/35294949/can-i-call-the-bluemix-message-hub-service-from-python/40325181#40325181

I also found this for confluent-kafka:

A new Python client

Confluent, the company founded by the creators of Kafka, has released a Python client (https://github.com/confluentinc/confluent-kafka-python). It is built as a thin bindings layer on top of librdkafka and works for both Python 2 and 3.

To use with Message Hub, simply pass these properties in when creating a Producer/Consumer:

'ssl.ca.location': '/etc/ssl/certs/',
'sasl.mechanisms': 'PLAIN',
'sasl.username': '<USER>',
'sasl.password': '<PASSWORD>',
'security.protocol': 'sasl_ssl'

Note: The value of ‘ssl.ca.location depends’ on your operating system. For example:

Ubuntu: /etc/ssl/certs/
RedHat: /etc/pki/tls/cert.pem
OS X: select system root certificates from Keychain Access and export as .pem on the filesystem.

Is there a way to connect using pykafka? If so, how would I do it?

貢獻者指南

SASL Support · Parsely/pykafka#651 | Good First Issue