Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.13
-
None
-
None
Description
xbean-finder sometimes fails parsing classes but does not always log the name of the class, making it difficult to identify issues.
For instance
Caused by: java.lang.UnsupportedOperationException
at org.apache.xbean.asm6.ClassVisitor.visitNestHostExperimental(ClassVisitor.java:158)
at org.apache.xbean.asm6.ClassReader.accept(ClassReader.java:541)
at org.apache.xbean.asm6.ClassReader.accept(ClassReader.java:391)
at org.apache.xbean.finder.AnnotationFinder.readClassDef(AnnotationFinder.java:1168)
at org.apache.xbean.finder.AnnotationFinder.<init>(AnnotationFinder.java:145)
at org.apache.xbean.finder.AnnotationFinder.<init>(AnnotationFinder.java:158)
The annotation finder only catches NoClassDefFound
So either we catch all exceptions we are interested in, or we collect a bit wider (Exception) and log a proper message. I'd probably go for the second as first it's simpler and second, whatever exception happens, it's always useful to know what class we were processing when it failed.
Attachments
Issue Links
- is related to
-
SPARK-28111 Upgrade `xbean-asm7-shaded` to 4.14
- Resolved