Dear Claude, dear list members
As I understand, Smooks targets Java 1.8, but should work also on newer releases. I am using the latest 2.0.0-RC1 in a pure Kotlin environment on JDK 17. Throughout the development, I did encounter classloader warnings over and again. Fiddling with dependencies, I was able to get several toy examples up and running. inside IntelliJ. but as soon standalone executable fat JARs crash with the following error:
2022-04-02T13:55:51.291+0200 WARN Not scanning classpath for ClassLoader 'jdk.internal.loader.ClassLoaders$AppClassLoader'. ClassLoader must implement 'java.net.URLClassLoader'.
2022-04-02T13:55:51.507+0200 WARN Not scanning classpath for ClassLoader 'jdk.internal.loader.ClassLoaders$AppClassLoader'. ClassLoader must implement 'java.net.URLClassLoader'.
2022-04-02T13:55:51.564+0200 ERROR Error initializing smooks: Error processing resource file '/system-interceptors.xml'.
This is exactly the same error @Nestor already observed on WSO2. As per Claude's answer in the related thread, cause might be some shadowing on the class path. The class loader warnings above to me indicate that there seems to be some problem with Smooks using some deprecated (since Java 9) classloader API. Maybe this is the roor cause, maybe not.
To dig deeper, it would be very helpful to have an overview about how, where, and why Smooks does its own classpath scanning and classloading; especially, where does Smooks not play by the book but uses tweaks that might cause the above problems?
Thanks very much for your help!
Uli