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

Archive JVM error dumps on failure #9223

Merged
merged 1 commit into from
Apr 25, 2022
Merged

Archive JVM error dumps on failure #9223

merged 1 commit into from
Apr 25, 2022

Conversation

npepinpe
Copy link
Member

Description

This PR adds an extra post step to archive JVM error dumps when the jobs have failed. This means archiving any file with the pattern hs_err_*.log produced by the job.

Archiving dump files generated by the JVM on crashes (e.g. SIGSEV, SIGBUS, etc.). This is particularly useful when dealing with native memory and running into unrecoverable crashes to get the stacktrace of the failing frame, as this is often not logged to standard out.

NOTE: the post steps are getting bigger, but there is a follow up issue to group these together.

Related issues

closes #9129

Definition of Done

Not all items need to be done depending on the issue and the pull request.

Code changes:

  • The changes are backwards compatibility with previous versions
  • If it fixes a bug then PRs are created to backport the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. backport stable/1.3) to the PR, in case that fails you need to create backports manually.

Testing:

  • There are unit/integration tests that verify all acceptance criterias of the issue
  • New tests are written to ensure backwards compatibility with further versions
  • The behavior is tested manually
  • The change has been verified by a QA run
  • The impact of the changes is verified by a benchmark

Documentation:

  • The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
  • New content is added to the release announcement
  • If the PR changes how BPMN processes are validated (e.g. support new BPMN element) then the Camunda modeling team should be informed to adjust the BPMN linting.

Please refer to our review guidelines.

@npepinpe
Copy link
Member Author

You can see the run where I added tests to crash the JVM. The artifacts have the right file and all. I added one test per job type, not to each module. I would revert it before merging.

Copy link
Contributor

@remcowesterhoud remcowesterhoud left a comment

Choose a reason for hiding this comment

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

@npepinpe I have some small comments. Please have a look at them 🙂

🔧 I think it would be nice to combine the archive jobs for test results and test errors into one instead of duplicating them. We can do this by specifying multiple paths: https://github.com/actions/upload-artifact#upload-using-multiple-paths-and-exclusions

.github/workflows/test.yml Outdated Show resolved Hide resolved
Archives dump files generated by the JVM on crashes (e.g. SIGSEV,
SIGBUS, etc.). This is particularly useful when dealing with native
memory and running into unrecoverable crashes to get the stacktrace of
the failing frame, as this is often not logged to standard out.
@npepinpe
Copy link
Member Author

👍 I merged the paths together.

Copy link
Contributor

@remcowesterhoud remcowesterhoud left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@npepinpe
Copy link
Member Author

bors merge

zeebe-bors-camunda bot added a commit that referenced this pull request Apr 25, 2022
9223: Archive JVM error dumps on failure r=npepinpe a=npepinpe

## Description

This PR adds an extra post step to archive JVM error dumps when the jobs have failed. This means archiving any file with the pattern `hs_err_*.log` produced by the job.

Archiving dump files generated by the JVM on crashes (e.g. SIGSEV, SIGBUS, etc.). This is particularly useful when dealing with native memory and running into unrecoverable crashes to get the stacktrace of the failing frame, as this is often not logged to standard out.

NOTE: the post steps are getting bigger, but there is a follow up issue to group these together.

## Related issues

closes #9129 



Co-authored-by: Nicolas Pepin-Perreault <nicolas.pepin-perreault@camunda.com>
@zeebe-bors-camunda
Copy link
Contributor

Build failed:

@npepinpe
Copy link
Member Author

As bors is silent at the moment, I'll just merge. It's silly to run the whole pipeline for something that has no impact on it 😄

@npepinpe npepinpe merged commit b0d7781 into main Apr 25, 2022
@npepinpe npepinpe deleted the 9129-archive-jvm-dumps branch April 25, 2022 11:36
@deepthidevaki deepthidevaki added the version:8.1.0-alpha1 Marks an issue as being completely or in parts released in 8.1.0-alpha1 label May 3, 2022
@Zelldon Zelldon added the version:8.1.0 Marks an issue as being completely or in parts released in 8.1.0 label Oct 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
version:8.1.0-alpha1 Marks an issue as being completely or in parts released in 8.1.0-alpha1 version:8.1.0 Marks an issue as being completely or in parts released in 8.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GHA: Archive JVM dumps
4 participants