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

[Service Bus extension] ServiceBusScalerProvider does not clean up resources #37713

Open
JoshLove-msft opened this issue Jul 18, 2023 · 0 comments
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. Functions

Comments

@JoshLove-msft
Copy link
Member

The ServiceBusScalerProvider constructs a ServiceBusClient and ServiceBusReceiver and passes these into ServiceBusTargetScaler.
ServiceBusTargetScaler passes these into ServiceBusMetricsProvider where the receiver is used periodically to peek messages from the queue. There are no lifecycle methods on the ServiceBusScalerProvider and the ServiceBusClient never gets closed. This leads to test failures like https://dev.azure.com/azure-sdk/internal/_build/results?buildId=2928991&view=ms.vss-test-web.build-test-results-tab&runId=42025520&resultId=101117&paneView=debug. There should be a method that is called as part of the ServiceBusScalerProvider lifetime that allows it to be cleaned up.

The ServiceBusTargetScaler also is added via the ServiceBusListener, but this is not a problem as the underlying ServiceBusClient is closed when the ServiceBusListener is closed.

@JoshLove-msft JoshLove-msft added Service Bus Client This issue points to a problem in the data-plane of the library. Functions labels Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Client This issue points to a problem in the data-plane of the library. Functions
Projects
None yet
Development

No branches or pull requests

3 participants