Skip to content

Fix failing die with dignity test#77373

Merged
jasontedor merged 1 commit intoelastic:masterfrom
jasontedor:fix-test-die-with-dignity-test
Sep 8, 2021
Merged

Fix failing die with dignity test#77373
jasontedor merged 1 commit intoelastic:masterfrom
jasontedor:fix-test-die-with-dignity-test

Conversation

@jasontedor
Copy link
Copy Markdown
Member

This test sometimes spuriously fails because we are looking for a specific string in the command line, but jps truncates the output to 1024 characters. Sometimes, the string we are looking for is beyond 1024 characters in the command line. This commit changes the tactic, to instead use jcmd to find the command line of all running JVMs on the machine, and then look for the specific string there. This circumvents the truncation issue.

Closes #77282

This test sometimes spuriously fails because we are looking for a
specific string in the command line, but jps truncates the output to
1024 characters. Sometimes, the string we are looking for is beyond 1024
characters in the command line. This commit changes the tactic, to
instead use jcmd to find the command line of all running JVMs on the
machine, and then look for the specific string there. This circumvents
the truncation issue.
@jasontedor jasontedor added :Core/Infra/Core Core issues without another label >test-failure Triaged test failures from CI v8.0.0 v7.16.0 labels Sep 7, 2021
@elasticmachine elasticmachine added the Team:Core/Infra Meta label for core/infra team label Sep 7, 2021
@elasticmachine
Copy link
Copy Markdown
Collaborator

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

Copy link
Copy Markdown
Contributor

@AthenaEryma AthenaEryma 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 for digging in and fixing!

@AthenaEryma
Copy link
Copy Markdown
Contributor

Just saw #77385, that'll teach me to refresh the page for comments before reviewing. I don't have strong opinions about which approach we should take.

@jasontedor jasontedor merged commit d5ccfea into elastic:master Sep 8, 2021
jasontedor added a commit that referenced this pull request Sep 8, 2021
This test sometimes spuriously fails because we are looking for a
specific string in the command line, but jps truncates the output to
1024 characters. Sometimes, the string we are looking for is beyond 1024
characters in the command line. This commit changes the tactic, to
instead use jcmd to find the command line of all running JVMs on the
machine, and then look for the specific string there. This circumvents
the truncation issue.
@jasontedor jasontedor deleted the fix-test-die-with-dignity-test branch September 8, 2021 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Core/Infra/Core Core issues without another label Team:Core/Infra Meta label for core/infra team >test-failure Triaged test failures from CI v7.16.0 v8.0.0-alpha2

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DieWithDignityIT.testDieWithDignity failures on CI

5 participants