Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix(input.redis_sentinel): fix sentinel and replica stats gathering #12229

Merged

Conversation

spideyfusion
Copy link
Contributor

Required for all PRs

resolves #12152


I improved the integration test by making sure the plugin gets Initialized and talks to an actual Redis Sentinel instance.

@telegraf-tiger telegraf-tiger bot added fix pr to fix corresponding bug plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins labels Nov 11, 2022
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

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

Thank you for revamping this! One comment in line. Ideally you would continue to use the testutil.Container function, so I have on place to change things when testcontainers breaks backwards comparability again. However, I think this should be ok.

Comment on lines 364 to 366
WaitingFor: wait.ForAll(
wait.ForExposedPort(),
),
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you also have this wait for the log message "Ready to accept connections" as well? I like to see both a port + log. Similar to what you already do for the sentinels.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@powersj Done. I added the additional wait condition in 79c95e8.

@powersj powersj added the waiting for response waiting for response from contributor label Nov 14, 2022
@powersj powersj self-assigned this Nov 14, 2022
@spideyfusion
Copy link
Contributor Author

Thank you for revamping this! One comment in line. Ideally you would continue to use the testutil.Container function, so I have on place to change things when testcontainers breaks backwards comparability again. However, I think this should be ok.

I added the wrapper functions in order to gain readability as I felt things were getting a bit hectic with bootstrapping three containers for this test case.

@telegraf-tiger telegraf-tiger bot removed the waiting for response waiting for response from contributor label Nov 15, 2022
@powersj powersj added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Nov 15, 2022
Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

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

Looks good to me. Thanks for the fix @spideyfusion!

@powersj powersj merged commit 61f6450 into influxdata:master Nov 16, 2022
powersj pushed a commit that referenced this pull request Nov 29, 2022
# for free to join this conversation on GitHub. Already have an account? # 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.

Replica and Sentinel stats are not gathered in redis_sentinel input plugin
3 participants