RFR(S/M): 8205419: [testbug] TestJmapCore failing without SA: introduce @requires vm.hasSA

Lindenmaier, Goetz goetz.lindenmaier at sap.com
Wed Jun 20 13:49:46 UTC 2018


Hi,

TestJmapCore is failing on aix because there jhsdb is not implemented.
So far, such tests check at runtime Platform.shouldSAAttach() which is missing
in TestJmapCore.

Instead, I implement @requires vm.hasSAandCanAttach.
This makes jtreg skip the tests without compiling and starting them.

I added the new property to all tests that check shouldSAAttach in jdk and hostpot test
directories. 
This is the implementation of the new property, the rest is just repetitive checking it:
http://cr.openjdk.java.net/~goetz/wr18/8205419-requiresHasSA/01/test/jtreg-ext/requires/VMProps.java.udiff.html
webrev:
http://cr.openjdk.java.net/~goetz/wr18/8205419-requiresHasSA/01/ 

Is it correct to assume the VMProps is evaluated on the same machine and with the same
user as used for executing the test?  canPtraceAttachLinux directly accesses the system.

(Should I remove the checks for shouldSAAttach() from the changed tests?)

Best regards,
  Goetz.


More information about the serviceability-dev mailing list