Skip to content

Commit

Permalink
Untie ConsumerRebalanceListener
Browse files Browse the repository at this point in the history
  • Loading branch information
ods committed Oct 22, 2023
1 parent c2041d9 commit ee1f564
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 1,472 deletions.
3 changes: 1 addition & 2 deletions aiokafka/abc.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import abc
from kafka import ConsumerRebalanceListener as BaseConsumerRebalanceListener


class ConsumerRebalanceListener(BaseConsumerRebalanceListener):
class ConsumerRebalanceListener(abc.ABC):
"""
A callback interface that the user can implement to trigger custom actions
when the set of partitions assigned to the consumer changes.
Expand Down
1 change: 0 additions & 1 deletion kafka/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ def emit(self, record):

from kafka.admin import KafkaAdminClient
from kafka.client_async import KafkaClient
from kafka.consumer.subscription_state import ConsumerRebalanceListener
from kafka.conn import BrokerConnection
from kafka.serializer import Serializer, Deserializer
from kafka.structs import TopicPartition, OffsetAndMetadata
Expand Down
Empty file removed kafka/consumer/__init__.py
Empty file.
501 changes: 0 additions & 501 deletions kafka/consumer/subscription_state.py

This file was deleted.

1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ exclude =
venv
__pycache__
.tox
tests/kafka/

[isort]
line_length=88
Expand Down
8 changes: 0 additions & 8 deletions tests/kafka/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,6 @@ def factory(**broker_params):
broker.close()


@pytest.fixture
def kafka_client(kafka_broker, request):
"""Return a KafkaClient fixture"""
(client,) = kafka_broker.get_clients(cnt=1, client_id='%s_client' % (request.node.name,))
yield client
client.close()


@pytest.fixture
def kafka_consumer(kafka_consumer_factory):
"""Return a KafkaConsumer fixture"""
Expand Down
297 changes: 0 additions & 297 deletions tests/kafka/test_consumer_integration.py

This file was deleted.

Loading

0 comments on commit ee1f564

Please sign in to comment.