It's all about the answers!

Ask a question

[closed] Could not find or load main class WorkshopSetup.jar


vikrant kamble (132559) | asked Jul 03 '15, 5:35 a.m.
closed Jul 06 '15, 7:49 a.m. by Ralph Schoon (57.1k23642)
 Hi All,
I am following rational team concert extension workshop to set development environment to extend RTC provided on below link
https://jazz.net/library/article/1000

Instead of using web installers to install Server and client I used Installation managers to install Jazz team server and RTC eclipse client. However directory in my system is same as the one shown in workhsop. 
When I open WorkshopSetup.bat in notepad first line I see is
"set JAVA_HOME=..\TeamConcert\jazz\client\eclipse\jdk"

but in my system jdk folder is directly under TeamConcert folder therefore in WorkshopSetup.bat file I changed first line as
"set JAVA_HOME=..\TeamConcert\jdk"

When I try to run WorkshopSetup.bat file it is showing me error as
"Could not find or load main class WorkshopSetup.jar"
How do I resolve this problem
I am performing this workshop on CLM version 5.0.2

Comments
Howard Hsiao commented Jul 03 '15, 5:39 a.m.
JAZZ DEVELOPER

 Do you get the same result if you use absolute path for JAVA_HOME?


vikrant kamble commented Jul 03 '15, 5:42 a.m.

 How to set absolute path for JAVA_HOME?

I currently set it as
set JAVA_HOME=..\TeamConcert\jdk


Howard Hsiao commented Jul 03 '15, 10:19 a.m.
JAZZ DEVELOPER

Find out the the absolute path for the TeamConcert\jdk directory, for example, C:\RTC502Dev\installs\TeamConcert\jdk, and then set it in WorkshopSetup.bat


vikrant kamble commented Jul 04 '15, 2:10 a.m.

Yes It was showing same error even after setting absolute path

The question has been closed for the following reason: "Problem is not reproducible or outdated" by rschoon Jul 06 '15, 7:49 a.m.

One answer



permanent link
Ralph Schoon (57.1k23642) | answered Jul 03 '15, 6:00 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
As described in 1.3 Setup the RTC Tomcat Server step _14_b on Page 26 this depends on the relative locations, if you did not follow the steps exactly, and your structure does not look like 1.1 Download and Unzip the Required Files from jazz.net on Page 13 you will have to fix the paths - and not necessarily only one. Dependent on how you deviated, all paths could be affected.

An absolute path would be "C:\RTC502Dev\installs\TeamConcert\jazz\client\eclipse\jdk" or "C:/RTC502Dev/installs/TeamConcert/jazz/client/eclipse/jdk"

Comments
vikrant kamble commented Jul 03 '15, 6:22 a.m.

  In my system I installed JTS,CCM and RTC using Installation Manager.   "jdk" folder was directly under "Team Concert" therefore I had to change that line.

When first time I opened WorkshopSetup.bat I tried to run it as it is It showed me "the system cannot find the path specified" therefore I changed JAVA_HOME to set JAVA_HOME=..\TeamConcert\jdk


Ralph Schoon commented Jul 03 '15, 8:22 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

With the information provided, I can't tell anything. If you use the zip version of RTC and install in the same structure, it always worked for me an all 6 versions I tested.

Is this a Linux System?

"Could not find or load main class WorkshopSetup.jar"

does not make sense, becase java is called with -jar and the main class is configured inside the jar file.


vikrant kamble commented Jul 04 '15, 3:18 a.m.

I am performing workshop on windows
I installed RTC using installation manager but that does not seem to be issue to me.
When I opened WorkshopSetup.jar for the first time I had to make changes only in first line in notepad.
I saved changes and run WorkshopSetup.jar there it showed this error.
I could not understood cause of this error. Because WorkshopSetup.jar is shipped in the download file.
I also could not understand how it is searching for WorkshopSetup.jar because we are setting path of java home and plain java libraries but path of this file is not set anywhere.


Ralph Schoon commented Jul 05 '15, 5:36 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

If you sa open the jar, what do you mean?
You are only supposed to change setting in the batch file and then run the batch file.


Ralph Schoon commented Jul 05 '15, 5:37 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

And the batch file with sensible settings works. We have proven that over and over again.


Ralph Schoon commented Jul 05 '15, 5:40 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

The parameters are set in the batch file. If you can't figure how to set the paths to a JDK and the plain Java client libraries run the batch file, I don't have high hopes for you being able to follow the workshop let alone develop your own extensions.

showing 5 of 6 show 1 more comments