Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove some unused functions #14145

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,6 @@ def kafka_client(self):
)
return self._kafka_client

def create_kafka_admin_client(self):
raise NotImplementedError

def get_consumer_offsets_dict(self):
return self._consumer_offsets

Expand Down Expand Up @@ -68,7 +65,6 @@ def reset_offsets(self):
self._highwater_offsets = {}

def get_partitions_for_topic(self, topic):

try:
cluster_metadata = self.kafka_client.list_topics(topic, timeout=self.config._request_timeout_ms / 1000)
topic_metadata = cluster_metadata.topics[topic]
Expand Down Expand Up @@ -195,6 +191,3 @@ def _get_topic_partitions(self, topics, consumer_group):
topic_partitions.append(TopicPartition(topic, partition))

return topic_partitions

def get_broker_offset(self):
raise NotImplementedError
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,3 @@ def get_consumer_offsets_dict(self):
return self.python_kafka_client.get_consumer_offsets_dict()
return self.confluent_kafka_client.get_consumer_offsets_dict()

def create_kafka_admin_client(self):
# TODO when this method is implemented in ConfluentKafkaClient, replace this with:
# if self.use_legacy_client:
# return self.python_kafka_client.get_consumer_offsets()
# return self.confluent_kafka_client.get_consumer_offsets()

return self.python_kafka_client.create_kafka_admin_client()
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ def __init__(self, config, tls_context, log) -> None:
self._consumer_offsets = {}
self._tls_context = tls_context

@abstractmethod
def create_kafka_admin_client(self):
pass

@abstractmethod
def get_consumer_offsets(self):
Expand Down