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

De-flake TestJetStreamSuperClusterTagInducedMoveCancel #6160

Merged
merged 1 commit into from
Nov 23, 2024

Conversation

mtmk
Copy link
Contributor

@mtmk mtmk commented Nov 21, 2024

Request to cancel the move sometimes lands as the stream is being moved
and at that point there is not leader hence no response is sent back.
With this change we're retrying the request and falling back to the case
later in the test where we skip as stream move is not in progress.

Signed-off-by: Ziya Suzen ziya@synadia.com

@mtmk mtmk requested a review from a team as a code owner November 21, 2024 20:42
var cancelResp JSApiStreamUpdateResponse
require_NoError(t, json.Unmarshal(rmsg.Data, &cancelResp))
checkFor(t, 5*time.Second, 0, func() error {
Copy link
Member

Choose a reason for hiding this comment

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

Is the test reliable if you have a short interval (i.e. 100*time.Millisecond) instead of 0?

Copy link
Contributor Author

@mtmk mtmk Nov 22, 2024

Choose a reason for hiding this comment

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

it should be. let me try edit: worked fine

Request to cancel the move sometimes lands as the stream is being moved
and at that point there is not leader hence no response is sent back.
With this change we're retrying the request and falling back to the case
later in the test where we skip as stream move is not in progress.

Signed-off-by: Ziya Suzen <ziya@synadia.com>
Copy link
Member

@neilalexander neilalexander left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@derekcollison derekcollison merged commit 1a4fec8 into main Nov 23, 2024
5 checks passed
@derekcollison derekcollison deleted the mtmk/de-flake-js-test branch November 23, 2024 15:56
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.

3 participants