3 Replies Latest reply on Oct 28, 2002 5:09 AM by Eric Chow

    Unable to load to deserialize result

    Eric Chow Newbie

      Hello,

      My simple EJB example that worked in JBoss3.0 but failed in JBoss3.0.1/JBoss3.0.2/JBoss3.0.3.

      My EJB(CMP) just for keeping some message.
      The datatype in DB is BLOB and in EJB is Object.

      When I retrieve the EJB, some exception raised as following:
      =====================================================
      2002-10-24 17:26:20,330 ERROR [org.jboss.ejb.plugins.LogInterceptor] EJBException, causedBy:
      java.sql.SQLException: Unable to load to deserialize result: java.io.StreamCorruptedException: invalid stream header
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.convertByteArrayToObject(JDBCUtil.java:612)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.getResult(JDBCUtil.java:311)
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadArgumentResults(JDBCAbstractCMPFieldBridge.java:350)
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadInstanceResults(JDBCAbstractCMPFieldBridge.java:304)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:147)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:62)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadEntity(JDBCStoreManager.java:572)
      at org.jboss.ejb.plugins.CMPPersistenceManager.loadEntity(CMPPersistenceManager.java:410)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.loadEntity(CachedConnectionInterceptor.java:353)
      at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invoke(EntitySynchronizationInterceptor.java:262)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
      at org.jboss.ejb.plugins.EntityReentranceInterceptor.invoke(EntityReentranceInterceptor.java:90)
      at org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:152)
      at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:107)
      at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:69)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:178)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:60)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:203)
      at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:493)
      at org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invoke(BaseLocalContainerInvoker.java:301)
      at org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:38)
      at $Proxy45.getName(Unknown Source)
      at eric.forum.tag.MessageTag.doStartTag(MessageTag.java:116)
      at org.apache.jsp.show$jsp._jspService(show$jsp.java:102)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:201)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:366)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:332)
      at eric.share.charset.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:71)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:324)
      at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:276)
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:577)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1674)
      at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:544)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1624)
      at org.mortbay.http.HttpServer.service(HttpServer.java:875)
      at org.jboss.jetty.Jetty.service(Jetty.java:541)
      at org.mortbay.http.HttpConnection.service(HttpConnection.java:785)
      at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:935)
      at org.mortbay.http.HttpConnection.handle(HttpConnection.java:802)
      at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:200)
      at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:294)
      at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:743)
      at java.lang.Thread.run(Thread.java:536)
      2002-10-24 17:26:20,490 WARN [org.jboss.jbossweb] WARNING: Error
      javax.ejb.EJBException: Internal error getting results for field member name; CausedByException is:
      Unable to load to deserialize result: java.io.StreamCorruptedException: invalid stream header
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadArgumentResults(JDBCAbstractCMPFieldBridge.java:360)
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadInstanceResults(JDBCAbstractCMPFieldBridge.java:304)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:147)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:62)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadEntity(JDBCStoreManager.java:572)
      at org.jboss.ejb.plugins.CMPPersistenceManager.loadEntity(CMPPersistenceManager.java:410)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.loadEntity(CachedConnectionInterceptor.java:353)
      at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invoke(EntitySynchronizationInterceptor.java:262)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
      at org.jboss.ejb.plugins.EntityReentranceInterceptor.invoke(EntityReentranceInterceptor.java:90)
      at org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:152)
      at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:107)
      at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:69)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:178)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:60)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:203)
      at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:493)
      at org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invoke(BaseLocalContainerInvoker.java:301)
      at org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:38)
      at $Proxy45.getName(Unknown Source)
      at eric.forum.tag.MessageTag.doStartTag(MessageTag.java:116)
      at org.apache.jsp.show$jsp._jspService(show$jsp.java:102)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:201)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:366)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:332)
      at eric.share.charset.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:71)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:324)
      at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:276)
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:577)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1674)
      at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:544)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1624)
      at org.mortbay.http.HttpServer.service(HttpServer.java:875)
      at org.jboss.jetty.Jetty.service(Jetty.java:541)
      at org.mortbay.http.HttpConnection.service(HttpConnection.java:785)
      at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:935)
      at org.mortbay.http.HttpConnection.handle(HttpConnection.java:802)
      at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:200)
      at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:294)
      at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:743)
      at java.lang.Thread.run(Thread.java:536)
      java.sql.SQLException: Unable to load to deserialize result: java.io.StreamCorruptedException: invalid stream header
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.convertByteArrayToObject(JDBCUtil.java:612)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.getResult(JDBCUtil.java:311)
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadArgumentResults(JDBCAbstractCMPFieldBridge.java:350)
      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.loadInstanceResults(JDBCAbstractCMPFieldBridge.java:304)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:147)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCLoadEntityCommand.execute(JDBCLoadEntityCommand.java:62)
      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadEntity(JDBCStoreManager.java:572)
      at org.jboss.ejb.plugins.CMPPersistenceManager.loadEntity(CMPPersistenceManager.java:410)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.loadEntity(CachedConnectionInterceptor.java:353)
      at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invoke(EntitySynchronizationInterceptor.java:262)
      at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
      at org.jboss.ejb.plugins.EntityReentranceInterceptor.invoke(EntityReentranceInterceptor.java:90)
      at org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:152)
      at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:107)
      at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:69)
      at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
      at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:178)
      at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:60)
      at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
      at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:203)
      at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:493)
      at org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invoke(BaseLocalContainerInvoker.java:301)
      at org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:38)
      at $Proxy45.getName(Unknown Source)
      at eric.forum.tag.MessageTag.doStartTag(MessageTag.java:116)
      at org.apache.jsp.show$jsp._jspService(show$jsp.java:102)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:201)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:366)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:332)
      at eric.share.charset.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:71)
      at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:324)
      at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:276)
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:577)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1674)
      at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:544)
      at org.mortbay.http.HttpContext.handle(HttpContext.java:1624)
      at org.mortbay.http.HttpServer.service(HttpServer.java:875)
      at org.jboss.jetty.Jetty.service(Jetty.java:541)
      at org.mortbay.http.HttpConnection.service(HttpConnection.java:785)
      at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:935)
      at org.mortbay.http.HttpConnection.handle(HttpConnection.java:802)
      at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:200)
      at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:294)
      at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:743)
      at java.lang.Thread.run(Thread.java:536)

      2002-10-24 17:26:20,660 INFO [org.jboss.jbossweb] Error: javax.ejb.EJBException: Internal error getting results for field member name; CausedByException is:
      Unable to load to deserialize result: java.io.StreamCorruptedException: invalid stream header

      ========================================================


      Environment:
      1. JBoss3.0.3
      2. JDK1.4.1_01
      3. Win 98
      4. MySQL 3.23.47 for Win98


      Best regards,
      Eric