Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Auto Closed
-
1.5.0
-
None
-
None
Description
Section 4.4.2.2 of the EJB 3.1 spec states that the following JNDI locations should be populated for "other client views," which includes remote. TomEE is instead exposing it as BeanName + Remote.
This was shown with the following test material
@Remote
public interface RemoteDatabaseIntegrator {
public void runQuery(String query) throws SQLException;
}
@Remote(RemoteDatabaseIntegrator.class)
@Stateless(name="RemoteDatabaseIntegrator")
public class RemoteDatabaseIntegratorImpl implements RemoteDatabaseIntegrator {
@Resource(name="jdbc/AppDS")
private DataSource ds;
private Connection conn;
@PostConstruct
public void init() throws SQLException
@PreDestroy
public void cleanup() throws SQLException
public void runQuery(String query) throws SQLException
{ this.conn.createStatement().execute(query); }}
@RunWith(Arquillian.class)
@RunAsClient
public class RemoteDatabaseIntegratorTest {
@Deployment(testable=false)
public static JavaArchive createTestArchive()
@ArquillianResource
private URL deploymentURL;
private static final String JNDI_LOC = "RemoteDatabaseIntegratorRemote";
@Test
public void testDbServiceInjectionFailure() throws Exception
}