Hey thread - if anyone is still running into this issue, this update might help.
We had the same problem at kJAR deployment on our standalone KIE: the WARN messages about unable to create instance and such...it looks like those errors were mainly coming from classes that were part of POM sub-dependencies that were marked as <optional>. Take this joda-time dependency we added to our kJAR (for no reason other than to test this issue):
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<version>2.11.1</version>
</dependency>
The POM for that joda-time dependency has an optional dependency for joda-convert:
<dependency>
<groupId>org.joda</groupId>
<artifactId>joda-convert</artifactId>
<version>1.9.2</version>
<scope>compile</scope>
<optional>true</optional>
<!-- mandatory in Scala -->
</dependency>
And when we deployed a kJAR that had just joda-time as a dependency and only used the org.joda.time.DateTime class, KIE still complained about the convert library with those WARN messages and then would not run the process even though the script wasn't using anything from "convert". At runtime we'd see those NoClassDefFound errors and such.
So we updated standalone.xml with the system-property mentioned above:
<system-properties>
<property name="org.drools.server.filter.classes" value="true/>
...
</system-properties>
And we still see the WARN messages at kJAR deploy, but the code now works at runtime/execution.
So org.drools.server.filter.classes seems to fix the runtime but not deployment.
I hope that helps!
RHPAM 7.11
Java11
jBPM/KIE 7.52.0.Final-redhat-00008