Hello, Our team is using geronimo for our application server so we thought it best to use openejb to do unit testing. I have been attempting to set it up using eclipse. I have followed the examples and created a simple test case for an EJB. Everything seems to go smoothly until I run into this error
INFO - PersistenceUnit(name=MatchMakerModel, provider=org.apache.openjpa.persistence.PersistenceProviderImpl) 15:15:57,468 INFO [startup] PersistenceUnit(name=MatchMakerModel, provider=org.apache.openjpa.persistence.PersistenceProviderImpl) ERROR - JAVA AGENT NOT INSTALLED. The JPA Persistence Provider requested installation of a ClassFileTransformer which requires a JavaAgent. See http://openejb.apache.org/3.0/javaagent.html 15:15:57,734 ERROR [startup] JAVA AGENT NOT INSTALLED. The JPA Persistence Provider requested installation of a ClassFileTransformer which requires a JavaAgent. See http://openejb.apache.org/3.0/javaagent.html After reading through the examples and forums I have found that since we are using openjpa we need to also have the open-ejb java agent. I have tried to include this in the build path but the error still occurs. Any help/advice is greatly appreciated Here is the test in case it is something in there. Thanks, Fred package englrn.matchmaker.unittests; import static org.junit.Assert.*; import java.util.Properties; import javax.naming.Context; import javax.naming.InitialContext; import org.junit.Before; import org.junit.Test; import englrn.matchmaker.ejb.TechnologyGroupAdminLocal; import englrn.matchmaker.ejb.TechnologyGroupAdminLocalBean; public class TechnologyLocalTestCase { private InitialContext initialContext; @Before public void setUp() throws Exception { Properties p= new Properties(); p.setProperty(Context.INITIAL_CONTEXT_FACTORY, "org.apache.openejb.client.LocalInitialContextFactory"); initialContext = new InitialContext(p); p.put("matchingDatabase", "new://Resource?type=DataSource"); p.put("matchingDatabase.JdbcDriver", "oracle.jdbc.OracleDriver"); p.put("matchingDatabase.JdbcUrl", "jdbc:oracle:thin:@enged-dev-oracle.cisco.com:1521:engeddev"); p.put("matchingDatabaseUnmanaged", "new://Resource?type=DataSource"); p.put("matchingDatabaseUnmanaged.JdbcDriver", "oracle.jdbc.OracleDriver"); p.put("matchingDatabaseUnmanaged.JdbcUrl", "jdbc:oracle:thin:@enged-dev-oracle.cisco.com:1521:engeddev"); p.put("matchingDatabaseUnmanaged.JtaManaged", "false"); } @Test public void testTechnologyGroup() throws Exception { Object object = initialContext.lookup("TechnologyGroupAdminLocal"); assertNotNull(object); assertTrue(object instanceof TechnologyGroupAdminLocal); TechnologyGroupAdminLocal technologyGroup = (TechnologyGroupAdminLocal) object; assertNotNull(technologyGroup.getAllTechnologyGroups()); } } -- View this message in context: http://www.nabble.com/OpenEJB-Unit-Test-ERROR---java-agent-not-installed.-tp17414955p17414955.html Sent from the OpenEJB User mailing list archive at Nabble.com.
