-
Bug
-
Resolution: Incomplete
-
P4
-
None
-
15.0.1
-
x86_64
-
linux_suse_slec
A DESCRIPTION OF THE PROBLEM :
if a jar is built including some signed dependency like bouncy castle bcmail-15on which brings META-INF/BCKEY.DSA into it then the jar is not runnable and it is pain to investigate why, because it incorrectly reports that the main class was not found:
$ java -jar myjar.jar
Error: Could not find or load main class com.example.MyMainClass
Caused by: java.lang.ClassNotFoundException: com.example.MyMainClass
Once META-INF/BCKEY.DSA is explicitly excluded from the jar by the build system then it starts working
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
see description it is very easy to reproduce
if a jar is built including some signed dependency like bouncy castle bcmail-15on which brings META-INF/BCKEY.DSA into it then the jar is not runnable and it is pain to investigate why, because it incorrectly reports that the main class was not found:
$ java -jar myjar.jar
Error: Could not find or load main class com.example.MyMainClass
Caused by: java.lang.ClassNotFoundException: com.example.MyMainClass
Once META-INF/BCKEY.DSA is explicitly excluded from the jar by the build system then it starts working
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
see description it is very easy to reproduce