|
15 | 15 | import com.google.common.collect.Multimap; |
16 | 16 | import datadog.environment.JavaVirtualMachine; |
17 | 17 | import datadog.environment.OperatingSystem; |
| 18 | +import datadog.environment.SystemProperties; |
18 | 19 | import datadog.trace.api.Pair; |
19 | 20 | import datadog.trace.api.config.ProfilingConfig; |
20 | 21 | import delight.fileupload.FileUpload; |
|
24 | 25 | import java.io.IOException; |
25 | 26 | import java.io.InputStream; |
26 | 27 | import java.net.InetAddress; |
27 | | -import java.nio.file.FileSystems; |
28 | 28 | import java.nio.file.Files; |
29 | 29 | import java.nio.file.Path; |
30 | 30 | import java.nio.file.Paths; |
|
73 | 73 | import org.slf4j.LoggerFactory; |
74 | 74 |
|
75 | 75 | @DisabledIfSystemProperty(named = "java.vm.name", matches = ".*J9.*") |
76 | | -// @DisabledIf( |
77 | | -// value = "isJavaVersionAtLeast24", |
78 | | -// disabledReason = "Failing on Java 24. Skip until we have a fix.") |
79 | 76 | class JFRBasedProfilingIntegrationTest { |
80 | 77 | private static final Logger log = LoggerFactory.getLogger(JFRBasedProfilingIntegrationTest.class); |
81 | 78 | private static final Duration ONE_NANO = Duration.ofNanos(1); |
@@ -860,10 +857,7 @@ private static ProcessBuilder createProcessBuilder( |
860 | 857 | } |
861 | 858 |
|
862 | 859 | private static String javaPath() { |
863 | | - final String separator = FileSystems.getDefault().getSeparator(); |
864 | | - String cmd = System.getProperty("java.home") + separator + "bin" + separator + "java"; |
865 | | - System.err.println("===> Java: " + cmd); |
866 | | - return cmd; |
| 860 | + return Paths.get(SystemProperties.getOrDefault("java.home", ""), "bin", "java").toString(); |
867 | 861 | } |
868 | 862 |
|
869 | 863 | private static String buildDirectory() { |
|
0 commit comments