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(inputs.socket_listener): Fix loss of connection tracking #13056

Merged
merged 6 commits into from
May 17, 2023

Conversation

phemmer
Copy link
Contributor

@phemmer phemmer commented Apr 6, 2023

Previously if an error was encountered during socket initialization, it would return early from the setupConnection function, and skip adding the connection to the tracking list. This could cause issues later down the line.

This refactors the code so that setupConnection() only returns an error if the connection should be aborted. Otherwise messages should be written to the logger.

fixes #13051

Required for all PRs

  • Updated associated README.md. - not applicable
  • Wrote appropriate unit tests.
  • Pull request title or commits are in conventional commit format

resolves #

@telegraf-tiger telegraf-tiger bot added the fix pr to fix corresponding bug label Apr 6, 2023
@phemmer phemmer changed the title fix(inpus.socket_listener): fix loss of connection tracking fix(input.socket_listener): fix loss of connection tracking Apr 6, 2023
@phemmer phemmer force-pushed the fix-13051 branch 2 times, most recently from 041c9f1 to 8a1a567 Compare April 7, 2023 00:14
@phemmer phemmer changed the title fix(input.socket_listener): fix loss of connection tracking fix(inputs.socket_listener): fix loss of connection tracking Apr 7, 2023
Previously if an error was encountered during socket initialization, it would return early from the setupConnection function, and skip adding the connection to the tracking list. This could cause issues later down the line.

This refactors the code so that setupConnection() only returns an error if the connection should be aborted. Otherwise messages should be written to the logger.

fixes influxdata#13051
@phemmer
Copy link
Contributor Author

phemmer commented May 16, 2023

closing as I don't have time to carry this. If someone else wants to pick it up, feel free

@phemmer phemmer closed this May 16, 2023
@srebhan srebhan reopened this May 16, 2023
@srebhan srebhan changed the title fix(inputs.socket_listener): fix loss of connection tracking fix(inputs.socket_listener): Fix loss of connection tracking May 16, 2023
@srebhan srebhan added ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins labels May 16, 2023
@powersj powersj merged commit f098e5f into influxdata:master May 17, 2023
powersj pushed a commit that referenced this pull request May 22, 2023
@srebhan srebhan added this to the v1.26.3 milestone Jun 21, 2023
@powersj powersj mentioned this pull request Jun 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix pr to fix corresponding bug plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

socket_listener loses track of connections when they don't initialize properly
3 participants