4 Replies Latest reply on Sep 18, 2008 9:52 AM by Andy Conn

    EJB Timeout firing too soon on bootup; LoginContext not avai

    Andy Conn Newbie

      On bootup, any expired timers go off. My EJB @Timeout method attempts to login first to establish and identity. However on bootup, it seems the JAAS/LoginContext facility is not established.

      It would seem I need to somehow set a simple dependency for the EJB on startup. How is this done?

      Here is my stack trace:
      2008-09-15 14:43:59,734 INFO [org.jboss.ejb3.EJBContainer] STARTED EJB: com.bittware.parts.session.dominosync.ConErpSync ejbName: ConErpSync
      2008-09-15 14:44:00,093 INFO [com.bittware.parts.session.dominosync.ConErpSync] ConErpSync.timeout expired ...

      2008-09-15 14:44:00,109 ERROR [STDERR] javax.security.auth.login.LoginException: unable to find LoginModule class: No ClassLoaders found for: com.bittware.parts.session.ContainerLogin
      2008-09-15 14:44:00,109 ERROR [STDERR] at javax.security.auth.login.LoginContext.invoke(LoginContext.java:808)
      2008-09-15 14:44:00,109 ERROR [STDERR] at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
      2008-09-15 14:44:00,109 ERROR [STDERR] at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
      2008-09-15 14:44:00,109 ERROR [STDERR] at java.security.AccessController.doPrivileged(Native Method)
      2008-09-15 14:44:00,109 ERROR [STDERR] at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
      2008-09-15 14:44:00,109 ERROR [STDERR] at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
      2008-09-15 14:44:00,109 ERROR [STDERR] at com.bittware.parts.session.dominosync.ConErpSync.login(ConErpSync.java:166)
      2008-09-15 14:44:00,109 ERROR [STDERR] at com.bittware.parts.session.dominosync.ConErpSync.timeout(ConErpSync.java:330)
      2008-09-15 14:44:00,109 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2008-09-15 14:44:00,109 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      2008-09-15 14:44:00,109 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      2008-09-15 14:44:00,109 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:597)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.tx.BMTInterceptor.handleStateless(BMTInterceptor.java:71)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.tx.BMTInterceptor.invoke(BMTInterceptor.java:131)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.mdb.MessagingContainer.localInvoke(MessagingContainer.java:249)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.mdb.MessagingContainer.localInvoke(MessagingContainer.java:236)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb3.mdb.MessagingContainer.callTimeout(MessagingContainer.java:290)
      2008-09-15 14:44:00,109 ERROR [STDERR] at org.jboss.ejb.txtimer.TimerImpl$TimerTaskImpl.run(TimerImpl.java:561)
      2008-09-15 14:44:00,109 ERROR [STDERR] at java.util.TimerThread.mainLoop(Timer.java:512)
      2008-09-15 14:44:00,109 ERROR [STDERR] at java.util.TimerThread.run(Timer.java:462)