[JBoss JIRA] (DROOLS-2733) Support MVEL Dialect using custom inline accumulate code with external declarations in the executable model
by Luca Molteni (Jira)
[ https://issues.jboss.org/browse/DROOLS-2733?page=com.atlassian.jira.plugi... ]
Luca Molteni updated DROOLS-2733:
---------------------------------
Sprint: 2019 Week 23-25 (was: 2019 Week 20-22)
> Support MVEL Dialect using custom inline accumulate code with external declarations in the executable model
> -----------------------------------------------------------------------------------------------------------
>
> Key: DROOLS-2733
> URL: https://issues.jboss.org/browse/DROOLS-2733
> Project: Drools
> Issue Type: Feature Request
> Components: executable model
> Reporter: Luca Molteni
> Assignee: Luca Molteni
> Priority: Optional
>
> The executable model doesn't support custom inline accumulate code that uses external declarations such as
> {code:java}
> String str = "import " + Person.class.getCanonicalName() + ";\n" +
> "rule R dialect \"mvel\" when\n" +
> " String( $l : length )" +
> " $sum : Integer() from accumulate (\n" +
> " Person( age > 18, $age : age ), init( int sum = 0 * $l; ), action( sum += $age; ), reverse( sum -= $age; ), result( sum )\n" +
> " )" +
> "then\n" +
> " insert($sum);\n" +
> "end";
> {code}
> (Notice that in the init we multiply the sum value with the length of string)
> But it can support such style using the "classic" generation of accumulate classes which gets compiled among the executable model and instantiate during the execution of the DSL.
> This mechanism is broken with the MVEL dialect, as we don't have such generated classes.
> Probably what we should do instead is putting MVEL expressions in the DSL directly such as
> {code:java}
> accumulateScript("initCode", "accCode", "reverseCode");
> {code}
> and then during interpretation create a new MVEL context and execute the accumulate in memory
> See
> AccumulateUnsupportedTest.testMVELAccumulate
> AccumulateUnsupportedTest.testMVELAccumulate2WM
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 7 months
[JBoss JIRA] (DROOLS-3066) NPE in Drools org.drools.core.rule.SingleAccumulate.reverse(SingleAccumulate.java:124)
by Luca Molteni (Jira)
[ https://issues.jboss.org/browse/DROOLS-3066?page=com.atlassian.jira.plugi... ]
Luca Molteni updated DROOLS-3066:
---------------------------------
Sprint: 2019 Week 23-25 (was: 2019 Week 20-22)
> NPE in Drools org.drools.core.rule.SingleAccumulate.reverse(SingleAccumulate.java:124)
> ---------------------------------------------------------------------------------------
>
> Key: DROOLS-3066
> URL: https://issues.jboss.org/browse/DROOLS-3066
> Project: Drools
> Issue Type: Bug
> Components: core engine
> Affects Versions: 7.4.1.Final
> Environment: Windows 7
> Oracle Java Development Kit 1.8.0_111
> Eclipse Oxygen 3a
> Optaplanner 7.4.1.Final
> Reporter: Philip Harding
> Assignee: Luca Molteni
> Priority: Major
> Attachments: NPE_Drools_MWE.zip
>
> Original Estimate: 2 days
> Remaining Estimate: 2 days
>
> The rule
> {code:java}
> rule "globalRequiredPredecessorAfterMe"
> when
> $rpAll: Set(size>1) from accumulate (
> Customer(Domicile != null, $rpAfterMe: requiredPredecessorsAfterMe);
> collectSet($rpAfterMe)
> )
> then
> scoreHolder.addMediumConstraintMatch(kcontext, - $rpAll.size()-1);
> end
> {code}
> gives following NPE within the attached Optaplanner model:
> {code:java}
> Exception in thread "main" java.lang.RuntimeException: java.lang.NullPointerException
> at org.drools.core.rule.SingleAccumulate.reverse(SingleAccumulate.java:124)
> at org.drools.core.phreak.PhreakAccumulateNode.removeMatch(PhreakAccumulateNode.java:796)
> at org.drools.core.phreak.PhreakAccumulateNode.doRightUpdatesProcessChildren(PhreakAccumulateNode.java:517)
> at org.drools.core.phreak.PhreakAccumulateNode.doRightUpdates(PhreakAccumulateNode.java:450)
> at org.drools.core.phreak.PhreakAccumulateNode.doNode(PhreakAccumulateNode.java:76)
> at org.drools.core.phreak.RuleNetworkEvaluator.switchOnDoBetaNode(RuleNetworkEvaluator.java:581)
> at org.drools.core.phreak.RuleNetworkEvaluator.evalBetaNode(RuleNetworkEvaluator.java:552)
> at org.drools.core.phreak.RuleNetworkEvaluator.evalNode(RuleNetworkEvaluator.java:379)
> at org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:339)
> at org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:175)
> at org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:133)
> at org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:212)
> at org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:87)
> at org.drools.core.concurrent.AbstractRuleEvaluator.internalEvaluateAndFire(AbstractRuleEvaluator.java:34)
> at org.drools.core.concurrent.SequentialRuleEvaluator.evaluateAndFire(SequentialRuleEvaluator.java:43)
> at org.drools.core.common.DefaultAgenda.fireLoop(DefaultAgenda.java:1067)
> at org.drools.core.common.DefaultAgenda.internalFireAllRules(DefaultAgenda.java:1014)
> at org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1006)
> at org.drools.core.impl.StatefulKnowledgeSessionImpl.internalFireAllRules(StatefulKnowledgeSessionImpl.java:1337)
> at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1328)
> at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1312)
> at org.optaplanner.core.impl.score.director.drools.DroolsScoreDirector.calculateScore(DroolsScoreDirector.java:117)
> at org.optaplanner.core.impl.score.director.AbstractScoreDirector.doAndProcessMove(AbstractScoreDirector.java:187)
> at org.optaplanner.core.impl.constructionheuristic.decider.ConstructionHeuristicDecider.doMove(ConstructionHeuristicDecider.java:126)
> at org.optaplanner.core.impl.constructionheuristic.decider.ConstructionHeuristicDecider.decideNextStep(ConstructionHeuristicDecider.java:100)
> at org.optaplanner.core.impl.constructionheuristic.DefaultConstructionHeuristicPhase.solve(DefaultConstructionHeuristicPhase.java:74)
> at org.optaplanner.core.impl.solver.AbstractSolver.runPhases(AbstractSolver.java:88)
> at org.optaplanner.core.impl.solver.DefaultSolver.solve(DefaultSolver.java:191)
> at canihazafischbroetchenplz.app.TestApp.main(TestApp.java:35)
> Caused by: java.lang.NullPointerException
> at org.drools.core.base.accumulators.CollectSetAccumulateFunction.reverse(CollectSetAccumulateFunction.java:118)
> at org.drools.core.base.accumulators.CollectSetAccumulateFunction.reverse(CollectSetAccumulateFunction.java:49)
> at org.drools.core.base.accumulators.JavaAccumulatorFunctionExecutor.reverse(JavaAccumulatorFunctionExecutor.java:133)
> at org.drools.core.rule.SingleAccumulate.reverse(SingleAccumulate.java:116)
> ... 28 more
> {code}
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 7 months
[JBoss JIRA] (JBCLUSTER-315) Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
by log an (Jira)
[ https://issues.jboss.org/browse/JBCLUSTER-315?page=com.atlassian.jira.plu... ]
log an updated JBCLUSTER-315:
-----------------------------
Description:
I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
"Failed to replicate session java.lang.NullPointerException"
Here is how did I configure jboss for session replication:
jboss-web.xml:
<replication-granularity>ATTRIBUTE</replication-granularity>
web.xml:
<distributable/>
Expected: Session should be replicated without NPE.
Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
java.lang.NullPointerException
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
at java.lang.Thread.run(Thread.java:682)
*Debugging details:*
I have debugged the application and found that one of the attribute value is null.
Here is the line throws NPE:
org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
return value;
}
Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
was:
I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
"Failed to replicate session java.lang.NullPointerException"
jboss-web.xml:
<replication-granularity>ATTRIBUTE</replication-granularity>
web.xml:
<distributable/>
Expected: Session should be replicated without NPE.
Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
java.lang.NullPointerException
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
at java.lang.Thread.run(Thread.java:682)
*Debugging details:*
I have debugged the application and found that one of the attribute value is null.
Here is the line throws NPE:
org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
return value;
}
Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
> Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
> -------------------------------------------------------------------------
>
> Key: JBCLUSTER-315
> URL: https://issues.jboss.org/browse/JBCLUSTER-315
> Project: JBoss Clustering
> Issue Type: Bug
> Components: HA-Server-Cache-JBC
> Affects Versions: HA-Server-Cache-JBC 2.0.3.Final
> Environment: jboss-eap-5.1
> Reporter: log an
> Assignee: Paul Ferraro
> Priority: Major
>
> I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
> "Failed to replicate session java.lang.NullPointerException"
> Here is how did I configure jboss for session replication:
> jboss-web.xml:
> <replication-granularity>ATTRIBUTE</replication-granularity>
> web.xml:
> <distributable/>
> Expected: Session should be replicated without NPE.
> Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
> Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
> java.lang.NullPointerException
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
> at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
> at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
> at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
> at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
> at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
> at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
> at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
> at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
> at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
> at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
> at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
> at java.lang.Thread.run(Thread.java:682)
> *Debugging details:*
> I have debugged the application and found that one of the attribute value is null.
> Here is the line throws NPE:
> org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
> if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
> return value;
> }
> Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 7 months
[JBoss JIRA] (JBCLUSTER-315) Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
by log an (Jira)
[ https://issues.jboss.org/browse/JBCLUSTER-315?page=com.atlassian.jira.plu... ]
log an updated JBCLUSTER-315:
-----------------------------
Description:
I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
"Failed to replicate session java.lang.NullPointerException"
jboss-web.xml:
<replication-granularity>ATTRIBUTE</replication-granularity>
web.xml:
<distributable/>
Expected: Session should be replicated without NPE.
Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
java.lang.NullPointerException
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
at java.lang.Thread.run(Thread.java:682)
*Debugging details:*
I have debugged the application and found that one of the attribute value is null.
Here is the line throws NPE:
org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
return value;
}
Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
was:
I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
"Failed to replicate session java.lang.NullPointerException"
jboss-web.xml:
<replication-granularity>ATTRIBUTE</replication-granularity>
web.xml:
<distributable/>
Expected: Session should be replicated without NPE.
Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
java.lang.NullPointerException
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
at java.lang.Thread.run(Thread.java:682)
Debugging details:
I have debugged the application and found that one of the attribute value is null.
Here is the line throws NPE:
org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
return value;
}
Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
> Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
> -------------------------------------------------------------------------
>
> Key: JBCLUSTER-315
> URL: https://issues.jboss.org/browse/JBCLUSTER-315
> Project: JBoss Clustering
> Issue Type: Bug
> Components: HA-Server-Cache-JBC
> Affects Versions: HA-Server-Cache-JBC 2.0.3.Final
> Environment: jboss-eap-5.1
> Reporter: log an
> Assignee: Paul Ferraro
> Priority: Major
>
> I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
> "Failed to replicate session java.lang.NullPointerException"
> jboss-web.xml:
> <replication-granularity>ATTRIBUTE</replication-granularity>
> web.xml:
> <distributable/>
> Expected: Session should be replicated without NPE.
> Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
> Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
> java.lang.NullPointerException
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
> at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
> at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
> at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
> at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
> at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
> at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
> at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
> at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
> at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
> at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
> at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
> at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
> at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
> at java.lang.Thread.run(Thread.java:682)
> *Debugging details:*
> I have debugged the application and found that one of the attribute value is null.
> Here is the line throws NPE:
> org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
> if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
> return value;
> }
> Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 7 months
[JBoss JIRA] (JBCLUSTER-315) Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
by log an (Jira)
log an created JBCLUSTER-315:
--------------------------------
Summary: Jboss 5.x ATTRIBUTE level session replication throws NullPointerException
Key: JBCLUSTER-315
URL: https://issues.jboss.org/browse/JBCLUSTER-315
Project: JBoss Clustering
Issue Type: Bug
Components: HA-Server-Cache-JBC
Affects Versions: HA-Server-Cache-JBC 2.0.3.Final
Environment: jboss-eap-5.1
Reporter: log an
Assignee: Paul Ferraro
I have JSF based web application deployed in Jboss 5.1 EAP server. Enabled the distributable tag for session replication across two jboss nodes with Apache web server for failover feature and my business requires Attribute level replication but the system throws NullPointerException.
"Failed to replicate session java.lang.NullPointerException"
jboss-web.xml:
<replication-granularity>ATTRIBUTE</replication-granularity>
web.xml:
<distributable/>
Expected: Session should be replicated without NPE.
Actual: Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
Failed to replicate session 9jYCBgKn2mIIVS2g8EzEzQ__.XXXX
java.lang.NullPointerException
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.getMarshalledValue(AbstractJBossCacheService.java:679)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:185)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AttributeBasedJBossCacheService.storeSessionAttributes(AttributeBasedJBossCacheService.java:40)
at org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.storeSessionData(AbstractJBossCacheService.java:402)
at org.jboss.web.tomcat.service.session.ClusteredSession.processSessionReplication(ClusteredSession.java:1192)
at org.jboss.web.tomcat.service.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:2221)
at org.jboss.web.tomcat.service.session.JBossCacheManager.storeSession(JBossCacheManager.java:321)
at org.jboss.web.tomcat.service.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:51)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:147)
at org.jboss.web.tomcat.service.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:94)
at org.jboss.web.tomcat.service.session.JvmRouteValve.invoke(JvmRouteValve.java:88)
at org.jboss.web.tomcat.service.session.LockingValve.invoke(LockingValve.java:62)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:451)
at java.lang.Thread.run(Thread.java:682)
Debugging details:
I have debugged the application and found that one of the attribute value is null.
Here is the line throws NPE:
org.jboss.web.tomcat.service.session.distributedcache.impl.jbc.AbstractJBossCacheService.class (Line no: 679)
if(MarshalledValueHelper.isTypeExcluded(value.getClass())) {
return value;
}
Please let me know if you need more detail. Also, I am trying to reproduce the issue with sample application but could not able to do. Kindly, provide some suggestions.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
6 years, 7 months