Two Laptop Bag*
The moose likes Websphere and the fly likes The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0" Watch "The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0" New topic
Author

The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0

Greg Doe
Greenhorn

Joined: Oct 05, 2011
Posts: 1
I am using JPA 2.0 and Hibernate (version 3.5) as persistence provider. Have all the required jar files in classpath.

I am trying to use @PersistenceContext annotation in my Service class and getting below error.

Problem description: The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0 runtimes. Set the UseEJB61FEPScanPolicy custom property to true in the MANIFEST.MF file for this module.

As I am digging deep into this issue found that the deployment descriptor (application.xml) has J2EE(1.4) not JavaEE (1.5) version but changing this didn't help either . What is the reason for this error?
Victor Sosa
Greenhorn

Joined: Aug 26, 2008
Posts: 20

Do you have installed the OSGi 1.0 and JPA 2.0 Feature Pack?
http://www-01.ibm.com/software/webservers/appserv/was/featurepacks/osgi/


"Software development has been, is, and will remain fundamentally hard"
- Grady Booch
 
Don't get me started about those stupid light bulbs.
 
subject: The annotation PersistenceContext will not be recognized by WebSphere Application Server v7.0