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

Call close on KafkaApplication only once #275

Merged
merged 2 commits into from
Jan 23, 2025
Merged

Conversation

philipp94831
Copy link
Member

Fixes #263

@philipp94831 philipp94831 self-assigned this Jan 22, 2025
Copy link
Contributor

@torbsto torbsto left a comment

Choose a reason for hiding this comment

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

I think a test would be helpful to ensure it is called only once

@philipp94831
Copy link
Member Author

I think a test would be helpful to ensure it is called only once

I tried, the problem is that the shutdown hook is not invoked in the tests. We avoid system.exit with a junit plugin but this also avoids the shutdown hook. If we allow system.exit, Gradle tests are aborted

@philipp94831 philipp94831 merged commit 09360ef into master Jan 23, 2025
15 checks passed
@philipp94831 philipp94831 deleted the fix/close-once branch January 23, 2025 08:00
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.

Close method is called twice on shutdown
2 participants