Mantis - Resin
Viewing Issue Advanced Details
2856 minor always 08-19-08 09:20 08-19-08 10:15
ferg  
ferg  
normal  
closed  
fixed  
none    
none 3.1.7  
0002856: JMS length issue
(rep by Richard Grantham)

Me again, more issues upgrading to Resin 3.1.6. This time with JMS.

We are using MS SQL Server 2005 with JTDS which generates the following
error when attempting to send a JMS message using a JDBC queue (snipped
for brevity).

org.springframework.jms.UncategorizedJmsException: Uncategorized
exception occured during JMS processing; nested exception is
com.caucho.jms.JMSExceptionWrapper: I/O Error: More data in stream than
specified by length
Caused by:
com.caucho.jms.JMSExceptionWrapper: I/O Error: More data in stream than
specified by length
    at com.caucho.jms.jdbc.JdbcQueue.send(JdbcQueue.java:201)
    at
com.caucho.jms.connection.JmsSession.send(JmsSession.java:888)
    at
com.caucho.jms.connection.MessageProducerImpl.send(MessageProducerImpl.j
ava:276)
    at
com.caucho.jms.connection.MessageProducerImpl.send(MessageProducerImpl.j
ava:207)
    at
org.springframework.jms.core.JmsTemplate.doSend(JmsTemplate.java:534)
    at
org.springframework.jms.core.JmsTemplate.doSend(JmsTemplate.java:511)
    at
org.springframework.jms.core.JmsTemplate$2.doInJms(JmsTemplate.java:477)
    at
org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:428)
    at
org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:475)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
Caused by: java.sql.SQLException: I/O Error: More data in stream than
specified by length
    at
net.sourceforge.jtds.jdbc.TdsCore.executeSQL(TdsCore.java:1049)
    at
net.sourceforge.jtds.jdbc.JtdsStatement.executeSQL(JtdsStatement.java:47
8)
    at
net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeUpdate(JtdsPrepar
edStatement.java:421)
    at
net.sourceforge.jtds.jdbcx.proxy.PreparedStatementProxy.executeUpdate(Pr
eparedStatementProxy.java:75)
    at
com.caucho.sql.UserPreparedStatement.executeUpdate(UserPreparedStatement
java:107)
    at
com.caucho.sql.UserPreparedStatement.executeUpdate(UserPreparedStatement
java:107)
    at com.caucho.jms.jdbc.JdbcMessage.send(JdbcMessage.java:298)
    at com.caucho.jms.jdbc.JdbcQueue.send(JdbcQueue.java:199)
    ... 68 more
Caused by: java.io.IOException: More data in stream than specified by
length
    at
net.sourceforge.jtds.jdbc.ParamInfo.loadFromStream(ParamInfo.java:272)
    at
net.sourceforge.jtds.jdbc.ParamInfo.getBytes(ParamInfo.java:232)
    at
net.sourceforge.jtds.jdbc.TdsData.writeParam(TdsData.java:2186)
    at
net.sourceforge.jtds.jdbc.TdsCore.executeSQL70(TdsCore.java:3787)
    at
net.sourceforge.jtds.jdbc.TdsCore.executeSQL(TdsCore.java:1029)
    ... 75 more

It would appear that when persisting a blob to the database-backed JMS
queue the size is calculated incorrectly.


Notes
(0003338)
ferg   
08-19-08 10:15   
jms/2d00