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

Fix potential leak of endpoint clients during the initialisation of the probe #44

Merged
merged 3 commits into from
Jan 20, 2025

Conversation

geobeau
Copy link
Contributor

@geobeau geobeau commented Jan 20, 2025

it was possible to not close an endpoint when a probe failed to start. If it failed during connect or during the execution of prepareFn, it was not closed.

Also added a lot of unit testing on the scheduler

If the probe failed preparation, the driver would not be closed
and be leaked forever.
Also added more checks in the close to support closing even
if it has not been connected yet.
Add tests to ensure endpoints are properly closed
in case of failures.
Before we had 2 different paths depending on the check
now we use only one.
Also added unittest to have coverage on these functions
Copy link
Contributor

@jfwm2 jfwm2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@geobeau geobeau merged commit f0cf93c into criteo:main Jan 20, 2025
1 check passed
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

Successfully merging this pull request may close these issues.

2 participants