-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Description
Library name and version
com.azure:azure-messaging-eventhubs:5.21.1
Query/Question
How can I manage my receivers per partitions via the SDK? I was developing and accidentally created too many receivers. After doing research, I know that I need to refactor my code to reuse my connection and not create one over and over. But how do I go back and delete the connections I have already made or reuse one that I already made. I cannot continue development because I get the following error:
com.azure.core.amqp.exception.AmqpException: Exceeded the maximum number of allowed receivers per partition in a consumer group which is 5. List of connected receivers
My connection code.
new EventHubClientBuilder().connectionString(connectionString).consumerGroup(EventHubClientBuilder.DEFAULT_CONSUMER_GROUP_NAME).buildAsyncConsumerClient();
Again, I get that I did it wrong, and I will fix my code. But I have not found anywhere in the Azure documentation on how to delete a connection, or reuse a connection with a receiver ID.
Thanks.
Environment
Android, Java.