-
Bug
-
Resolution: Done
-
Major
-
None
-
None
-
None
-
False
-
False
-
Undefined
-
-
-
2021 Week 28-30 (from Jul 12)
After the introduction of "KOGITO-5223 kie v7 legacy API for Kogito"
https://github.com/kiegroup/kogito-runtimes/pull/1347
https://github.com/kiegroup/optaplanner/pull/1402
The following problem was detected
Before:
It was possible to have a Quarkus application packaged as a uber-jar that uses the optaplanner-quarkus extesion and use the solver factory, etc, for example:
@Inject SolverFactory<TaskAssigningSolution> solverFactory and work with it.
Now:
The same application, same packaging, etc. fails at Solver instantiation time producing the following exception:
2021-07-06 12:26:18,083 INFO [io.quarkus] (main) Installed features: [cdi, optaplanner, resteasy, smallrye-context-propagation]
2021-07-06 12:26:18,165 ERROR [org.jbo.thr.errors] (executor-thread-0) Thread Thread[executor-thread-0,5,main] threw an uncaught exception: java.lang.ExceptionInInitializerError
at org.drools.dynamic.DynamicServiceRegistrySupplier.get(DynamicServiceRegistrySupplier.java:32)
at org.drools.dynamic.DynamicServiceRegistrySupplier.get(DynamicServiceRegistrySupplier.java:23)
at org.kie.api.internal.utils.ServiceRegistry$Impl.getServiceRegistry(ServiceRegistry.java:90)
at org.kie.api.internal.utils.ServiceRegistry$ServiceRegistryHolder.<clinit>(ServiceRegistry.java:49)
at org.kie.api.internal.utils.ServiceRegistry.getInstance(ServiceRegistry.java:41)
at org.kie.api.internal.utils.ServiceRegistry.getService(ServiceRegistry.java:37)
at org.kie.api.KieServices$Factory$LazyHolder.<clinit>(KieServices.java:358)
at org.kie.api.KieServices$Factory.get(KieServices.java:365)
at org.kie.api.KieServices.get(KieServices.java:349)
at org.optaplanner.core.impl.score.stream.drools.DroolsConstraintSessionFactory.buildKieBaseFromModel(DroolsConstraintSessionFactory.java:79)
at org.optaplanner.core.impl.score.stream.drools.DroolsConstraintSessionFactory.buildSession(DroolsConstraintSessionFactory.java:126)
at org.optaplanner.core.impl.score.director.stream.DroolsConstraintStreamScoreDirectorFactory.newConstraintStreamingSession(DroolsConstraintStreamScoreDirectorFactory.java:50)
at org.optaplanner.core.impl.score.director.stream.DroolsConstraintStreamScoreDirector.resetConstraintStreamingSession(DroolsConstraintStreamScoreDirector.java:75)
at org.optaplanner.core.impl.score.director.stream.DroolsConstraintStreamScoreDirector.setWorkingSolution(DroolsConstraintStreamScoreDirector.java:67)
at org.optaplanner.core.impl.solver.scope.SolverScope.setWorkingSolutionFromBestSolution(SolverScope.java:215)
at org.optaplanner.core.impl.solver.AbstractSolver.solvingStarted(AbstractSolver.java:80)
at org.optaplanner.core.impl.solver.DefaultSolver.solvingStarted(DefaultSolver.java:200)
at org.optaplanner.core.impl.solver.DefaultSolver.solve(DefaultSolver.java:174)
at org.kie.kogito.taskassigning.ServiceResource.lambda$startSolver$0(ServiceResource.java:55)
at io.smallrye.context.impl.wrappers.SlowContextualRunnable.run(SlowContextualRunnable.java:19)
at io.quarkus.vertx.core.runtime.VertxCoreRecorder$14.runWith(VertxCoreRecorder.java:486)
at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2442)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1476)
at org.jboss.threads.DelegatingRunnable.run(DelegatingRunnable.java:29)
at org.jboss.threads.ThreadLocalResettingRunnable.run(ThreadLocalResettingRunnable.java:29)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.RuntimeException: Child services [org.drools.compiler.kie.builder.impl.KieBaseUpdaters] have no parent
at org.kie.api.internal.utils.ServiceDiscoveryImpl.buildMap(ServiceDiscoveryImpl.java:162)
at org.kie.api.internal.utils.ServiceDiscoveryImpl.getServices(ServiceDiscoveryImpl.java:87)
at org.kie.api.internal.utils.ServiceRegistry$Impl.<init>(ServiceRegistry.java:62)
at org.drools.dynamic.DynamicServiceRegistrySupplier$LazyHolder.<clinit>(DynamicServiceRegistrySupplier.java:27)
... 27 more
- blocks
-
PLANNER-2183 Kogito Continuous Task Assignment in jBPM using OptaPlanner
- Resolved
- relates to
-
DROOLS-6493 Make Drools uber-jar friendly
- Closed