tar-file repository error with jackrabbit oak - java

i am working since a few months with jackrabbit oak. While everything works fine with MongoDB as backend, i got problems by using a tar file based Segment NodeStore.
Here, working just with nt:folder nodes works like with MongoDB, but when i try to handle files (nt:file) i get following error massage (when writing nodes to repository):
java.lang.NoSuchMethodError: com.google.common.io.ByteStreams.equal(Lcom/google/common/io/InputSupplier;Lcom/google/common/io/InputSupplier;)Z
at org.apache.jackrabbit.oak.plugins.memory.AbstractBlob.equal(AbstractBlob.java:68)
at org.apache.jackrabbit.oak.plugins.segment.SegmentBlob.equals(SegmentBlob.java:217)
at com.google.common.base.Objects.equal(Objects.java:60)
at org.apache.jackrabbit.oak.plugins.memory.AbstractPropertyState.equal(AbstractPropertyState.java:53)
at org.apache.jackrabbit.oak.plugins.memory.AbstractPropertyState.equals(AbstractPropertyState.java:90)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:748)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:726)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:726)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:726)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:726)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter$ChildNodeCollectorDiff.childNodeChanged(SegmentWriter.java:877)
at org.apache.jackrabbit.oak.plugins.memory.ModifiedNodeState.compareAgainstBaseState(ModifiedNodeState.java:416)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter$ChildNodeCollectorDiff.diff(SegmentWriter.java:892)
at org.apache.jackrabbit.oak.plugins.segment.SegmentWriter.writeNode(SegmentWriter.java:714)
at org.apache.jackrabbit.oak.plugins.segment.SegmentNodeBuilder.getNodeState(SegmentNodeBuilder.java:111)
at org.apache.jackrabbit.oak.plugins.segment.SegmentNodeStore.rebase(SegmentNodeStore.java:269)
at org.apache.jackrabbit.oak.core.MutableRoot.rebase(MutableRoot.java:223)
at org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate.refresh(SessionDelegate.java:506)
at org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate.prePerform(SessionDelegate.java:611)
at org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate.perform(SessionDelegate.java:205)
at org.apache.jackrabbit.oak.jcr.session.ItemImpl.perform(ItemImpl.java:112)
at org.apache.jackrabbit.oak.jcr.session.NodeImpl.internalSetProperty(NodeImpl.java:1363)
at org.apache.jackrabbit.oak.jcr.session.NodeImpl.setProperty(NodeImpl.java:506)
at org.opencms.file.OnOffRepoCustomUnique.putResource(OnOffRepoCustomUnique.java:1229)
at org.opencms.file.OnOffRepoTest.testVersioning(OnOffRepoTest.java:873)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at junit.framework.TestCase.runTest(TestCase.java:176)
at junit.framework.TestCase.runBare(TestCase.java:141)
at junit.framework.TestResult$1.protect(TestResult.java:122)
at junit.framework.TestResult.runProtected(TestResult.java:142)
at junit.framework.TestResult.run(TestResult.java:125)
at junit.framework.TestCase.run(TestCase.java:129)
at junit.framework.TestSuite.runTest(TestSuite.java:252)
at junit.framework.TestSuite.run(TestSuite.java:247)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:86)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
it seems to be a problem with guava.. Is this a bug in oak or it is my fault? But where could the problem be?

Most probably you have multiple / invalid versions of Guava in your classpath. Please check what does mvn dependency:tree print regarding Guava.

Related

Simple Stateless with Descriptor: ClassNotFoundException: LocalInitialContextFactory

I'm beginning to lean EJB, and I'm trying to run the sample: http://openejb.apache.org/examples-trunk/simple-stateless-with-descriptor/README.html
...and I got:
javax.naming.NoInitialContextException: Cannot instantiate class: simpleStatelessWithDescriptor.LocalInitialContextFactory [Root exception is java.lang.ClassNotFoundException: simpleStatelessWithDescriptor.LocalInitialContextFactory]
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:657)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
at javax.naming.InitialContext.init(InitialContext.java:223)
at javax.naming.InitialContext.<init>(InitialContext.java:197)
at simpleStatelessWithDescriptor.CalculatorTest.setUp(CalculatorTest.java:17)
at junit.framework.TestCase.runBare(TestCase.java:139)
at junit.framework.TestResult$1.protect(TestResult.java:122)
at junit.framework.TestResult.runProtected(TestResult.java:142)
at junit.framework.TestResult.run(TestResult.java:125)
at junit.framework.TestCase.run(TestCase.java:129)
at junit.framework.TestSuite.runTest(TestSuite.java:252)
at junit.framework.TestSuite.run(TestSuite.java:247)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:86)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
Caused by: java.lang.ClassNotFoundException: simpleStatelessWithDescriptor.LocalInitialContextFactory
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:249)
at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:46)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:654)
... 18 more
My file tree is:
I searched and replaced in all file the package names to meet the file tree.
Now, what's still missing? Why it can't find the LocalInitialContextFactory?
I'm on Windows 10 64bits, Eclipse Neon, java 6 (can't update for now).
simpleStatelessWithDescriptor.LocalInitialContextFactory doesn't exist in your classes and you should not declare it.
You should use org.apache.openejb.core.LocalInitialContextFactory if you follow the example. You have not the class in your classpath because I imagine you have not added it. Adding each needed library may be long and complex.
You should use the pom.xml as proposed in the example.
Some advices if I can :
Install Maven, learn the basis to use it, checkout the project from scratch and build it with Maven:
http://svn.apache.org/repos/asf/tomee/tomee/trunk/examples/simple-stateless-with-descriptor/

upgrading hazelcast to > 3.2.5 results in: PortableFactory[-19] is already registered

When I use hazelcast 3.2.5 in my pom.xml everything is working very well. But when I change the hazelcast version to 3.3.1 or to 3.4 then I will get the following error.
Googeling this error message does not give me any hint. So have you seen this message before and how can I fix this?
java.lang.IllegalArgumentException: PortableFactory[-19] is already registered! com.hazelcast.client.txn.ClientTxnPortableHook$1#2cb4c3ab -> com.hazelcast.transaction.client.ClientTxnPortableHook$1#13c78c0b
at com.hazelcast.nio.serialization.PortableHookLoader.register(PortableHookLoader.java:84)
at com.hazelcast.nio.serialization.PortableHookLoader.load(PortableHookLoader.java:51)
at com.hazelcast.nio.serialization.PortableHookLoader.<init>(PortableHookLoader.java:41)
at com.hazelcast.nio.serialization.SerializationServiceImpl.<init>(SerializationServiceImpl.java:85)
at com.hazelcast.nio.serialization.SerializationServiceBuilder.build(SerializationServiceBuilder.java:174)
at com.hazelcast.instance.Node.<init>(Node.java:158)
at com.hazelcast.instance.HazelcastInstanceImpl.<init>(HazelcastInstanceImpl.java:95)
at com.hazelcast.instance.HazelcastInstanceFactory.constructHazelcastInstance(HazelcastInstanceFactory.java:147)
at com.hazelcast.instance.HazelcastInstanceFactory.newHazelcastInstance(HazelcastInstanceFactory.java:130)
at com.hazelcast.instance.HazelcastInstanceFactory.newHazelcastInstance(HazelcastInstanceFactory.java:107)
at com.hazelcast.core.Hazelcast.newHazelcastInstance(Hazelcast.java:87)
at kic.engine.main.MQLFactory.getHazelcastInstance(MQLFactory.java:54)
at kic.engine.v3.gramar.ParserTest.testConfig(ParserTest.java:19)
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.RunBefores.evaluate(RunBefores.java:24)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
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:74)
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:211)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:67)
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:134)
I think I have found the problem in the classpath. My ide contained both hazelcasts 3.2.5 and 3.4 in the classpath. Usually my ide is smater than I but not this time :-)

Windows Azure Java SDK keystore path issue

I am trying to setup Windows Azure Java SDK in Windows 7 machine
followed their Wiki setup page
https://github.com/Azure/azure-sdk-for-java/wiki/Devbox-Setup
when I run test cases/ trying to access Azure REST webservice URLS, getting below error.
set management.keystore.path=E:/Program Files (x86)/Java/jdk1.7.0_51/jre/lib/security/clientcert.jks
Windows Azure Java SDK keystore path issue
java.lang.IllegalArgumentException: The keystore path cannot be null or empty.
at com.microsoft.windowsazure.core.utils.SSLContextFactory.create(SSLContextFactory.java:86)
at com.microsoft.windowsazure.core.utils.SSLContextFactory.create(SSLContextFactory.java:60)
at com.microsoft.windowsazure.credentials.CertificateCloudCredentials.applyConfig(CertificateCloudCredentials.java:128)
at com.microsoft.windowsazure.core.pipeline.apache.Exports$2.create(Exports.java:51)
at com.microsoft.windowsazure.core.pipeline.apache.Exports$2.create(Exports.java:1)
at com.microsoft.windowsazure.core.DefaultBuilder.build(DefaultBuilder.java:200)
at com.microsoft.windowsazure.core.pipeline.apache.Exports$3.create(Exports.java:65)
at com.microsoft.windowsazure.core.pipeline.apache.Exports$3.create(Exports.java:1)
at com.microsoft.windowsazure.core.DefaultBuilder.build(DefaultBuilder.java:200)
at com.microsoft.windowsazure.core.DefaultBuilder$1.create(DefaultBuilder.java:138)
at com.microsoft.windowsazure.core.DefaultBuilder.build(DefaultBuilder.java:200)
at com.microsoft.windowsazure.Configuration.create(Configuration.java:113)
at com.microsoft.windowsazure.management.storage.StorageManagementService.create(StorageManagementService.java:47)
at com.microsoft.windowsazure.management.compute.ComputeManagementIntegrationTestBase.createStorageManagementClient(ComputeManagementIntegrationTestBase.java:63)
at com.microsoft.windowsazure.management.compute.VirtualMachineOperationsTests.setup(VirtualMachineOperationsTests.java:61)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
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.RunBefores.evaluate(RunBefores.java:24)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
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)
java.lang.NullPointerException
at com.microsoft.windowsazure.management.compute.VirtualMachineOperationsTests.cleanHostedService(VirtualMachineOperationsTests.java:452)
at com.microsoft.windowsazure.management.compute.VirtualMachineOperationsTests.cleanup(VirtualMachineOperationsTests.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
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.RunAfters.evaluate(RunAfters.java:33)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
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)
Try switching to the latest release of the Java SDK. I wrote up a very basic how-to guide on getting going with it here that might help you get past your JKS issue. Looks like the namespaces you're using are from an earlier release.
http://azure.microsoft.com/blog/2014/09/15/getting-started-with-the-azure-java-management-libraries/

Error trying to test XML parsing with Robolectric

I'm using Robolectric and trying to test parsing a XML response. I'm getting the following exception:
java.lang.NoClassDefFoundError: java/lang/AutoCloseable
at android.util.Xml.parse(Xml.java:80)
at com.test.app.network.parser.soap.BaseSoapParser.doParse(BaseSoapParser.java:57)
at com.test.app.network.parser.soap.RecipeParser.parse(RecipeParser.java:57)
at com.test.app.network.command.RecipeCommand.searchRecipes(RecipeCommand.java:64)
at com.test.app.data.PrepopulateDB.prepopulateDB(PrepopulateDB.java:53)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at org.robolectric.RobolectricTestRunner$2.evaluate(RobolectricTestRunner.java:230)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
at org.robolectric.RobolectricTestRunner$1.evaluate(RobolectricTestRunner.java:172)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
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: java.lang.ClassNotFoundException: java.lang.AutoCloseable
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.robolectric.bytecode.AsmInstrumentingClassLoader.loadClass(AsmInstrumentingClassLoader.java:100)
at android.util.Xml.$$robo$$Xml_e8aa_parse(Xml.java:80)
at android.util.Xml.parse(Xml.java)
at com.test.app.network.parser.soap.BaseSoapParser.doParse(BaseSoapParser.java:57)
at com.test.test.app.network.parser.soap.RecipeParser.parse(RecipeParser.java:57)
at com.test.app.network.command.RecipeCommand.searchRecipes(RecipeCommand.java:64)
at com.test.app.data.PrepopulateDB.prepopulateDB(PrepopulateDB.java:53)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
... 22 more
The thing is that "AutoCloseable" was only added in Java 7 and since Android uses Java 6 I can understand why the class isn't found - any help will be appreciated.
Libraries:
robolectric-2.3-20140204.032758-112-jar-with-dependencies.jar
android-all-4.4_r1-robolectric-0.jar /
android-all-4.3_r2-robolectric-0.jar
Update:
I tested this using JDK 6 and Target API 18 with the same result.
Update 2:
It seems that the source of the problem is this class: org.apache.harmony.xml.ExpatReader it is using AutoClosable which isn't available on Java 6 or Android API 18.
Actually this interface is in the Android SDK : https://developer.android.com/reference/java/lang/AutoCloseable.html
Added in API level 19
Before level 19, it was there but "hidden".
This error happens when you compile your project with a higher API version than some of your required classes, your target is API 18, but as Guillaume sais, when you use AutoCloseable you're trying to load a class which is not added until API 19. So your application crashes at runtime. You need to modify your minSDK version of your project or consider an alternative.
Download the SDK bundle [1], extract it and then update/overwrite your Eclipse and Android SDK (just make a backup copy of eclipse and android-sdk folder beforehand).
Of course afterwards make all the necessary updates within the SDK and Eclipse IDE
[1] https://developer.android.com/sdk/index.html

NullPointerException when calling webservice in Weblogic 9.2

I am trying to call a webservice. The client was generated with weblogic's ant task clientgen. But when I use the client, following exception happens:
java.lang.ExceptionInInitializerError
at com.bea.xbean.xb.xsdschema.SchemaDocument$Factory.parse(SchemaDocument.java:799)
at weblogic.wsee.wsdl.WsdlSchema.parse(WsdlSchema.java:104)
at weblogic.wsee.wsdl.WsdlSchema.parse(WsdlSchema.java:73)
at weblogic.wsee.wsdl.WsdlTypes.parse(WsdlTypes.java:165)
at weblogic.wsee.wsdl.WsdlDefinitions.parseChild(WsdlDefinitions.java:480)
at weblogic.wsee.wsdl.WsdlExtensible.parse(WsdlExtensible.java:98)
at weblogic.wsee.wsdl.WsdlDefinitions.parse(WsdlDefinitions.java:428)
at weblogic.wsee.wsdl.WsdlDefinitions.parse(WsdlDefinitions.java:385)
at weblogic.wsee.wsdl.WsdlFactory.parse(WsdlFactory.java:78)
at weblogic.wsee.wsdl.WsdlFactory.parse(WsdlFactory.java:65)
at weblogic.wsee.jaxrpc.ServiceImpl.loadWsdlDefinition(ServiceImpl.java:437)
at weblogic.wsee.jaxrpc.ServiceImpl.<init>(ServiceImpl.java:108)
[...]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
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:232)
at junit.framework.TestSuite.run(TestSuite.java:227)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:46)
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: java.lang.NullPointerException
at com.bea.xml.XmlBeans.typeSystemForClassLoader(XmlBeans.java:769)
at com.bea.xbean.xb.xsdschema.SchemaDocument.<clinit>(SchemaDocument.java:19)
... 36 more
Does anybody know what could be the problem?
I found the solution. It was a classpath problem. I needed the following jars on my classpath:
weblogic.jar
weblogic-container-binding.jar
xbean.jar
stax-api-1.0.1.jar
webservices.jar
ant.jar
There is one more way to fix this issue.
Include under and add all weblogic server library jars in build.xml
Run setDomainEnv of your domain directory.
Now build webserivces.

Categories

Resources