summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Arthur <mumrah@gmail.com>2012-10-02 12:20:57 -0400
committerDavid Arthur <mumrah@gmail.com>2012-10-02 12:20:57 -0400
commitc448bf367036d3a3c04ee553987da6be64820d00 (patch)
tree56d0b92f5c389251376b72901daf9d22a0caf454
parentc99d4119f2d6d0fdee38a159e1c845e42cf398b1 (diff)
downloadkafka-python-c448bf367036d3a3c04ee553987da6be64820d00.tar.gz
Renaming kafka.py to client.py
-rw-r--r--README.md5
-rw-r--r--example.py3
-rw-r--r--kafka/client.py (renamed from kafka/kafka.py)0
-rw-r--r--setup.py2
-rw-r--r--test/integration.py2
-rw-r--r--test/unit.py2
6 files changed, 9 insertions, 5 deletions
diff --git a/README.md b/README.md
index ce257f1..540fc9f 100644
--- a/README.md
+++ b/README.md
@@ -12,6 +12,10 @@ Copyright 2012, David Arthur under Apache License, v2.0. See `LICENSE`
This project is very much alpha. The API is in flux and not all the features are fully implemented.
+# Install
+
+Install with your favorite package manager
+
# Tests
## Run the unit tests
@@ -43,6 +47,7 @@ python -m test.integration
## Send a message to a topic
```python
+ from kafka.client import KafkaClient
kafka = KafkaClient("localhost", 9092)
kafka.send_messages_simple("my-topic", "some message")
kafka.close()
diff --git a/example.py b/example.py
index 286bfdb..ced32dd 100644
--- a/example.py
+++ b/example.py
@@ -1,6 +1,6 @@
import logging
-from kafka import KafkaClient, FetchRequest, ProduceRequest
+from kafka.client import KafkaClient, FetchRequest, ProduceRequest
def produce_example(kafka):
message = kafka.create_message("testing")
@@ -26,7 +26,6 @@ def main():
consume_example(kafka)
kafka.close()
-
if __name__ == "__main__":
logging.basicConfig(level=logging.DEBUG)
main()
diff --git a/kafka/kafka.py b/kafka/client.py
index 0cde87f..0cde87f 100644
--- a/kafka/kafka.py
+++ b/kafka/client.py
diff --git a/setup.py b/setup.py
index 52bf07a..722564d 100644
--- a/setup.py
+++ b/setup.py
@@ -1,7 +1,7 @@
from distutils.core import setup
setup(
- name="Kafka Python Client",
+ name="kafka-python",
version="0.1-alpha",
author="David Arthur",
author_email="mumrah@gmail.com",
diff --git a/test/integration.py b/test/integration.py
index 197f5ec..03e988e 100644
--- a/test/integration.py
+++ b/test/integration.py
@@ -11,7 +11,7 @@ from threading import Thread, Event
import time
import unittest
-from kafka.kafka import KafkaClient, ProduceRequest, FetchRequest
+from kafka.client import KafkaClient, ProduceRequest, FetchRequest
def get_open_port():
sock = socket.socket()
diff --git a/test/unit.py b/test/unit.py
index 2db0857..6ca3564 100644
--- a/test/unit.py
+++ b/test/unit.py
@@ -3,7 +3,7 @@ import random
import struct
import unittest
-from kafka.kafka import KafkaClient, ProduceRequest, FetchRequest, length_prefix_message
+from kafka.client import KafkaClient, ProduceRequest, FetchRequest, length_prefix_message
from kafka.codec import gzip_encode, gzip_decode
ITERATIONS = 1000