It's all about the answers!

Ask a question

JBE NoClassDefFoundError on CentOS 5


Christoph Treude (3141) | asked Sep 19 '08, 6:49 p.m.
retagged Dec 12 '12, 10:46 a.m. by SEC Servizi (97122652)
Hi,

I can't get my build engine (Standard Edition) to run on CentOS 5.

After running

java -cp plugins/org.eclipse.equinox.launcher_1.0.1.R33x_v20080118.jar org.eclipse.equinox.launcher.Main -application com.ibm.team.build.engine.jazzBuildEngine -repository http://XYZ:9080/jazz -userId xyz -pass xyz -engineId xyz

I'm getting the following output:

Running build loop...
Waiting for request...
java.lang.NoClassDefFoundError: org/xmlsoap/schemas/soap/envelope/Envelope
at com.ibm.team.repository.transport.client.RemoteTeamServer.createTeamService(RemoteTeamServer.java:296)
at com.ibm.team.repository.common.transport.AbstractTeamServer.getService(AbstractTeamServer.java:94)
at com.ibm.team.repository.client.internal.TeamRepository.getTeamService(TeamRepository.java:1397)
at com.ibm.team.repository.client.internal.TeamRepository.getServiceInterface(TeamRepository.java:1084)
at com.ibm.team.repository.client.internal.TeamRepository.<init>(TeamRepository.java:334)
at com.ibm.team.repository.client.internal.TeamRepositoryService.getTeamRepository(TeamRepositoryService.java:82)
at com.ibm.team.repository.client.internal.TeamRepositoryService.getUnmanagedRepository(TeamRepositoryService.java:119)
at com.ibm.team.build.internal.engine.BuildLoop.getTeamRepository(BuildLoop.java:990)
at com.ibm.team.build.internal.engine.BuildLoop.runLoop(BuildLoop.java:206)
at com.ibm.team.build.internal.engine.BuildLoop$1.run(BuildLoop.java:161)
at java.lang.Thread.run(Thread.java:595)

I've tried to add all kinds of jars to the classpath (in particular buildsystem/buildtoolkit/com.ibm.team.repository.common.transport_0.6.0.I200805291754.jar as it's supposed to include Envelope), but it doesn't change anything.

Any idea on what I could try? Let me know if there's any more information I should provide.

Thanks,
Christoph

8 answers



permanent link
Ryan Manwiller (1.3k1) | answered Sep 22 '08, 6:34 p.m.
JAZZ DEVELOPER
I really don't have a good answer for you. Your invocation of the build
engine looks good. You should not need to add any other jars (besides the
equinox launcher) to the classpath.

Can I assume your working dir when running the command is
"path_to_buildsystem\buildengine\eclipse" ?

One thing that may give us more information is to run the 'ss' command in
the osgi console. Add the -console argument before -repository, like this:

java -cp
path_to_buildsystem\buildengine\eclipse\plugins\org.eclipse.equinox.launcher_1.0.1.R33x_v20080118.jar
org.eclipse.equinox.launcher.Main -application
com.ibm.team.build.engine.jazzBuildEngine -console -repository ....

After running the command, wait a few seconds, then type ss and enter

This should show the state of all the bundles. When I do this, the
repository.common.transport bundle is in the ACTIVE state. I wonder if yours
is any different?

23 ACTIVE
com.ibm.team.repository.common.transport_0.6.0.I200805291754

In fact, if you can reply with the entire output of the ss, it might be
helpful.

---
Ryan Manwiller
Jazz Team

permanent link
Christoph Treude (3141) | answered Sep 24 '08, 6:28 p.m.
Thanks for your reply.

My working dir when running the command is indeed "path_to_buildsystem/buildengine/eclipse". I've attached the entire output of the ss command. It turns out that the repository.common.transport bundle is <<LAZY>> (id 68).

Any idea what I could do?

Thanks,
Christoph

----

Framework is launched.

id State Bundle
0 ACTIVE org.eclipse.osgi_3.3.2.R33x_v20080105
1 ACTIVE org.eclipse.equinox.common_3.3.0.v20070426
2 ACTIVE org.eclipse.update.configurator_3.2.101.R33x_v20070810
3 ACTIVE org.eclipse.core.runtime_3.3.100.v20070530
4 ACTIVE com.ibm.team.repository.common.serialize_0.6.0.I200805291754
5 <<LAZY>> com.ibm.team.process.common_0.6.0.I200805300008
6 RESOLVED org.apache.log4j_1.2.12
7 RESOLVED org.eclipse.core.resources_3.3.1.R33x_v20080205
Fragments=60
8 <<LAZY>> org.eclipse.emf.ecore.xmi_2.3.2.v200802051830
9 <<LAZY>> com.ibm.team.workitem.common_0.6.0.I200806111021
10 <<LAZY>> org.eclipse.xsd_2.3.2.v200802051830
13 RESOLVED com.ibm.team.fulltext.common_0.6.0.I200805281605
14 RESOLVED org.eclipse.osgi.services_3.1.200.v20070605
15 RESOLVED org.apache.ant_1.7.0.v200706080842
16 ACTIVE org.eclipse.equinox.registry_3.3.1.R33x_v20070802
Fragments=30
17 RESOLVED com.ibm.team.build.engine_0.6.0.I200806112316
18 RESOLVED org.eclipse.text_3.3.0.v20070606-0010
19 ACTIVE org.eclipse.core.runtime.compatibility.auth_3.2.100.v20070502
20 <<LAZY>> com.ibm.team.process.client_0.6.0.I200805300008
22 <<LAZY>> org.eclipse.core.expressions_3.3.0.v20070606-0010
23 RESOLVED org.eclipse.equinox.launcher_1.0.1.R33x_v20080118
24 ACTIVE com.ibm.team.scm.common_0.6.0.I200805272116
25 RESOLVED org.mortbay.jetty_5.1.11.v200706111724
26 <<LAZY>> org.eclipse.emf.commonj.sdo_2.3.0.v200802051830
27 <<LAZY>> org.eclipse.ant.core_3.1.200.v20070522
29 RESOLVED com.ibm.team.repository.common.json_0.6.0.I200805291754
30 RESOLVED org.eclipse.core.runtime.compatibility.registry_3.2.100.v20070316
Master=16
31 <<LAZY>> com.ibm.team.filesystem.client_0.6.0.I200805272116
32 RESOLVED org.eclipse.osgi.util_3.1.200.v20070605
33 RESOLVED org.eclipse.emf.ecore_2.3.2.v200802051830
34 <<LAZY>> org.eclipse.core.variables_3.2.0.v20070426
35 ACTIVE org.eclipse.equinox.preferences_3.2.101.R33x_v20080117
36 <<LAZY>> com.ibm.team.foundation.common_0.6.0.I200806111021
37 <<LAZY>> com.ibm.team.workitem.client_0.6.0.I200806111021
38 <<LAZY>> org.eclipse.core.filesystem_1.1.0.v20070606
39 RESOLVED org.eclipse.core.commands_3.3.0.I20070605-0010
40 RESOLVED com.ibm.team.repository.common.remoteaccess.auth_0.6.0.I200805291754
41 RESOLVED org.apache.commons.logging_1.0.5.jazz
42 RESOLVED com.ibm.team.build.client_0.6.0.I200805282208
43 <<LAZY>> com.ibm.icu_3.6.1.v20070906
44 <<LAZY>> org.eclipse.emf.ecore.change_2.3.0.v200802051830
45 <<LAZY>> org.eclipse.emf.ecore.sdo_2.3.0.v200802051830
46 RESOLVED com.ibm.team.scm.client_0.6.0.I200805272116
47 ACTIVE org.eclipse.core.jobs_3.3.1.R33x_v20070709
48 ACTIVE com.ibm.team.repository.common_0.6.0.I200806122105
49 ACTIVE org.eclipse.emf.common_2.3.2.v200802051830
50 RESOLVED org.apache.commons.codec_1.3.0
51 INSTALLED org.eclipse.core.filesystem.win32.x86_1.1.0.v20070510
52 RESOLVED com.ibm.team.foundation.client_0.6.0.I200805281605
53 <<LAZY>> com.ibm.team.foundation.rcp.core_0.6.0.I200805281605
54 RESOLVED com.ibm.team.build.common_0.6.0.I200806102218
55 RESOLVED javax.servlet_2.4.0.v200706111738
56 RESOLVED com.ibm.team.repository.common.remoteaccess_0.6.0.I200805291754
57 ACTIVE com.ibm.team.repository.client_0.6.0.I200805292304
58 RESOLVED com.ibm.team.filesystem.common.workitems_0.6.0.I200805272116
59 <<LAZY>> com.ibm.team.filesystem.common_0.6.0.I200805272116
60 RESOLVED org.eclipse.core.resources.compatibility_3.2.100.v20070502
Master=7
61 ACTIVE org.eclipse.equinox.app_1.0.1.R33x_v20070828
62 INSTALLED org.eclipse.core.resources.win32_3.3.0.v20070226
63 <<LAZY>> org.eclipse.core.contenttype_3.2.100.v20070319
64 RESOLVED com.ibm.team.build.toolkit_0.6.0.I200806052245
65 INSTALLED org.eclipse.equinox.launcher.win32.win32.x86_1.0.3.R33x_v20080118
66 RESOLVED org.apache.commons.httpclient_3.0.0
67 INSTALLED org.eclipse.equinox.launcher.gtk.linux.x86_1.0.3.R33x_v20080118
68 <<LAZY>> com.ibm.team.repository.common.transport_0.6.0.I200805291754

permanent link
Ryan Manwiller (1.3k1) | answered Sep 25 '08, 4:35 p.m.
JAZZ DEVELOPER
In the osgi console, after doing ss, try doing diag <bundle>. So in
your example output, diag 68

If it says something like some other bundle is not resolved, diag that
bundle. Basically try to get down the root cause of what is missing or in a
bad state.

Maybe its worth re-unzipping the buildsystem just to make sure we have a
valid installation.

When I unzip the RTC-BuildSystemToolkit-1.0-Linux.zip, I end up with 57
jars, and 8 directories under \buildsystem\buildengine\eclipse\plugins

permanent link
Christoph Treude (3141) | answered Sep 25 '08, 7:56 p.m.
The diag command didn't reveal any unresolved bundles:

osgi> diag 68
update@plugins/com.ibm.team.repository.common.transport_0.6.0.I200805291754.jar
No unresolved constraints.

Also, the number of jars and directories is the same that you posted.

I will request the buildsystem to be unzipped again.

permanent link
Christoph Treude (3141) | answered Oct 14 '08, 5:06 p.m.
After the build system was unzipped again in a new location, running jbe now gives the following pop-up window:

JVM terminated. Exit code=13
/usr/java5/bin/java
-Dosgi.requiredJavaVersion=1.5
-jar /opt/Public/opt/IBM/JazzTeamServer/buildsystem/buildengine/eclipse/plugins/org.eclipse.equinox.launcher_1.0.1.R33x_v20080118.jar
-os linux
-ws gtk
-arch x86
-showsplash
-launcher /opt/Public/opt/IBM/JazzTeamServer/buildsystem/buildengine/eclipse/jbe
-name Jbe
--launcher.library /opt/Public/opt/IBM/JazzTeamServer/buildsystem/buildengine/eclipse/plugins/org.eclipse.equinox.launcher.gtk.linux.x86_1.0.3.R33x_v20080118/eclipse_1023.so
-startup /opt/Public/opt/IBM/JazzTeamServer/buildsystem/buildengine/eclipse/plugins/org.eclipse.equinox.launcher_1.0.1.R33x_v20080118.jar
-exitdata 38a0008
-repository XYZ
-userId XYZ
-pass XYZ
-engineId XYZ
-vm /usr/java5/bin/java
-vmargs
-Dosgi.requiredJavaVersion=1.5
-jar /opt/Public/opt/IBM/JazzTeamServer/buildsystem/buildengine/eclipse/plugins/org.eclipse.equinox.launcher_1.0.1.R33x_v20080118.jar

I haven't been able to figure out what causes this -- especially since I didn't get this error with the previous installation which was done from the same zip file.

Any ideas?

Thanks,
Christoph

permanent link
Ryan Manwiller (1.3k1) | answered Oct 14 '08, 7:08 p.m.
JAZZ DEVELOPER
Here are a few things to check:

Under buildsystem/buildengine/eclipse is there a configuration directory?
Are there any log files there? They sometimes contain the error.

Try using a jdk instead of jre

Try using the -vm argument at the end of your jbe command line to point
directly at the jdk/bin/java executable

Try making sure the java found on your PATH is the same as JAVA_HOME

What's the version/vender of the jre you are using?

permanent link
SEC Servizi (97122652) | answered Dec 12 '12, 10:38 a.m.
edited Dec 12 '12, 10:41 a.m.
 We got a similar exception:
java.lang.NoClassDefFoundError: org/eclipse/jface/text/BadLocationException
when JBE process launches an Ant script which executes a JAR:
        [...]
        < path id="libraries">
<fileset file="${jar.file}" />
<fileset dir="${userlib.dir}">
<include name="*.jar" />
        </fileset>
< /path>
<taskdef name="Response" classname="it.secservizi.rtc.util.deploy.ant.Response" classpathref="libraries" />
<Response buildResultUUID="${buildResultUUID}" />
[...]
where ${jar.file} is the path to our JAR and ${userlib.dir} is the Plain Java Client folder.
We found the "org.eclipse.jface.text.BadLocationException" class into the "/jazz/client/plainjava/org.eclipse.text_3.4.0.v20080605-1800.jar" file (i.e., in the ${userlib.dir} folder), so we cannot understand why a "java.lang.NoClassDefFoundError" exception was thrown.

We use log4j to log our JAR classes. No logs are written to file when our JAR is executed by the JBE process. Instead, logger works as expected if the Ant script are manually launched using the same "jazz\buildsystem\buildengine\eclipse\plugins\org.apache.ant_1.7.0.v200803061910" binary.

We are using RTC v2.0.0.2iFix6.
Any advice? Thanks in advance.

permanent link
SEC Servizi (97122652) | answered Dec 12 '12, 11:05 a.m.
 If we deselect option "Include the Jazz build toolkit tasks on the Ant library path" on the Build Defintions, all works as expected.
Could it be a bug?

Your answer


Register or to post your answer.