Hi I just started using JackRabbit and most things seem to work fine. I experimented a bit with the TransientRepository and tried to switch to the standalone server afterwards. When trying to create new users I need the JAckRabbitSession-Object but I get a ClassCastException.

How to resolve this? I found some topics about this problem but neither of them had provided a solution.

Best regards
Pascal Knüppel

java.lang.ClassCastException: org.apache.jackrabbit.jcr2spi.SessionImpl cannot be cast to org.apache.jackrabbit.api.JackrabbitSession at de.fiverx.intern.contentrepository.JackRabbitClient.createNewUser(JackRabbitClient.java:49) at de.fiverx.intern.contentrepository.JackRabbitClientTest.testJackRabbitSessionProducer(JackRabbitClientTest.java:33)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
    at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
    at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
    at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
    at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
    at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
    at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
    at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
    at org.junit.runner.JUnitCore.run(JUnitCore.java:160)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:78) at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:212) at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:68)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:140)

--
Mit freundlichen Grüßen

Pascal Knüppel
------------
Dipl. Informatiker
Entwicklung

NARZ/AVN Apothekenpartner
E-Mail     : [email protected]
Internet  : www.narz-avn.de
Im Serviceverbund mit der GfI   
GfI Gesellschaft für Informations- und Datenverarbeitung mbH, Bauerland 3, 
28259 Bremen
Gerichtsstand     : Amtsgericht Bremen, HRB 10857 HB
Geschäftsführer: Dipl.-Volkswirt Hanno Helmker, Uwe Ennen

Reply via email to