timefold-solver
timefold-solver copied to clipboard
quarkus-run.jar fails fast due to "gizmo missing" even though gizmo isn't needed at runtime
Gizmo should not be needed as a runtime dependency if the quarkus generated the anti-reflection code at build time.
So this fail fast is failing too much:
java -jar target/quarkus-app/quarkus-run.jar
...
2023-06-26 11:53:12,750 ERROR [io.qua.ver.htt.run.QuarkusErrorHandler] (executor-thread-1) HTTP Request to /schedules failed, error id: b06b7462-6f90-4c69-8fdc-2adf32f5ca3f-1: org.jboss.resteasy.spi.UnhandledException: java.lang.IllegalStateException: When using the domainAccessType (GIZMO) the classpath or modulepath must contain io.quarkus.gizmo:gizmo.
Maybe add a dependency to io.quarkus.gizmo:gizmo.
at org.jboss.resteasy.core.ExceptionHandler.handleException(ExceptionHandler.java:384)
at org.jboss.resteasy.core.SynchronousDispatcher.writeException(SynchronousDispatcher.java:218)
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:519)
at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:261)
at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:161)
at org.jboss.resteasy.core.interception.jaxrs.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:364)
at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:164)
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:247)
at io.quarkus.resteasy.runtime.standalone.RequestDispatcher.service(RequestDispatcher.java:82)
at io.quarkus.resteasy.runtime.standalone.VertxRequestHandler.dispatch(VertxRequestHandler.java:147)
at io.quarkus.resteasy.runtime.standalone.VertxRequestHandler$1.run(VertxRequestHandler.java:93)
at io.quarkus.vertx.core.runtime.VertxCoreRecorder$14.runWith(VertxCoreRecorder.java:576)
at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538)
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:833)
Caused by: java.lang.IllegalStateException: When using the domainAccessType (GIZMO) the classpath or modulepath must contain io.quarkus.gizmo:gizmo.
Maybe add a dependency to io.quarkus.gizmo:gizmo.
at ai.timefold.solver.core.impl.domain.common.accessor.gizmo.GizmoMemberAccessorFactory.buildGizmoMemberAccessor(GizmoMemberAccessorFactory.java:35)
at ai.timefold.solver.core.impl.domain.common.accessor.MemberAccessorFactory.buildMemberAccessor(MemberAccessorFactory.java:38)
at ai.timefold.solver.core.impl.domain.common.accessor.MemberAccessorFactory.lambda$buildAndCacheMemberAccessor$0(MemberAccessorFactory.java:125)
at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
at ai.timefold.solver.core.impl.domain.common.accessor.MemberAccessorFactory.buildAndCacheMemberAccessor(MemberAccessorFactory.java:124)
at ai.timefold.solver.core.impl.domain.entity.descriptor.EntityDescriptor.processPlanningVariableAnnotation(EntityDescriptor.java:240)
at ai.timefold.solver.core.impl.domain.entity.descriptor.EntityDescriptor.processAnnotations(EntityDescriptor.java:155)
at ai.timefold.solver.core.impl.domain.solution.descriptor.SolutionDescriptor.buildSolutionDescriptor(SolutionDescriptor.java:107)
at ai.timefold.solver.core.impl.solver.DefaultSolverFactory.buildSolutionDescriptor(DefaultSolverFactory.java:148)
at ai.timefold.solver.core.impl.solver.DefaultSolverFactory.<init>(DefaultSolverFactory.java:70)
at ai.timefold.solver.core.api.solver.SolverFactory.create(SolverFactory.java:106)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider.solverFactory(DefaultTimefoldBeanProvider.java:46)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverFactory_5706de706f4c57c0ea21f6c077f050d9d713cf51_Bean.doCreate(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverFactory_5706de706f4c57c0ea21f6c077f050d9d713cf51_Bean.create(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverFactory_5706de706f4c57c0ea21f6c077f050d9d713cf51_Bean.get(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverFactory_5706de706f4c57c0ea21f6c077f050d9d713cf51_Bean.get(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverManager_4f9396522af41bbdbba5ba1e84099a4e8821592f_Bean.doCreate(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverManager_4f9396522af41bbdbba5ba1e84099a4e8821592f_Bean.create(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverManager_4f9396522af41bbdbba5ba1e84099a4e8821592f_Bean.get(Unknown Source)
at ai.timefold.solver.quarkus.bean.DefaultTimefoldBeanProvider_ProducerMethod_solverManager_4f9396522af41bbdbba5ba1e84099a4e8821592f_Bean.get(Unknown Source)
at ai.timefold.model.orderfulfillmentvehiclerouting.service.OFVRPSchedulesResource_Bean.doCreate(Unknown Source)
at ai.timefold.model.orderfulfillmentvehiclerouting.service.OFVRPSchedulesResource_Bean.create(Unknown Source)
at ai.timefold.model.orderfulfillmentvehiclerouting.service.OFVRPSchedulesResource_Bean.create(Unknown Source)
at io.quarkus.arc.impl.AbstractSharedContext.createInstanceHandle(AbstractSharedContext.java:113)
at io.quarkus.arc.impl.AbstractSharedContext$1.get(AbstractSharedContext.java:37)
at io.quarkus.arc.impl.AbstractSharedContext$1.get(AbstractSharedContext.java:34)
at io.quarkus.arc.impl.LazyValue.get(LazyValue.java:26)
at io.quarkus.arc.impl.ComputingCache.computeIfAbsent(ComputingCache.java:69)
at io.quarkus.arc.impl.AbstractSharedContext.get(AbstractSharedContext.java:34)
at ai.timefold.model.orderfulfillmentvehiclerouting.service.OFVRPSchedulesResource_Bean.get(Unknown Source)
at ai.timefold.model.orderfulfillmentvehiclerouting.service.OFVRPSchedulesResource_Bean.get(Unknown Source)
at io.quarkus.arc.impl.ArcContainerImpl.beanInstanceHandle(ArcContainerImpl.java:485)
at io.quarkus.arc.impl.ArcContainerImpl.beanInstanceHandle(ArcContainerImpl.java:498)
at io.quarkus.arc.impl.ArcContainerImpl$2.get(ArcContainerImpl.java:282)
at io.quarkus.arc.impl.ArcContainerImpl$2.get(ArcContainerImpl.java:279)
at io.quarkus.resteasy.common.runtime.QuarkusConstructorInjector.construct(QuarkusConstructorInjector.java:52)
at org.jboss.resteasy.plugins.server.resourcefactory.POJOResourceFactory.createResource(POJOResourceFactory.java:71)
at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:401)
at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:69)
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:492)
... 15 more
Being stopgapped now https://github.com/TimefoldAI/timefold-solver/pull/135 Being fixed long term https://github.com/TimefoldAI/timefold-solver/pull/134
Blocked by https://github.com/TimefoldAI/timefold-solver/issues/136