{"repo":"nasa-gcn/gcn-kafka-python","free":true,"listed":false,"github":"https://github.com/nasa-gcn/gcn-kafka-python","clone":"git clone https://github.com/nasa-gcn/gcn-kafka-python.git","description":"Official Python client for the General Coordinates Network (GCN)","language":"Python","stars":13,"topics":["astronomy","kafka","python"],"license":"CC0-1.0","category":"data-pipelines","readme_excerpt":"GCN Kafka Client for Python This is the official Python client for the General Coordinates Network (GCN). It is a very lightweight wrapper around confluent-kafka-python. To Install Run this command to install with pip: or this command to install with with conda: To Use Create a consumer. List all topics: Subscribe to topics and receive alerts: The timeout argument to consume() , given as an integer number of seconds, will allow the program to exit quickly once it has reached the end of the existing message buffer. This is useful for users who just want to recover an older message from the stream. timeout will also make the while True infinite loop interruptible via the standard ctrl-c key sequence, which consume() ignores. Testing and Development Kafka Clusters GCN has three Kafka clusters: production, testing, and an internal development deployment. Use the optional domain keyword argument to select which broker to connect to. FAQ How can I keep track of the last read message when restarting a client? A key feature of kafka consumer clients is the ability to perform persistent tracking of which messages have been read. This allows clients to recover missed messages after a restart by beginning at the earliest unread message rather than the next available message from the stream. In order to enable this feature, you will need to set a client Group ID using the configuration dictionary argument for the Consumer class as well as change the auto offset reset option to the ‘earli","default_branch":null,"files":null,"tree":[],"storefront":"/r/nasa-gcn","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/nasa-gcn/gcn-kafka-python/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}