RFR: 8290313: Produce warning when user specified java.io.tmpdir directory doesn't exist [v4]
Alan Bateman
alanb at openjdk.org
Sat Oct 15 14:10:51 UTC 2022
On Sat, 15 Oct 2022 09:47:52 GMT, Sean Coffey <coffeys at openjdk.org> wrote:
> Seems like there's a difference of opinion on when such a configuration issue should be reported. Reporting at start up will cost cycles (esp since there's an IO stat call) Maybe we can revert the patch to the original style which is to report the issue at time of tmpFile creation failure.
>
> The original intent of the bug is to improve the exception message reported to end user for the extremely rare case of when java.io.tmpdir contains a bad value.
I don't think we have any data on how common it change java.io.tmpdir to use a different location but if it rare then it should be okay to check the value eagerly. I think the issue we've had with all iterations of this PR to date is that it doesn't distinguish the case where the configuration is overridden, e.g. the current patch checks the location even when java.io.tmpdir is not changed; I guess this is what Roger is pointing out.
Yes, improving the exception and maybe use of jdk.includeInExceptions was listed as an option in JBS.
-------------
PR: https://git.openjdk.org/jdk/pull/9989
More information about the core-libs-dev
mailing list