Skip to content

Conversation

@mzyromski-atlassian
Copy link
Contributor

…ead of all Java processes on the node

wyrzyk
wyrzyk previously approved these changes Feb 20, 2020
@mzyromski-atlassian mzyromski-atlassian force-pushed the KonradMarszalek/issue/JPERF-188-improve-stop-jira-condition branch from e0c6c0a to d110ba8 Compare February 21, 2020 12:45
@dagguh
Copy link
Contributor

dagguh commented Feb 25, 2020

This is #82 adopted by @mzyromski-atlassian to cover the CI.
CI shows, that the change introduces an infinite Bash loop, which times out:

java.lang.Exception: SSH command failed to finish in extended time (PT3M45S): SshExecutedCommand(cmd=echo SHUTDOWN | nc localhost 8005 && while pgrep -f jira; do sleep 5; done, stdout=6481
7459
6481
7459
6481
7459
6481
7459
...

/cc @KonradMarszalek

val shutdownTomcat = "echo SHUTDOWN | nc localhost 8005"
val waitForNoJavaProcess = "while ps -C java -o pid=; do sleep 5; done"
Ssh(host, connectivityPatience = 4).newConnection().use { it.safeExecute("$shutdownTomcat && $waitForNoJavaProcess", Duration.ofMinutes(3)) }
val waitForNoJiraProcess = "while pgrep -f jira; do sleep 5; done"
Copy link
Contributor

Choose a reason for hiding this comment

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

Gotta fix that infinite loop from CI

@konradmars
Copy link

It seems there are more processes with jira fragment in it's execution path in the CI. Let me improve the logging first so we can see what the processes are. Then we can narrow the pgrep query even more.

@dagguh
Copy link
Contributor

dagguh commented Feb 25, 2020

Alternatively we could read PID from the PID file.

@dagguh dagguh requested a review from a team as a code owner February 10, 2023 16:06
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.

4 participants