The bookstore jar contains exception/OrderException. As you dont have it, it throws an exception.
Main Topics
Browse All TopicsOS: Windows XP
Programs: Netbeans 4.1
I am following the course schedule at http://www.javapassion.com
-----1
Message ID:
WebModule[/bookstore1]Exce
Complete Message
exception/OrderException
at listeners.ContextListener.
at org.apache.catalina.core.S
at org.apache.catalina.core.S
at com.sun.enterprise.web.Web
at org.apache.catalina.core.C
at org.apache.catalina.core.S
at org.apache.catalina.core.C
at org.apache.catalina.core.S
at org.apache.catalina.startu
at com.sun.enterprise.web.Web
at com.sun.enterprise.web.PEW
at com.sun.enterprise.web.PEW
at com.sun.enterprise.server.
at com.sun.enterprise.server.
at com.sun.enterprise.server.
-----2
Message ID:
Complete Message
Error listenerStart
Diagnostic Causes
----3
Message ID:
Complete Message
Context startup failed due to previous errors
Diagnostic Causes
I know that I probably did something wrong but I do not remember what. So, I just re-deployed the app according to the instructions and I get the same message. To reiterate I just did the following:
1. downloaded and unzipped j2ee-1_4-doc-tutorial_5.zi
2. restarted the app server through netbeans
3. restarted the PointBase server through netbeans
4. the application deployment instructions for examples\web\bookstore
-asant build
-asant package-bookstore
-asant create-db_common
-asant create-jdbc-resource_commo
5. the application deployment instructions for examples\web\bookstore1
-asant build
-asant create-bookstore-war
-asant deploy-war
When I visit http://localhost:8080/book
At this point, the log file tells me that 'Servlet CatalogServlet is currently unavailable.' The message that I posted above occurs only once right before I see in the log files that the server started up successfully. For reference, this is part of the log file:
62 INFO Application server startup complete. (details) javax.enterprise.system.co
61 INFO Status of System JMX Connector: Active = [true] (details) javax.enterprise.system.to
60 INFO Here is the JMXServiceURL for the JMXConnectorServer: [service:jmx:rmi:///jndi/r
(details) javax.enterprise.system.to
59 INFO Starting Sun-Java-System/Applicatio
58 INFO Initializing Sun-Java-System/Applicatio
57 INFO Starting Sun-Java-System/Applicatio
56 INFO Initializing Sun-Java-System/Applicatio
55 INFO Starting Sun-Java-System/Applicatio
54 INFO Initializing Sun-Java-System/Applicatio
53 INFO contextInitialized() (details) javax.enter....system.cont
52 INFO contextInitialized() (details) javax.enter....system.cont
51 SEVERE Context startup failed due to previous errors (details) tomcat.server./bookstore1.
50 SEVERE Error listenerStart (details) tomcat.server./bookstore1.
49 SEVERE exception/OrderException
at listeners.ContextListener.
at org.ap...
(details)
Can anyone provide a solution to this or another method of troubleshooting because I've run out of suggestions?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Thanks cupra. The ContextListener issue is no longer a problem but there is another that I believe is the actual problem (the bookstore.jar was listed in the Java Source Classpath section). Basically, I started to mess around with the App Server and the PointBase dB and found out the following:
I
Action: restart Pointbase
Result: App does not work. Browser takes forever to load
II
Action:restart App Server and Pointbase
Result:Bookstore does not work.
Action:Undeploy Bookstore
Action:Deploy Bookstore1
Result:Bookstore works.
For some reason the ContextListener is no longer an issue but somehow restarting the App Server or the PointBase server creates a problem. I don't know if this expected behavior but it sure is a pain... The last thing I can say is that when I restart the server I get the following log entries that are the root of the problem in my opinion but I do not know how to solve them since the dB is working and undeploying and deploying the app does the trick.
52 WARNING Error allocating connection : [Error in allocating a connection. Cause: Connection could not be allo...
(details) javax.enter...ource.resour
51 WARNING Failed to obtain/create connection. Reason : Connection could not be allocated because: SQL-server r...
(details) javax.enter...ource.resour
50 INFO Sun-Java-System/Applicatio
49 INFO Loading web module [bookstore1] in virtual server [server] at [/bookstore1] (details)
The specifics for error 52 are:
Error allocating connection : [Error in allocating a connection. Cause: Connection could not be allocated because: SQL-server rejected establishment of SQL-connection. Pointbase Server may not be running on localhost at port 9092.]
And the specifics for error 51 are:
Error allocating connection : [Error in allocating a connection. Cause: Connection could not be allocated because: SQL-server rejected establishment of SQL-connection. Pointbase Server may not be running on localhost at port 9092.]
As I mentioned earlier, simply undeploying and deploying the application works. Does anyone know if this is considered a bug? Is there anything I can do so that these database dependent apps stay functional after a server reload or a NetBeans reload and whatnot? Otherwise, does anyone have a suggestion for fixing the dB Connection issue?
Did you create the JDBC resource in the Admin Console? (BookDB)
>> -asant create-jdbc-resource_commo
So, you need to delete this jdbc-resource and create a new one as this seems to be corrupted.
Business Accounts
Answer for Membership
by: kupra1Posted on 2005-07-19 at 09:34:06ID: 14476861
You don't have the bookstore.jar (bookstore\dist\bookstore. jar ) included in your bookstore1.war. If you don't have it, create the bookstore.jar and then include it.