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

Enable debug logging in FileSettingsRoleMappingsStartupIT #99247

Merged

Conversation

pgomulka
Copy link
Contributor

@pgomulka pgomulka commented Sep 6, 2023

investigating failing tests

relates #98391

  • Have you signed the contributor license agreement?
  • Have you followed the contributor guidelines?
  • If submitting code, have you built your formula locally prior to submission with gradle check?
  • If submitting code, is your pull request against main? Unless there is a good reason otherwise, we prefer pull requests against main and will backport as needed.
  • If submitting code, have you checked that your submission is for an OS and architecture that we support?
  • If you are submitting this code for a class then read our policy for that.

@pgomulka pgomulka self-assigned this Sep 6, 2023
@pgomulka pgomulka added >test Issues or PRs that are addressing/adding tests :Core/Infra/Settings Settings infrastructure and APIs labels Sep 6, 2023
@elasticsearchmachine elasticsearchmachine added v8.11.0 Team:Core/Infra Meta label for core/infra team labels Sep 6, 2023
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (Team:Core/Infra)

Copy link
Member

@rjernst rjernst left a comment

Choose a reason for hiding this comment

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

Looks fine but I have one suggestion

@@ -73,6 +74,10 @@ protected Path nodeConfigPath(int nodeOrdinal) {
return null;
}

public void setupLogging() {
updateClusterSettings(Settings.builder().put("logger.org.elasticsearch.common.file", "DEBUG"));
Copy link
Member

Choose a reason for hiding this comment

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

An alternative way of enabling test logging you might consider is using the TestLogging annotation (on the test method):

@TestLogging(value = "org.elasticsearch.common.file:DEBUG", reason = "https://github.com/elastic/elasticsearch/issues/98391")

Copy link
Contributor Author

Choose a reason for hiding this comment

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

good hint. changed to used @testlogging

@pgomulka pgomulka merged commit f5871af into elastic:main Sep 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Settings Settings infrastructure and APIs Team:Core/Infra Meta label for core/infra team >test Issues or PRs that are addressing/adding tests v8.11.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants