The solution to the problem is to change the "spring-version" property in the properties section of jpetstore's pom.xml.
Before the fix:
After the fix:
To get the server.sh script to run (to start the hsqldb database), I did all of the following. Don't know if all were necessary, just know the server.sh script did actually work after doing the following:
1) Used the directions at http://en.wikipedia.org/wiki/Shebang_%28Unix%29 to add the 1st line shown in the server.sh script below as shipped, server.sh only has 2 lines:
2) At a terminal window:
cd `dirname $0`
mvn -e -Ddb.file=./jpetstore exec:java
3) in STS: a) project...clean jpetstore; b) run as ... Maven Package
new-host:hsqldb rdg$ chmod 777 server.bat
new-host:hsqldb rdg$ ./server.sh
4) Started TC Server and got the following error:
5) As directed by error message, went to http://www.slf4j.org/codes.html#StaticLoggerBinder where it said:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
Jul 27, 2010 10:17:37 PM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
6) Added the following to jpetstore's pom.xml (I copied it from the pom.xml of the mvc-showcase sample:
Failed to load class org.slf4j.impl.StaticLoggerBinder
This error is reported when the org.slf4j.impl.StaticLoggerBinder class could not be loaded into memory. This happens when no appropriate SLF4J binding could be found on the class path. Placing one (and only one) of slf4j-nop.jar, slf4j-simple.jar, slf4j-log4j12.jar, slf4j-jdk14.jar or logback-classic.jar on the class path should solve the problem.
As of SLF4J version 1.6, in the absence of a binding, SLF4J will default to a no-operation (NOP) logger implementation.
You can download SLF4J bindings from the project download page
7) added the following to the properties section of pom.xml:
<!-- Logging -->
8) After starting the tc server there were, at first glance, to errors. However nothing happened when I typed in FireFox: http://localhost:8080/jpetstore
9) Looked more carefully and found this message in the log:
10) Googled and found a hit in a Spring Forum post at:
INFO: Initializing Spring FrameworkServlet 'petstore'
[TomcatAspectJWeavingClassLoader@41584807] warning javax.* types are not being woven because the weaver option '-Xset:weaveJavaxPackages=true' has not been specified
Jul 27, 2010 10:27:48 PM org.apache.catalina.core.ApplicationContext log
11) I give up trying to figure out the error message. Instead, I remove the war file from TC server and then install the war back into TC server. When I start TC server it seems to give more messages that look healthy. I right click on index.html and select "Run on Server"
12) jperstore starts up in a browser and works okay.
13) I notice the url that jpetstore is running at: http://localhost:8080/org.springfram...ore/index.html
14) Who would have ever guessed that url? I had assumed it would be http://localhost:8080/jpetstore.
Am I the only one who has to do all this to get jpetstore to run?