Could not find or load main class WorkshopSetup.jar
Hi Friends,
I am trying to install rtc in local system and try to do Rational Team Concert Extensions Workshop from https://jazz.net/library/article/1000 Now I am try to run WorkshopSetup.bat file. But when I run this file it will show the error "Could not find or load main class WorkshopSetup.jar" I also check all the path, but error is same.
2 answers
Comments
I installed JRE in C:\Program Files and changed the WorkshopSetup.bat file content.
I also copied the JDK into eclipse client too and got the same issue.
You do not copy any JRE into the Eclipse client. There is a JDK already there that is supposed to be used.
Please follow the install instructions to get this working.
*JAVA_HOME had to be changed to ..\TeamConcert\jdk
However I don't know the root cause of the 'Error: Could not find or load main class WorkshopSetup.jar' error. It's there. I don't know exactly what the .bat file is trying to do to to track the root cause of this...
@Ralph do you have any thoughts or should I just start over using the installation instructions provided specifically for the labs?
Comments
The workshop mentions that if you deviate from the structure, you might need to adjust for it. It shows the bat file and you can open it with an editor.
I would recommend to go with the instructions, if you are a beginner, because that is the easiest. If you don't, you get issues and if you don't know how to solve them, you are stuck. I have run the workshop with 5.0 and 5.0.1 as per the instructions to test it works. I would assume it works with 5.0.2 too.
There is no magic in there. It basically sets the JAVA_HOME to a location relative to its install folder: set JAVA_HOME=..\TeamConcert\jazz\client\eclipse\jdk
If you install differently and need another path, just change that.
It also needs the Plain Java API and sets a path to it. It assumes the install matches the instructions. If not, change that too.
It defines the public URI and the admin user.
Then it runs java -jar to execute.
This is how the batch file looks like:
set JAVA_HOME=..\TeamConcert\jazz\client\eclipse\jdk
set PLAIN_JAVA=../PlainJavaAPI
set REPOSITORY="https://localhost:9443/ccm"
set USERID="myadmin"
set PASSWORD="myadmin"
%JAVA_HOME%\jre\bin\java -jar -Djava.ext.dirs=%PLAIN_JAVA%;%JAVA_HOME%/jre/lib/ext -cp %PLAIN_JAVA% WorkshopSetup.jar %REPOSITORY% %USERID% %PASSWORD%
pause