Mantis - Resin
Viewing Issue Advanced Details
1322 minor always 08-30-06 17:29 09-05-06 15:01
gzhu x86  
ferg Linux  
closed 3.0.21  
Thu, 10 Aug 2006 12:03:19 PDT fixed  
none 3.0.22  
0001322: Within Enterprise Bean Context, environment entries not stored for CMP EJB 2
Environment entries defined in EJB CMP 2.0 are not stored in EJB context - JNDI lookup returns null.

Stateless session bean can still have environment entries defined and looked up correctly. Somewhat consistent with EJB3 spec, since 'Entity' is no longer an EJB.

Define a simple CMP (EJB2), with following in your ejb-jar.xml:


Inside that CMP:
   String thisValue = (String)
           (new InitialContext()).lookup("java:comp/env/testEnvName");
   // thisValue would be "testEnvValue" with 3.0.19; and
   // thisValue would be null with 3.0.21

09-05-06 15:01