Details
-
Type:
Feature Request
-
Status: Closed (View Workflow)
-
Priority:
Major
-
Resolution: Done
-
Affects Version/s: 3.3.0.M2
-
Fix Version/s: 3.3.0.M3
-
Component/s: cdi-extensions
-
Labels:None
Description
Create SMPC in Seam 3 Persistence module as shown here http://docs.jboss.org/seam/3/persistence/latest/reference/en-US/html/persistence.html#persistence.seam-managed-persistence-contexts
@Inject
EntityManager em;
Shows "No bean is eligible for injection to the injection point [JSR-299 §5.2.1]" warning
Gliffy Diagrams
Issue Links
- is related to
-
JBDS-1721
JBDS50_0015: [DROPPING---COMMIT] (Dev) Seam 3 (ChangeRequest)
-
- Closed
-
-
JBIDE-9852
Make sure JBT works with the latest Seam 3.1.0.Beta3 release.
-
- Resolved
-
- relates to
-
JBIDE-9483
CDI extensions are not loaded if they are declared in a source folder.
-
- Closed
-
-
JBIDE-9484
CDI beans created by extensions are not loaded by child projects
-
- Closed
-
What we should do:
If there is a Seam Persistence module in the project classpath (org.jboss.seam.persistence.ManagedPersistenceContextExtension extension) and ExtensionManaged producer is defined in the project then we should provide a built-in bean with EntityManager type and qualifiers and scope defined for this producer. See an example of such a producer:
@ExtensionManaged@Produces@PersistenceUnit@ConversationScopedEntityManagerFactory producerField;where @ExtensionManaged indicates that this producer forces Seam to provide an EntityManager bean with the listed qualifiers and scope.
There may be a few producers for EntityManagerFactory with different set of qualifiers. So we also should provide the corresponding bean for every producer.
If such a producer has SessionFactory type instead of EntityManagerFactor and there is org.jboss.seam.persistence.hibernate.HibernateManagedSessionExtension extension in the project classpath then we should provide Session bean instead of EntityManager.