2 Replies Latest reply on Jun 28, 2007 4:45 AM by kike sedes

    Jboss 4.2.0 and SQL Server

    kike sedes Newbie

      i am running a ejb3 aplication on jboss 4.2.0. It worked fine, but i've added
      new entities unreleated with the old ones and it raises next exception.

      Can anyone help me?

      11:58:35,632 WARN [JDBCExceptionReporter] SQL Error: 208, SQLState: 42S02
      11:58:35,632 ERROR [JDBCExceptionReporter] [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]El nombre de objeto 'usuario_concesion' no es válido.
      11:58:35,632 WARN [JDBCExceptionReporter] SQL Error: 16945, SQLState: HY000
      11:58:35,632 ERROR [JDBCExceptionReporter] [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]El cursor no ha sido declarado.
      12:01:41,798 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.BasicAction_58] - Abort of action id -3f57df8d:759:4682264b:cf invoked while multiple threads active within it.
      12:01:41,798 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.CheckedAction_2] - CheckedAction::check - atomic action -3f57df8d:759:4682264b:cf aborting with 1 threads active!
      12:45:44,181 ERROR [LazyInitializationException] failed to lazily initialize a collection of role: com.satdatatelecom.satdataweb.model.usuario.ejb.UsuarioEJB.concesiones, no session or session was closed
      org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.satdatatelecom.satdataweb.model.usuario.ejb.UsuarioEJB.concesiones, no session or session was closed
      at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:358)
      at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationExceptionIfNotConnected(AbstractPersistentCollection.java:350)
      at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:343)
      at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:86)
      at org.hibernate.collection.PersistentBag.toString(PersistentBag.java:483)
      at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.finders.FindUsuarioAction.execute(FindUsuarioAction.java:31)

        • 1. Re: Jboss 4.2.0 and SQL Server
          Davide Ling Newbie

          Your problem is Hibernate related.

          When you load a persistent object it's related
          objects are lazily loaded.
          That is these objects aren't actually loaded,
          but will be loaded only when you try to access them.

          The problem take place when you access
          to lazily loaded object proxy when it's owner session
          is terminated.

          • 2. Re: Jboss 4.2.0 and SQL Server
            kike sedes Newbie

            i can't understand. I've debug the aplication with jboss ide to see the variable values.

            The entity usuario has a List of concesiones. When i run with debug i could see
            the value of this list and i was ok, it has the list of Concesiones i wanted but it crashes when calling the getList method (com.sun.jdi.InvocationException occurred invoking method) and after it jboss crashes

            .

            10:36:36,147 ERROR [LazyInitializationException] illegal access to loading collection
            org.hibernate.LazyInitializationException: illegal access to loading collection
             at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:341)
             at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:86)
             at org.hibernate.collection.PersistentBag.toString(PersistentBag.java:483)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.finders.FindUsuarioAction.execute(FindUsuarioAction.java:31)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.LoginUsuarioAction.execute(LoginUsuarioAction.java:65)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.UsuarioFacadeEJB.loginUsuarioVO(UsuarioFacadeEJB.java:198)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
             at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
             at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
             at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
             at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessContainer.dynamicInvoke(StatelessContainer.java:278)
             at org.jboss.aop.Dispatcher.invoke(Dispatcher.java:106)
             at org.jboss.aspects.remoting.AOPRemotingInvocationHandler.invoke(AOPRemotingInvocationHandler.java:82)
             at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:734)
             at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:560)
             at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:369)
             at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:165)
            10:36:38,022 ERROR [LazyInitializationException] illegal access to loading collection
            org.hibernate.LazyInitializationException: illegal access to loading collection
             at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:341)
             at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:86)
             at org.hibernate.collection.PersistentBag.toString(PersistentBag.java:483)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.finders.FindUsuarioAction.execute(FindUsuarioAction.java:31)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.LoginUsuarioAction.execute(LoginUsuarioAction.java:65)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.UsuarioFacadeEJB.loginUsuarioVO(UsuarioFacadeEJB.java:198)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
             at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
             at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
             at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
             at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessContainer.dynamicInvoke(StatelessContainer.java:278)
             at org.jboss.aop.Dispatcher.invoke(Dispatcher.java:106)
             at org.jboss.aspects.remoting.AOPRemotingInvocationHandler.invoke(AOPRemotingInvocationHandler.java:82)
             at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:734)
             at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:560)
             at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:369)
             at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:165)
            10:36:40,272 ERROR [LazyInitializationException] illegal access to loading collection
            org.hibernate.LazyInitializationException: illegal access to loading collection
             at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:341)
             at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:86)
             at org.hibernate.collection.PersistentBag.toString(PersistentBag.java:483)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.finders.FindUsuarioAction.execute(FindUsuarioAction.java:31)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.LoginUsuarioAction.execute(LoginUsuarioAction.java:65)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.UsuarioFacadeEJB.loginUsuarioVO(UsuarioFacadeEJB.java:198)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
             at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
             at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
             at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
             at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessContainer.dynamicInvoke(StatelessContainer.java:278)
             at org.jboss.aop.Dispatcher.invoke(Dispatcher.java:106)
             at org.jboss.aspects.remoting.AOPRemotingInvocationHandler.invoke(AOPRemotingInvocationHandler.java:82)
             at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:734)
             at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:560)
             at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:369)
             at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:165)
            10:41:02,966 ERROR [LazyInitializationException] illegal access to loading collection
            org.hibernate.LazyInitializationException: illegal access to loading collection
             at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:341)
             at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:86)
             at org.hibernate.collection.PersistentBag.toString(PersistentBag.java:483)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.finders.FindUsuarioAction.execute(FindUsuarioAction.java:31)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.actions.LoginUsuarioAction.execute(LoginUsuarioAction.java:65)
             at com.satdatatelecom.satdataweb.model.usuariofachada.ejb.UsuarioFacadeEJB.loginUsuarioVO(UsuarioFacadeEJB.java:198)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
             at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
             at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
             at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
             at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
             at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
             at org.jboss.ejb3.stateless.StatelessContainer.dynamicInvoke(StatelessContainer.java:278)
             at org.jboss.aop.Dispatcher.invoke(Dispatcher.java:106)
             at org.jboss.aspects.remoting.AOPRemotingInvocationHandler.invoke(AOPRemotingInvocationHandler.java:82)
             at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:734)
             at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:560)
             at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:369)
             at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:165)
            10:41:34,293 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.BasicAction_58] - Abort of action id -3f57df8d:11bc:46836fca:53 invoked while multiple threads active within it.
            10:41:34,293 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.CheckedAction_2] - CheckedAction::check - atomic action -3f57df8d:11bc:46836fca:53 aborting with 1 threads active!