1 Reply Latest reply on Jun 4, 2005 8:54 AM by Scott Stark

    EJB runtime compile error with J2SE 5.0

    Nick Oliver Newbie

      Any suggestions would be useful.

      Using JBoss 4.0.1 for the first time and JDK 1.5.0_02 also for the first time. I have an EJB that uses some 1.5 syntax which compiles just fine when building the project, however when the EJB is used for the first time in the container, in particular the updateTestObject method (see below), I get a compile error in the JBoss container. I've double checked the server log and it reports running in the 1.5 JVM and has the 1.5 tools.jar in the classpath.

      Is there something else that I need to configure?

      The line of code from the EJB is here:

      HashMap<String, String> originalObject = null;

      The stack trace in the server log looks like this:

      16:16:16,150 WARN [RequestProcessor] Unhandled Exception thrown: class javax.ejb.EJBException
      16:16:16,195 ERROR [Engine] StandardWrapperValve[action]: Servlet.service() for servlet action threw exception
      javax.ejb.EJBException: Unexpected Error
      java.lang.Error: Unresolved compilation problems:
      Syntax error on token "<", ( expected
      Syntax error, insert ")" to complete Expression
      Syntax error on token "<", ( expected
      Syntax error on token "(", invalid Expression

      at com.company.qae.jam.core.session.beans.TestObjectsEJB.updateTestObject(TestObjectsEJB.java:386)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
      at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:214)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
      at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:113)
      at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:105)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:313)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:123)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:192)
      at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
      at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
      at org.jboss.ejb.Container.invoke(Container.java:870)