It's all about the answers!

Ask a question

What jar files are needed for this Error message


vasanthakumari hariharan (2323) | asked Feb 13 '17, 5:02 a.m.
edited Feb 13 '17, 5:34 a.m. by Ralph Schoon (63.1k33646)

 Hi,

RTC(5.0.2) When i run my project  in java perspective , i came up with this error,

Exception in thread "main" java.lang.NoClassDefFoundError: com.ibm.team.calm.foundation.common.internal.rest.dto.RestPackage
at com.ibm.team.workitem.common.internal.web.rest.dto.impl.RestPackageImpl.init(RestPackageImpl.java:449)
at com.ibm.team.workitem.common.internal.web.rest.dto.RestPackage.<clinit>(RestPackage.java:69)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:201)
at sun.misc.Unsafe.ensureClassInitialized(Native Method)
at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:37)
at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:134)
at java.lang.reflect.Field.acquireFieldAccessor(Field.java:945)
at java.lang.reflect.Field.getFieldAccessor(Field.java:912)
at java.lang.reflect.Field.get(Field.java:371)
at com.ibm.team.repository.common.internal.util.InternalTeamPlatform$1.handleExtensionAdded(InternalTeamPlatform.java:284)
at com.ibm.team.repository.common.util.ExtensionReader.internalReadElement(ExtensionReader.java:202)
at com.ibm.team.repository.common.util.ExtensionReader.readRegistry(ExtensionReader.java:350)
at com.ibm.team.repository.common.util.ExtensionReader.start(ExtensionReader.java:380)
at com.ibm.team.repository.common.util.ExtensionReader.earlyStart(ExtensionReader.java:127)
at com.ibm.team.repository.common.internal.util.InternalTeamPlatform.initializeGeneratedPackages(InternalTeamPlatform.java:317)
at com.ibm.team.repository.common.internal.util.InternalTeamPlatform.start(InternalTeamPlatform.java:108)
at com.ibm.team.repository.client.TeamPlatform.startup(TeamPlatform.java:50)
at com.ibm.js.team.admin.automation.absence.csv.ScheduledAbsenceCSVImporter.main(ScheduledAbsenceCSVImporter.java:86)
Caused by: java.lang.ClassNotFoundException: com.ibm.team.calm.foundation.common.internal.rest.dto.RestPackage
at java.net.URLClassLoader.findClass(URLClassLoader.java:434)
at java.lang.ClassLoader.loadClass(ClassLoader.java:677)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:358)
at java.lang.ClassLoader.loadClass(ClassLoader.java:643)
... 19 more


So, what jar files need to add for resolve this error?

Regards,
H.Vasanthakumari

Accepted answer


permanent link
Ralph Schoon (63.1k33646) | answered Mar 22 '18, 6:59 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
edited Mar 22 '18, 6:59 a.m.

I had exactly that and the reason was that a user library specified for the Plain Java Client Library was not set to point to a plain Java Client Library install.

Details can be found in my other answer.

Ralph Schoon selected this answer as the correct answer

One other answer



permanent link
Ralph Schoon (63.1k33646) | answered Feb 13 '17, 5:33 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
edited Feb 13 '17, 6:57 a.m.

Please read How should I ask a question in the Forum if I want to receive useful answers? to improve asking your questions so that someone that has not written the failing code himself could possibly find out what you might try to do and has enough information to start thinking about a possible solution.



As explained in https://rsjazz.wordpress.com/2014/07/22/manage-scheduled-absences-using-the-plainjava-client-libraries/ you need the plain java client libraries added as a user library. It is a set of libraries that have dependencies, so you should add all libraries. See https://rsjazz.wordpress.com/2013/02/28/setting-up-rational-team-concert-for-api-development/ section Setting Up The Plain Java Client Libraries how to do that in general and add it to the classpath.  

Please note from the blog post:

"The data provided during creation is String and timestamps. Please note, this class is not part of the plain java client libraries but shipped with the RTC Eclipse client plugins in the file com.ibm.team.apt.common_*.jar. You need to add this jar file to your classpath, if you run this outside of the RTC SDK as described below."

At the end of Understanding and Using the RTC Java Client API is explained how to call in a batch file.,  



Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.