Skip to content

Commit 1a80b71

Browse files
committed
Capture core dump files from tests
When running Elasticsearch in tests we occassionally have JDK crashes. It's important to capture the state of the JVM at the time of the crash. We currently capture the hs_err_pid file for the crash, but the resulting core file exists in a directory that is no captured. This commit adjusts the capture patterns to also get core files.
1 parent 27b8fd7 commit 1a80b71

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/ElasticsearchBuildCompletePlugin.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,8 @@ private List<File> resolveProjectLogs(File projectDir) {
110110
projectDirFiles.include("**/build/testrun/*/temp/**");
111111
projectDirFiles.include("**/build/**/hs_err_pid*.log");
112112
projectDirFiles.include("**/build/**/replay_pid*.log");
113+
// core dump files are in the working directory of the installation, which is not project specific
114+
projectDirFiles.include("distribution/**/build/install/*/core.*");
113115
projectDirFiles.exclude("**/build/testclusters/**/data/**");
114116
projectDirFiles.exclude("**/build/testclusters/**/distro/**");
115117
projectDirFiles.exclude("**/build/testclusters/**/repo/**");

0 commit comments

Comments
 (0)