EJB 3.1 Embedded API - Unit test EJB + JPA Objects

Has anyone done this or tried to do this for an existing project?
There seem to be two options: either using the built-in EJB API , basically the following class

javax.ejb.embeddable.EJBContainer

It is expected that a customized installation of Glassfish v3 will be available (resources with the application area will be simplified).

An alternative is to use the built-in fan coil files and the built-in Glassfish API

I am looking for feedback from someone who has or who is in the process of this, links to blogs, etc. using a simple EJB, and a test case ten times.

If you have done this with any other EJB 3.1 container, feel free to share.

  • Have you used any particular test environment for reasons other than your preferred tool?
  • What JPA 2.0 implementation did you use, and was there a special reason for this?
  • If you used glass fish, which of the above strategies did you use? If not, which EJB 3.1 container did you use?
  • If you have successfully done this, was it worth it, and will you do it again for another existing project?
+5
source share
2 answers

There seem to be two options that you can use here: either using the built-in EJB API (...), which expects a customized installation of Glassfish v3 to be available.

, .

-, , .. EJB, - .

EJB 3.1 JPA ( Maven), Unit Testing EJB JPA GlassFish. , , .

- , ?

.

JPA 2.0 , - ?

EclipseLink ( ).

, ? , EJB 3.1 ?

API Embedded EJB, Java EE 6, .

, , ?

, , / , API Embedded EJB . , .

maven-embedded-glassfish-plugin (. ).

+4

Glassfish 3.1 EJB javax.ejb.embeddable.EJBContainer. , , createEJBContainer().

+1

All Articles