[JBoss JIRA] (DROOLS-5021) ClassCastException thrown when deserializing components of a Generic command
by Steve Davidson (Jira)
[ https://issues.redhat.com/browse/DROOLS-5021?page=com.atlassian.jira.plug... ]
Steve Davidson commented on DROOLS-5021:
----------------------------------------
New code:
{code:java}
@Override
public <T> T unmarshall(String serializedInput, Class<T> type) {
try {
final Class<?> actualType = classesSet.contains(type) ? type : Object.class; //The correct test & return
@SuppressWarnings("unchecked") //Suppress Generics Warning
final T unwrapped = (T) unwrap(deserializeObjectMapper.readValue(serializedInput, actualType));
return unwrapped;
} catch (IOException e) {
throw new MarshallingException("Error unmarshalling input", e);
} finally {
jsonContext.get().reset();
}
}
{code}
> ClassCastException thrown when deserializing components of a Generic command
> ----------------------------------------------------------------------------
>
> Key: DROOLS-5021
> URL: https://issues.redhat.com/browse/DROOLS-5021
> Project: Drools
> Issue Type: Bug
> Components: kie server
> Affects Versions: 7.29.0.Final
> Reporter: Steve Davidson
> Assignee: Maciej Swiderski
> Priority: Major
> Attachments: DroolsKieContainerCommandServiceImplLine60.png, JSONMarshallerLine328.WrongSelected.png, KieIssueDemo.tbz, KieRun.log
>
>
> When attempting to send a Generic Data object in an Insert Command to be added to the Rule Agenda, the server fails to deserialize the Insert Command with the following;
> Feb 6 11:09:30 thor jetty[21143]: Feb 06, 2020 11:09:30 AM org.kie.server.services.drools.DroolsKieContainerCommandServiceImpl callContainer
> Feb 6 11:09:30 thor jetty[21143]: SEVERE: Error calling container 'JUnit Test: kie-server'
> Feb 6 11:09:30 thor jetty[21143]: java.lang.ClassCastException: class java.util.LinkedHashMap cannot be cast to class org.kie.api.command.Command (java.util.LinkedHashMap is in module java.base of loader 'bootstrap'; org.kie.api.command.Command is in unnamed module of loader org.eclipse.jetty.webapp.WebAppClassLoader @51bd8b5c)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.services.drools.DroolsKieContainerCommandServiceImpl.callContainer(DroolsKieContainerCommandServiceImpl.java:60)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.remote.rest.drools.CommandResource.manageContainer(CommandResource.java:91)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/java.lang.reflect.Method.invoke(Method.java:566)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:140)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.internalInvokeOnTarget(ResourceMethodInvoker.java:509)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTargetAfterFilter(ResourceMethodInvoker.java:399)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.lambda$invokeOnTarget$0(ResourceMethodInvoker.java:363)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:365)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:337)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:310)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:443)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:233)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:139)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:142)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:219)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:227)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
> Feb 6 11:09:30 thor jetty[21143]: #011at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1401)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:760)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:226)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.services.impl.security.web.CaptureHttpRequestFilter.doFilter(CaptureHttpRequestFilter.java:42)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1596)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:545)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:501)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1592)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1296)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:485)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1562)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1211)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:221)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.Server.handle(Server.java:500)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:386)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:562)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:378)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:270)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:388)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/java.lang.Thread.run(Thread.java:834)
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 1 month
[JBoss JIRA] (DROOLS-5021) ClassCastException thrown when deserializing components of a Generic command
by Steve Davidson (Jira)
[ https://issues.redhat.com/browse/DROOLS-5021?page=com.atlassian.jira.plug... ]
Steve Davidson commented on DROOLS-5021:
----------------------------------------
Interim update:
(Was off for a couple of rounds of surgery as well as some additional side "jobs").
Attempting to verify this on the master branch, I ran into DROOLS-5106. And I have been unable to figure out how to compile the current version on Master, sorry (was getting actual compile errors, as well as a bunch of whole new tests failing). I WAS able to compile and build my fix on 7.29 (broke ALOT of Unit & Integration tests though), and run this manually. Suggested fix DID allow for the message to be processed, but apparently I forgot to initialize a session somewhere. I am looking into how to do that remotely now (sorry folks, your documentation on remote session initialization is less than completely clear or present).
I should have this along in the next couple of days (side tracked with kid home with friends -- schools are all closed).
Regards,
Steve
> ClassCastException thrown when deserializing components of a Generic command
> ----------------------------------------------------------------------------
>
> Key: DROOLS-5021
> URL: https://issues.redhat.com/browse/DROOLS-5021
> Project: Drools
> Issue Type: Bug
> Components: kie server
> Affects Versions: 7.29.0.Final
> Reporter: Steve Davidson
> Assignee: Maciej Swiderski
> Priority: Major
> Attachments: DroolsKieContainerCommandServiceImplLine60.png, JSONMarshallerLine328.WrongSelected.png, KieIssueDemo.tbz, KieRun.log
>
>
> When attempting to send a Generic Data object in an Insert Command to be added to the Rule Agenda, the server fails to deserialize the Insert Command with the following;
> Feb 6 11:09:30 thor jetty[21143]: Feb 06, 2020 11:09:30 AM org.kie.server.services.drools.DroolsKieContainerCommandServiceImpl callContainer
> Feb 6 11:09:30 thor jetty[21143]: SEVERE: Error calling container 'JUnit Test: kie-server'
> Feb 6 11:09:30 thor jetty[21143]: java.lang.ClassCastException: class java.util.LinkedHashMap cannot be cast to class org.kie.api.command.Command (java.util.LinkedHashMap is in module java.base of loader 'bootstrap'; org.kie.api.command.Command is in unnamed module of loader org.eclipse.jetty.webapp.WebAppClassLoader @51bd8b5c)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.services.drools.DroolsKieContainerCommandServiceImpl.callContainer(DroolsKieContainerCommandServiceImpl.java:60)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.remote.rest.drools.CommandResource.manageContainer(CommandResource.java:91)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/java.lang.reflect.Method.invoke(Method.java:566)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:140)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.internalInvokeOnTarget(ResourceMethodInvoker.java:509)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTargetAfterFilter(ResourceMethodInvoker.java:399)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.lambda$invokeOnTarget$0(ResourceMethodInvoker.java:363)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:365)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:337)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:310)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:443)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:233)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:139)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:142)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:219)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:227)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
> Feb 6 11:09:30 thor jetty[21143]: #011at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1401)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:760)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:226)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.kie.server.services.impl.security.web.CaptureHttpRequestFilter.doFilter(CaptureHttpRequestFilter.java:42)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1596)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:545)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:501)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1592)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1296)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:485)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1562)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1211)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:221)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.Server.handle(Server.java:500)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:386)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:562)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:378)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:270)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:388)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)
> Feb 6 11:09:30 thor jetty[21143]: #011at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)
> Feb 6 11:09:30 thor jetty[21143]: #011at java.base/java.lang.Thread.run(Thread.java:834)
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 1 month
[JBoss JIRA] (DROOLS-5106) Local/Internal Maven Repos can not be accessed
by Steve Davidson (Jira)
[ https://issues.redhat.com/browse/DROOLS-5106?page=com.atlassian.jira.plug... ]
Steve Davidson updated DROOLS-5106:
-----------------------------------
Attachment: settings.xml
> Local/Internal Maven Repos can not be accessed
> ----------------------------------------------
>
> Key: DROOLS-5106
> URL: https://issues.redhat.com/browse/DROOLS-5106
> Project: Drools
> Issue Type: Bug
> Components: Artifact Repository
> Affects Versions: 7.33.0.Final
> Reporter: Steve Davidson
> Assignee: Alexandre Bakos
> Priority: Major
> Labels: Drools, drools-compiler, maven
> Attachments: settings.xml
>
>
> Attempting to use an internal Nexus Repository, unable to load Drools KIE Modules using Maven. This works with 7.29.Final. Changing to 7.33.Final fails with the following stack trace;
> {code:java}
> WARNING: Environment variable M2_HOME is not set
> Feb 24, 2020 5:12:30 PM org.kie.server.services.impl.KieServerImpl createContainer
> SEVERE: Error creating container 'JUnit Test: kie-server' for module 'com.j2eeguys.demo:KieIssueDemo:0.1.0-SNAPSHOT'
> java.lang.RuntimeException: Cannot find KieModule: com.j2eeguys.demo:KieIssueDemo:0.1.0-SNAPSHOT
> at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:186)
> at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:176)
> at org.kie.server.services.impl.KieServerImpl.createContainer(KieServerImpl.java:281)
> at org.kie.server.remote.rest.common.resource.KieServerRestImpl.createContainer(KieServerRestImpl.java:157)
> at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.base/java.lang.reflect.Method.invoke(Method.java:566)
> at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:140)
> at org.jboss.resteasy.core.ResourceMethodInvoker.internalInvokeOnTarget(ResourceMethodInvoker.java:509)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTargetAfterFilter(ResourceMethodInvoker.java:399)
> at org.jboss.resteasy.core.ResourceMethodInvoker.lambda$invokeOnTarget$0(ResourceMethodInvoker.java:363)
> at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:365)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:337)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:310)
> at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:443)
> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:233)
> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:139)
> at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:142)
> at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:219)
> at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:227)
> at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
> at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> at org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1401)
> at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:760)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:226)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> at org.kie.server.services.impl.security.web.CaptureHttpRequestFilter.doFilter(CaptureHttpRequestFilter.java:42)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1596)
> at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:545)
> at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
> at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:501)
> at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
> at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1592)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
> at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1296)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
> at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:485)
> at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1562)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
> at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1211)
> at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
> at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:221)
> at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
> at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> at org.eclipse.jetty.server.Server.handle(Server.java:500)
> at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:386)
> at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:562)
> at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:378)
> at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:270)
> at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
> at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
> at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)
> at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:388)
> at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)
> at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)
> at java.base/java.lang.Thread.run(Thread.java:834)
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 1 month
[JBoss JIRA] (DROOLS-5106) Local/Internal Maven Repos can not be accessed
by Steve Davidson (Jira)
[ https://issues.redhat.com/browse/DROOLS-5106?page=com.atlassian.jira.plug... ]
Steve Davidson commented on DROOLS-5106:
----------------------------------------
Sorry for the delayed reply, was off for surgery, followed by Primaries (I was working a Polling Location), followed by more surgery.
[^settings.xml]
Runtime platform:
java -version
openjdk version "11.0.6" 2020-01-14
OpenJDK Runtime Environment (build 11.0.6+10-post-Ubuntu-1ubuntu118.04.1)
OpenJDK 64-Bit Server VM (build 11.0.6+10-post-Ubuntu-1ubuntu118.04.1, mixed mode, sharing)
Sample project is attached to https://issues.redhat.com/browse/DROOLS-5021. This includes both the client and the rules/kie module. I've added a sample settings.xml file to this ticket (specifically, removed confidential settings)
Short version:
* Upload project (see DROOLS-5021) to local Nexus Repo.
* Configure Maven on server to use local Nexus Repo (see attached settings.xml)
* Run sample client. If version 7.29, module is loaded, but then fails with issue reported in DROOLS-5021. If version 7.33, fails with the current stack trace.
What else do you need?
Regards,
Steve
> Local/Internal Maven Repos can not be accessed
> ----------------------------------------------
>
> Key: DROOLS-5106
> URL: https://issues.redhat.com/browse/DROOLS-5106
> Project: Drools
> Issue Type: Bug
> Components: Artifact Repository
> Affects Versions: 7.33.0.Final
> Reporter: Steve Davidson
> Assignee: Alexandre Bakos
> Priority: Major
> Labels: Drools, drools-compiler, maven
> Attachments: settings.xml
>
>
> Attempting to use an internal Nexus Repository, unable to load Drools KIE Modules using Maven. This works with 7.29.Final. Changing to 7.33.Final fails with the following stack trace;
> {code:java}
> WARNING: Environment variable M2_HOME is not set
> Feb 24, 2020 5:12:30 PM org.kie.server.services.impl.KieServerImpl createContainer
> SEVERE: Error creating container 'JUnit Test: kie-server' for module 'com.j2eeguys.demo:KieIssueDemo:0.1.0-SNAPSHOT'
> java.lang.RuntimeException: Cannot find KieModule: com.j2eeguys.demo:KieIssueDemo:0.1.0-SNAPSHOT
> at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:186)
> at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:176)
> at org.kie.server.services.impl.KieServerImpl.createContainer(KieServerImpl.java:281)
> at org.kie.server.remote.rest.common.resource.KieServerRestImpl.createContainer(KieServerRestImpl.java:157)
> at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.base/java.lang.reflect.Method.invoke(Method.java:566)
> at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:140)
> at org.jboss.resteasy.core.ResourceMethodInvoker.internalInvokeOnTarget(ResourceMethodInvoker.java:509)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTargetAfterFilter(ResourceMethodInvoker.java:399)
> at org.jboss.resteasy.core.ResourceMethodInvoker.lambda$invokeOnTarget$0(ResourceMethodInvoker.java:363)
> at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:365)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:337)
> at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:310)
> at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:443)
> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:233)
> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:139)
> at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:358)
> at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:142)
> at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:219)
> at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:227)
> at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
> at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> at org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1401)
> at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:760)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:226)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> at org.kie.server.services.impl.security.web.CaptureHttpRequestFilter.doFilter(CaptureHttpRequestFilter.java:42)
> at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1596)
> at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:545)
> at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
> at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:501)
> at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
> at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1592)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
> at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1296)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
> at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:485)
> at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1562)
> at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
> at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1211)
> at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
> at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:221)
> at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
> at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
> at org.eclipse.jetty.server.Server.handle(Server.java:500)
> at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:386)
> at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:562)
> at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:378)
> at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:270)
> at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
> at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
> at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)
> at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)
> at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:388)
> at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)
> at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)
> at java.base/java.lang.Thread.run(Thread.java:834)
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
6 years, 1 month