-
Notifications
You must be signed in to change notification settings - Fork 24.7k
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
[TEST] Fix staleness in fetching component templates #93321
Conversation
Result from the API call seems behind the most recent state. This change adds a retry of the call to ensure we fetch the most recent state.
Pinging @elastic/es-core-infra (Team:Core/Infra) |
response.indexTemplates().keySet().stream().collect(Collectors.toSet()), | ||
containsInAnyOrder("template_1", "template_2", "template_other") | ||
); | ||
}, 60L, TimeUnit.SECONDS); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From direct conversation: Can we wait for the appropriate metadata version? The issue, as ya mentioned in conversation, is GetComposableIndexTemplate
may be stale.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing the test, nice job.
Thanks Stu! |
💚 Backport successful
|
Result from the API call seems behind the most recent state. This change changes how we fetch the templates to ensure we use the most recent metadata version.
Based on the server logs we did write the index and component templates as we should've, but the API call made doesn't find them occasionally. I believe this is because the state hasn't propagated fully so we should retry the API call for a bit.
From the logs:
Closes #93202