Extension:EventLogging/Python
Appearance
This page is obsolete. It is being retained for archival purposes. It may document extensions or features that are obsolete and/or no longer supported. Do not rely on the information here being up-to-date. |
Skeleton Python kafka client for stat1007
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pykafka import KafkaClient
client = KafkaClient(hosts='kafka1012.eqiad.wmnet:9092')
topic = client.topics['eventlogging_Edit']
consumer = topic.get_simple_consumer()
for message in consumer:
print message.value # or whatever