Blocks :
|
|
Blocks :
|
|
Duplicate :
|
Possible solutions: - jni, jvmti. Write another lib(not monitoring one) which will get pid, but currently we do not have native tests support in hotspot/test - Runtime.exec( "echo $PPID" ).getInputStream()... some platforms may not have shell interpreter - via harness(jtreg?) get pid of the starting test and pass it somehow(via -D java property) to the same test. Example: sh -c 'exec /path/to/bin/java '-Dpid=$$ MyTest' - WB, Unsafe, ... with changes in product - Enhance Process API in JDK-8046092 JEP 102: Process API Updates