JDK-8170772 : ResourceBundle improper caching causes tools/javadoc tests intermittently
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util:i18n
  • Affected Version: 9
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2016-12-06
  • Updated: 2016-12-15
  • Resolved: 2016-12-10
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 9
9 b149Fixed
Related Reports
Relates :  
Description
tools/javadoc/CheckResourceKeys.java
tools/javadoc/MethodLinks.java
tools/javadoc/ReleaseOption.java
tools/javadoc/XWerror.java

The above tests faile due to they cannot find the requested resource bundle, like the below,
----------System.err:(56/4254)----------
java.lang.InternalError: Cannot find requested resource bundle for locale en_US
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getBundles(JavacMessages.java:128)
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getLocalizedString(JavacMessages.java:147)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.getText(Messager.java:149)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.notice(Messager.java:272)
	at jdk.javadoc/com.sun.tools.javadoc.main.DocEnv.notice(DocEnv.java:524)
	at jdk.javadoc/com.sun.tools.javadoc.main.JavadocTool.parse(JavadocTool.java:246)
	at jdk.javadoc/com.sun.tools.javadoc.main.JavadocTool.getRootDocImpl(JavadocTool.java:173)
	at jdk.javadoc/com.sun.tools.javadoc.main.Start.parseAndExecute(Start.java:433)
	at jdk.javadoc/com.sun.tools.javadoc.main.Start.begin(Start.java:238)
	at jdk.javadoc/com.sun.tools.javadoc.main.Start.begin(Start.java:224)
	at jdk.javadoc/com.sun.tools.javadoc.Main.execute(Main.java:151)
	at MethodLinks.main(MethodLinks.java:40)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:538)
	at com.sun.javatest.regtest.agent.MainActionHelper$SameVMRunnable.run(MainActionHelper.java:230)
	at java.base/java.lang.Thread.run(Thread.java:844)
Caused by: java.util.MissingResourceException: Can't find bundle for base name com.sun.tools.javadoc.resources.javadoc, locale en_US
	at java.base/java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2085)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1732)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1622)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1597)
	at java.base/java.util.ResourceBundle.getBundle(ResourceBundle.java:1006)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.lambda$new$0(Messager.java:131)
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getBundles(JavacMessages.java:125)
	... 17 more
java.lang.InternalError: Cannot find requested resource bundle for locale en_US
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getBundles(JavacMessages.java:128)
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getLocalizedString(JavacMessages.java:147)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.getText(Messager.java:149)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.error(Messager.java:254)
	at jdk.javadoc/com.sun.tools.javadoc.main.Start.begin(Start.java:249)
	at jdk.javadoc/com.sun.tools.javadoc.main.Start.begin(Start.java:224)
	at jdk.javadoc/com.sun.tools.javadoc.Main.execute(Main.java:151)
	at MethodLinks.main(MethodLinks.java:40)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:538)
	at com.sun.javatest.regtest.agent.MainActionHelper$SameVMRunnable.run(MainActionHelper.java:230)
	at java.base/java.lang.Thread.run(Thread.java:844)
Caused by: java.util.MissingResourceException: Can't find bundle for base name com.sun.tools.javadoc.resources.javadoc, locale en_US
	at java.base/java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2085)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1732)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1622)
	at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1597)
	at java.base/java.util.ResourceBundle.getBundle(ResourceBundle.java:1006)
	at jdk.javadoc/com.sun.tools.javadoc.main.Messager.lambda$new$0(Messager.java:131)
	at jdk.compiler/com.sun.tools.javac.util.JavacMessages.getBundles(JavacMessages.java:125)
	... 13 more

JavaTest Message: Test threw exception: java.lang.InternalError
JavaTest Message: shutting down test

result: Failed. Execution failed: `main' threw exception: java.lang.InternalError: Cannot find requested resource bundle for locale en_US


test result: Failed. Execution failed: `main' threw exception: java.lang.InternalError: Cannot find requested resource bundle for locale en_US
Comments
This is a regression caused by the resource bundle change in JDK-8169069.
09-12-2016

Now that the tests aren't put into ProblemList.txt, it's better to remove label ProblemList.
09-12-2016

This seems to be a systemic modules Resource loading issue, reproducible with javac, old doclet and new doclet, the trace is as follows: loader for module jdk.compiler com/sun/tools/javac/resources/compiler_en.properties caller module jdk.compiler findBundle: 1 [en, ] CacheKey[com.sun.tools.javac.resources.ct, lc="", ldr=jdk.internal.loader.ClassLoaders$AppClassLoader@64b8f8f4(format=null)] formats: [java.class, java.properties] local in module jdk.compiler com.sun.tools.javac.resources.ct caller module jdk.compiler: class com.sun.tools.javac.resources.ct findBundle: 0 [en, ] CacheKey[com.sun.tools.javac.resources.ct, lc=en, ldr=jdk.internal.loader.ClassLoaders$AppClassLoader@64b8f8f4(format=java.class)] formats: [java.class, java.properties] local in module jdk.compiler com.sun.tools.javac.resources.ct_en caller module jdk.compiler: null local in module jdk.compiler com/sun/tools/javac/resources/ct_en.properties caller module jdk.compiler jdk.compiler/com.sun.tools.javac.resources is accessible to module jdk.compiler : true loader for module jdk.compiler com/sun/tools/javac/resources/ct_en.properties caller module jdk.compiler found javadoc in PLATFORM_CLASS_PATH findBundle: 1 [en, ] CacheKey[com.sun.tools.doclets.formats.html.resources.standard, lc="", ldr=jdk.internal.loader.ClassLoaders$AppClassLoader@64b8f8f4(format=null)] formats: [java.class, java.properties] local in module jdk.javadoc com.sun.tools.doclets.formats.html.resources.standard caller unnamed module @757942a1: class com.sun.tools.doclets.formats.html.resources.standard <<ISSUE BELOW>> unnamed module @757942a1 does not have access to jdk.javadoc/com.sun.tools.doclets.formats.html.resources local in module jdk.javadoc com/sun/tools/doclets/formats/html/resources/standard.properties caller unnamed module @757942a1 jdk.javadoc/com.sun.tools.doclets.formats.html.resources is accessible to unnamed module @757942a1 : false loader for module jdk.javadoc com/sun/tools/doclets/formats/html/resources/standard.properties caller unnamed module @757942a1 findBundle: 0 [en, ] CacheKey[com.sun.tools.doclets.formats.html.resources.standard, lc=en, ldr=jdk.internal.loader.ClassLoaders$AppClassLoader@64b8f8f4(format=null)] formats: [java.class, java.properties] local in module jdk.javadoc com.sun.tools.doclets.formats.html.resources.standard_en caller unnamed module @757942a1: null local in module jdk.javadoc com/sun/tools/doclets/formats/html/resources/standard_en.properties caller unnamed module @757942a1 jdk.javadoc/com.sun.tools.doclets.formats.html.resources is accessible to unnamed module @757942a1 : false loader for module jdk.javadoc com/sun/tools/doclets/formats/html/resources/standard_en.properties caller unnamed module @757942a1 Exception in thread "main" java.util.MissingResourceException: Can't find bundle for base name com.sun.tools.doclets.formats.html.resources.standard, locale en at java.base/java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2085) at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1732) at java.base/java.util.ResourceBundle.getBundleFromModule(ResourceBundle.java:1651) at java.base/java.util.ResourceBundle.getBundle(ResourceBundle.java:1042) at CheckResourceKeys.getResourceKeys(CheckResourceKeys.java:237) at CheckResourceKeys.run(CheckResourceKeys.java:100) at CheckResourceKeys.main(CheckResourceKeys.java:54)
08-12-2016

I think there is a modules related issue lurking in the bottom, as far as javadoc is concerned, either we have a resource or not, if we don't have one that is a build issue, but that is not the case here.
07-12-2016

Raise to P2 since they fail in tier 1
06-12-2016