Reputation: 55
When I start Jetty server in Eclipse (using the jetty-wtp plugin) the console output this error message:
Caused by: java.lang.NoClassDefFoundError: javax/transaction/UserTransaction
My installed environment is:
How can I solve this?
Upvotes: 3
Views: 2782
Reputation: 5702
"uhhh. how do i add the JTA JAR to the CP"
Go to the "Server" view (I use the bottom left list popup list), then double-click on the Jetty Server at localhost. This will bring up the configuration. Select "open launch configuration" underlined link. This brings up a configuration panel, then add to the classpath the missing jar: javax.transaction_1.1.1. This jar is located in the jetty/lib dir. I was looking for it on Oracle website, but there, the link is broken.
Upvotes: 2
Reputation: 6726
Try adding the JTA API to your classpath. You can download from the java.net Maven repo at
http://download.java.net/maven/2/javax/transaction/jta/
Upvotes: 3