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

The kafka server is not stable. #2

Open
b1ueseanoah opened this issue Nov 22, 2023 · 1 comment
Open

The kafka server is not stable. #2

b1ueseanoah opened this issue Nov 22, 2023 · 1 comment

Comments

@b1ueseanoah
Copy link
Collaborator

The kafka server is not stable. Most of the reasons are because topics are maintained that have not been deleted after use.
It will probably be resolved soon.

@b1ueseanoah
Copy link
Collaborator Author

It will be removed through the corresponding source.

def delete_topic(self,topic_name, timeout = 1000):
delete_topics = [topic_name]
try:
# delete_topic
self.admin_client.delete_topics(topics=delete_topics,timeout_ms=timeout)
print(f"topic'{topic_name}' is deleted")
self.get_all_topics_info()
except UnknownTopicOrPartitionError:
print(f"topic '{topic_name}' is not exist.")
except Exception as e:
print(f"Error deleting topic: {e}")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant