Request for Review: 7132199: sun/management/jmxremote/bootstrap/JvmstatCountersTest.java failing on all platforms

Dmitry Samersoff Dmitry.Samersoff at oracle.com
Mon Jan 30 09:28:05 PST 2012


On 2012-01-30 16:28, Staffan Larsen wrote:
>> 2. If you decide to hardcode "/tmp" please, create a global constant
>> for it.
> 
> I don't agree that this would make the code easier to read or maintain.
> I should, however, include a comment saying that the file is always in
> /tmp regardless of the value of java.io.tmpdir.

/tmp is common but not mandatory, especially if we speak about embedded
systems.

  Native code should use P_tmpdir constant from stdio.h rather than
hardcode "/tmp".

As we can't access it from java I recommend to create a global constant
somewhere to reduce possible future porting efforts.


> Changing the tmpdir static would be a smaller fix, but all the cwd code
> would then remain. Yes, HotSpot never writes to cwd.

I agree with Staffan, that looks for socket/door in cwd should be removed.

-Dmitry

-- 
Dmitry Samersoff
Java Hotspot development team, SPB04
* There will come soft rains ...


More information about the serviceability-dev mailing list