File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Need help with web service + jpa combo

 
John Semler
Greenhorn
Posts: 13
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was putting the finishing touch on my logic, but something happen and I was never able to recover - getting the following error mostly now. Been racking my brains for 6 hours.

The class in question below does have the @Entity annotation so I don't know where to go with this. I'm relatively new at this so I appreciate any help!

I'm developing under Linux using NetBeans 7.2 and GlassFish 3.1.2.



ZIPCode.java (blows up at line 31):

ZIPCodes.java (auto-generated):


persistence.xml:

glassfish-resources.xml:
 
John Semler
Greenhorn
Posts: 13
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm also getting a lot of these errors. Keeps adding to the server log when I'm not doing anything. Probably a significant clue.



No error with another JPA module running in an EJB (it uses mysql_ephemeris_db_rootPool).
 
John Semler
Greenhorn
Posts: 13
  • 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Made the following changes:

1) Switched to Container Managed Persistence (see code below).
2) Copied "mysql-connector-java-5.1.18-bin.jar" to "/home/glassfish/glassfish/domains/domain1/lib/ext"

Works perfectly!

ZIPCode.java

persistence.xml

glassfish-resources.xml
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic