Skip to content
This repository was archived by the owner on Jan 30, 2019. It is now read-only.
This repository was archived by the owner on Jan 30, 2019. It is now read-only.

javax.persistence.EntityManager Injection with @Inject #28

Closed
@glassfishrobot

Description

@glassfishrobot

The default injection case:

@PersistenceContext
EntityManager em;

should be also possible with:

@Inject
EntityManager em;

In this case an EntityManager from the single persistence unit defined in the persistence.xml with the TRANSACTED type is going to be injected.

The elements unitName and type should be "replaced" by the Qualifiers:

@Unit("")

and

@Transacted / @Extended

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions