wood burning stoves*
The moose likes Java in General and the fly likes Java Petstore 2.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Java Petstore 2.0" Watch "Java Petstore 2.0" New topic

Java Petstore 2.0

Derek Zeng

Joined: Aug 25, 2006
Posts: 16
I download the Java Petstore 2.0 from the https://blueprints.dev.java.net/servlets/ProjectDocumentList?folderID=5315&expandFolder=5315&folderID=0
It is a jar file. Inside the jar file is a big .class file.
It should have the source codes.
How can i use it?

SCJP 5.0<br />Preparing SCWCD...
Ernest Friedman-Hill
author and iconoclast

Joined: Jul 08, 2003
Posts: 24183

Run the class file.

[Jess in Action][AskingGoodQuestions]
Derek Zeng

Joined: Aug 25, 2006
Posts: 16
Please tell me how can i run the class file.
It seems no main thread there.
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 41064
What happened when you typed "java -jar JarFileNameHere.jar"?

Ping & DNS - my free Android networking tools app
Derek Zeng

Joined: Aug 25, 2006
Posts: 16
Thanks Ulf.
It installs all the sorce codes.
[ February 18, 2007: Message edited by: Derek Zeng ]
Deepak Bala

Joined: Feb 24, 2006
Posts: 6661

This is from the link you gave us

AJAX-enabled Web 2.0 Java Pet Store Reference Application for Java EE 5, 2.0 Early Access distribution. To Install: Double-click the jar file javapetstore-2.0-ea4.5-installer.jar, or run 'java -jar javapetstore-2.0-ea4.5-installer.jar' from command-line

SCJP 6 articles - SCJP 5/6 mock exams - More SCJP Mocks
Derek Zeng

Joined: Aug 25, 2006
Posts: 16
i'm sorry John.
I just double-click the .jar file.
Derek Zeng

Joined: Aug 25, 2006
Posts: 16
When I build the project, it comes out the following error message:

D:\temp\javapetstore-2.0-ea4.5\build.xml:70: The following error occurred while executing this line:
D:\temp\javapetstore-2.0-ea4.5\setup\setup.xml:58: org.apache.derby.client.am.DisconnectException: java.security.PrivilegedActionException: Error opening socket to server localhost on port 1527 with message : null

Please help me what is the problem.
It is sorta covered in the JavaRanch Style Guide.
subject: Java Petstore 2.0
Similar Threads
Need help very urgent.
Tips on SCDJWS - 84%
Advice and help for SCEA part -2
SCEA-2 if using framework like seam then still have to use J2EE design pattrems ?
Another preparation advice