ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Khanna, Vijay \(GE, Corporate, consultant\)" <vijay.kha...@ge.com>
Subject RE: java.io.NotSerializableException: com.ibatis.db.sqlmap.LazyLoadList
Date Wed, 23 Aug 2006 18:24:33 GMT

I did run a custom test to write & read the instances in the list.It
failed as somehow the List now contains non-serializable objects (e.g
BrokerBean) returned by 'executeQueryForList()'. I made sure that Broker
bean, member data (lists containing other beans) are serializable. 

As per the Jboss guys, somewhere in the object graph we have a
declaration of java.lang.Object, which is causing this. But again theres
nothing of that sort. So after lot of useless effort doing post mortem
of Ibatis 1.x we decided to verify it with 2.x and 'YES' this problem
does not surface (solved) with 2x. So this means that its not the
problem with the application beans, mapping or JBOss cache..but with
Ibatis1.x. Although, I cannot support this point as to where this
problem is localized within Ibatis..

Thanks,
Vijay

-----Original Message-----
From: Chris Lamey [mailto:clamey@localmatters.com] 
Sent: Wednesday, August 23, 2006 2:02 PM
To: user-java@ibatis.apache.org
Subject: RE:java.io.NotSerializableException:
com.ibatis.db.sqlmap.LazyLoadList

On Wed, 2006-08-23 at 13:54 -0400, Khanna, Vijay (GE, Corporate,
consultant) wrote:

> Jboss gave us a utility class as a Listener to find the actual object 
> in the list causing this concern when stored in the HttpSession. To my

> surprise it found one bean/DTO type which is not serializable. I 
> quickly checked the bean and found that it does implment Serializable 
> interface and all the declaration within the bean (primitives and 
> Lists) are valid serializable entities.

Are all the entries in the Lists Serializable?

If so, can you serialize that bean/DTO yourself in a test program?  I
would write a simple main application that writes and reads an instance
of that object, with all member data (primitives and Lists) completely
filled out, to verify that it and all of its member variables are
Serializable.

Cheers,
Chris

Mime
View raw message