[
https://issues.jboss.org/browse/GTNPORTAL-2710?page=com.atlassian.jira.pl...
]
RH Bugzilla Integration commented on GTNPORTAL-2710:
----------------------------------------------------
Boleslaw Dawidowicz <bdawidow(a)redhat.com> changed the Status of [bug
957700|https://bugzilla.redhat.com/show_bug.cgi?id=957700] from NEW to ASSIGNED
Context not removed from ChromatticLifeCycle#currenctContext if an
exception is thrown in AbstractContext#close
---------------------------------------------------------------------------------------------------------------
Key: GTNPORTAL-2710
URL:
https://issues.jboss.org/browse/GTNPORTAL-2710
Project: GateIn Portal
Issue Type: Bug
Security Level: Public(Everyone can see)
Reporter: Stian Thorgersen
Assignee: Minh Hoang TO
Labels: done, portal-s70
Fix For: 3.6.0.Beta02
Original Estimate: 4 hours
Remaining Estimate: 4 hours
If ChromatticLifeCycle#closeContext is called with save=true and a failure occurs the
context is not removed from ChromatticLifeCycle#currenctContext. This is caused by
AbstractContext#close only calling lifeCycle.currentContext.set(null); if no exception is
thrown.
This can be reproduced by running test specified in GTNPORTAL-2711. When this test is run
the first test fails with the failure specified in that JIRA issue. However, the rest of
the tests fails with the failure in this issue.
Stack trace:
{code}
org.chromattic.api.UndeclaredRepositoryException: javax.jcr.RepositoryException: This
kind of operation is forbidden after a session.logout().
at org.chromattic.core.DomainSession.findByPath(DomainSession.java:199)
at
org.chromattic.core.api.ChromatticSessionImpl.findByPath(ChromatticSessionImpl.java:228)
at
org.exoplatform.portal.gadget.core.GadgetTokenInfoService$TokenTask.getGadgetTokenContainer(GadgetTokenInfoService.java:149)
at
org.exoplatform.portal.gadget.core.GadgetTokenInfoService$1.execute(GadgetTokenInfoService.java:55)
at
org.exoplatform.portal.gadget.core.GadgetTokenInfoService$1.execute(GadgetTokenInfoService.java:1)
at
org.exoplatform.portal.gadget.core.GadgetTokenInfoService$TokenTask.execute(GadgetTokenInfoService.java:165)
at
org.exoplatform.commons.chromattic.ContextualTask.executeWith(ContextualTask.java:54)
at
org.exoplatform.portal.gadget.core.GadgetTokenInfoService.createToken(GadgetTokenInfoService.java:59)
at
org.exoplatform.portal.gadget.TestGadgetTokenInfoService.createTokens(TestGadgetTokenInfoService.java:69)
at
org.exoplatform.portal.gadget.TestGadgetTokenInfoService.testSize(TestGadgetTokenInfoService.java:117)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at
org.exoplatform.component.test.AbstractGateInTest.runBare(AbstractGateInTest.java:91)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: javax.jcr.RepositoryException: This kind of operation is forbidden after a
session.logout().
at org.exoplatform.services.jcr.impl.core.SessionImpl.checkLive(SessionImpl.java:917)
at org.exoplatform.services.jcr.impl.core.SessionImpl.getRootNode(SessionImpl.java:760)
at org.chromattic.core.DomainSessionImpl._getRoot(DomainSessionImpl.java:809)
at org.chromattic.core.DomainSessionImpl._findByPath(DomainSessionImpl.java:115)
at org.chromattic.core.DomainSession.findByPath(DomainSession.java:196)
... 29 more
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira