Skip to content

Commit

Permalink
Fix quarkus.native.debug-build-process
Browse files Browse the repository at this point in the history
As of JDK 9 `address` needs to specify the host as well. This patch
makes JDWP listen on 0.0.0.0 and is compatible with JDK 8 and JDK >= 9
  • Loading branch information
zakkak committed Oct 5, 2021
1 parent cc5d211 commit 56fb882
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -620,8 +620,15 @@ public NativeImageInvokerInfo build() {
nativeImageArgs.add("-H:DebugInfoSourceSearchPath=" + APP_SOURCES);
}
if (nativeConfig.debugBuildProcess) {
String debugBuildProcessHost;
if (isContainerBuild) {
debugBuildProcessHost = "0.0.0.0";
} else {
debugBuildProcessHost = "localhost";
}
nativeImageArgs
.add("-J-Xrunjdwp:transport=dt_socket,address=" + DEBUG_BUILD_PROCESS_PORT + ",server=y,suspend=y");
.add("-J-Xrunjdwp:transport=dt_socket,address=" + debugBuildProcessHost + ":"
+ DEBUG_BUILD_PROCESS_PORT + ",server=y,suspend=y");
}
if (nativeConfig.enableReports) {
nativeImageArgs.add("-H:+PrintAnalysisCallTree");
Expand Down

0 comments on commit 56fb882

Please sign in to comment.