Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Has anyone ever got the PetStore Demo to work?

 
Kevin Thompson
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Has anyone ever got the PetStore Demo to work? On what platform did you get it to work? Windows 98? Windows NT? Linux?
I spent several hours and gave up, at least for now. I was curious if anyone else EVER got it to work?
Sun only has one complete example of EJBs/architectural design (the PetStore). This PetStore demo is the very core of understanding and learning architectural issues from Sun's examples. It also appears to be the very core of passing the architect certification.
I had posted this same question here a couple days ago, but the posting is gone? Was it deleted? If this question is inappropriate for this site, I hope the administrators tell me what is wrong with this posting.
In the absense of finding a single sole who got their example to work, I can only conclude that Sun's example is worthless code, and continueing to attempt to get the PetStore example to work, as a means of preparing for the architect exam, is a waste of my time.

thanks
 
Rahul Mahindrakar
Ranch Hand
Posts: 1869
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Kevin,
I have the j2sdkee1.3 on my system with petstore demo 1.1.2 and things seem to work just fine. I have a windows 2000 professional with 256 MB RAM which is a PIII system. If you have any specific problems do give us the messages or your problems so that we can help you out.


I had posted this same question here a couple days ago, but the posting is gone? Was it deleted? If this question is inappropriate for this site, I hope the administrators tell me what is wrong with this posting.

I do not think any moderator or Sheriff has deleted your post. Did you see your post after it was created. Normally moderators do write when they delete a post stating the specific reason for its delition. This is only in an extreme cases. In other cases the posts are edited and are left intact.
I am working intensively on the jps. I will definetly help you out. So keep posting....

------------------

Mahindrakar
IBM Application Server Forum Moderator
SCJP2
 
Amanda Waite
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Kevin,
It works fine for me too. I've run the 1.1.1 version on both Solaris Windows 2000 professional and server. As Rahul says, if you have any specific messages let us have them or post them on the EJB forum on the Java website: http://forum.java.sun.com/ (you'll need to be a member)
Amanda
 
Raj Mohan
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I do find problem in connection with the database. I have j2sdkee1.2.1 and the platform is Windows 98. I tried with Cloudscape, it didn't work and I tried with oracle the same problem. In fact I did create the database tables in Oracle as well as Cloudscape.
The index page of the demo opened but when I tried to create a new login name, it failed. Secondly, it failed to list all the pets for eg. fish, it didn't show anything.

what is the problem. Please help me.
Regars,
Raj
 
Rahul Mahindrakar
Ranch Hand
Posts: 1869
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Raj,
In the new Beta version of J2ee 1.3 with jps 1.2.2 as the application. most of the problems with setting up the database etc, have been solved. Try checking it out. If you can post the specific error message on the browser maybe we can help you out.

------------------

Mahindrakar
IBM Application Server Forum Moderator
Consultant - Zensar Technologies.
SCJP2 & SCJEA (Part I)
 
Raj Mohan
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rahul,
After a long time, I tried it today and found some other problems. This thime, I have used j2sdkee1.3 and jps 1.1.2 [i think this is the latest version]. The errors appeared on my screen :

A Servlet Exception Has Occurred
Exception Report:
javax.servlet.ServletException: Servlet execution threw an exception
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:240)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:251)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:196)
at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:242)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2041)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:225)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:159)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:818)
at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:897)
at java.lang.Thread.run(Thread.java:484)
Root Cause:
java.lang.NoSuchMethodError
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:247)
at org.apache.catalina.core.ApplicationDispatcher.access$0(ApplicationDispatcher.java:240)
at org.apache.catalina.core.ApplicationDispatcher$1.run(ApplicationDispatcher.java:224)
at java.security.AccessController.doPrivileged(Native Method)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:220)
at com.sun.j2ee.blueprints.tools.populate.web.PopulateServlet.showTables(PopulateServlet.java:249)
at com.sun.j2ee.blueprints.tools.populate.web.PopulateServlet.doGet(PopulateServlet.java:135)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:251)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:196)
at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:242)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2041)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:225)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:159)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:818)
at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:897)
at java.lang.Thread.run(Thread.java:484)

Please help me in solving the problem.
regards, Raj
 
Andrew Tyson
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Kevin,
I have got PetStore 1.0.1 working on Solaris 8 using WebLogic 5.1sp9 against an Oracle 8.1.5 RDBMS. Despite the demo 'supporting' this config I had to physically touch up some of the code to get it to work properly. Most of the issues were in the DAO classes where table column names were incorrectly referenced in the code. Finding the problems can be hard unless you turn on the debugging (which requires a programmatic change !!)
Thanks and regards,
Andrew
 
Gillian Henry
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Kevin Thompson:
Has anyone ever got the PetStore Demo to work? On what platform did you get it to work? Windows 98? Windows NT? Linux?

Hi,
I know this topic is a bit old, but I've also for the past few days been trying to get the petstore demo to work. I've downloaded a copy from the Oracle site (as I'm using Oracle App server, db and oc4j containers).
Everytime I try the 'Enter the store' link I get a 'PopulateServlet' error as follows:
========================
PopulateServlet Error:
java.lang.NullPointerException java.lang.NullPointerException at com.sun.j2ee.blueprints.tools.populate.web.PopulateServlet.checkTables(PopulateServlet.java:276) at com.sun.j2ee.blueprints.tools.populate.web.PopulateServlet.doGet(PopulateServlet.java:127) at javax.servlet.http.HttpServlet.service(HttpServlet.java:244) at javax.servlet.http.HttpServlet.service(HttpServlet.java:336) at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:59) at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:283) at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:523) at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:269) at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:735) at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:151) at com.evermind.util.ThreadPoolThread.run(ThreadPoolThread.java:64)
=========================
I've scoured all the Oracle and Sun sites and have had no joy in figuring out this problem. Has anybody else out there had this error or does anybody have suggestions?
Anything would be appreciated.
Thanks in advance,
Gillian
 
Byron Estes
Ranch Hand
Posts: 313
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Worked flawlessly for me on Windows 2000 Professional using latest Tomcat Server.
 
Kevin Thompson
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for posting Byron. I had set aside my architect studies for a long time, and have only recently returned to it.
As soon as I get past the Part I test, I am going to very seriously study and work on the Pet Store demo again. I have a new computer, so maybe things will be different this time.
However, this is still a "worry item" for me, because notice how that this original post is over 1 1/2 years old, not alot of people said "YES" it works fine.
thanks!
Kevin Thompson
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic