[jboss-as7-dev] Serialization, proxies issue & AS7-5496

Scott Marlow smarlow at redhat.com
Wed Sep 26 20:18:19 EDT 2012


On 09/26/2012 07:47 PM, David M. Lloyd wrote:
> Maybe the client is using an old/broken javassist.jar?

That doesn't seem to be the case.  The client contains:

photo_web.war
├── index.xhtml
├── META-INF
│   ├── MANIFEST.MF
│   └── maven
│       └── de.seimet
│           └── photo_web
│               ├── pom.properties
│               └── pom.xml
├── resources
│   ├── components
│   └── css
└── WEB-INF
     ├── beans.xml
     ├── classes
     │   ├── de
     │   │   └── seimet
     │   │       └── photo
     │   │           ├── backing
     │   │           │   └── ThumbnailBean.class
     │   │           ├── filter
     │   │           ├── service
     │   │           └── tools
     │   ├── messages_de.properties
     │   └── messages.properties
     ├── faces-config.xml
     ├── lib
     │   ├── commons-codec-1.6.jar
     │   ├── commons-io-2.4.jar
     │   ├── commons-logging-1.1.1.jar
     │   ├── cssparser-0.9.5.jar
     │   ├── guava-11.0.2.jar
     │   ├── jsr305-1.3.9.jar
     │   ├── photo_ejb_client-1.0.0-SNAPSHOT.jar
     │   ├── richfaces-components-api-4.2.2.Final.jar
     │   ├── richfaces-components-ui-4.2.2.Final.jar
     │   ├── richfaces-core-api-4.2.2.Final.jar
     │   ├── richfaces-core-impl-4.2.2.Final.jar
     │   └── sac-1.3.jar
     └── web.xml

I need to hack up a test against the older Hibernate 3.3 to eliminate 
Hibernate as a possible cause still.

>
> On 09/26/2012 06:07 PM, Stuart Douglas wrote:
>> This seems odd, de.seimet.photo.entity.Location_$$_javassist_2 should
>> write itself out as a SerializableProxy as well AFAIK.
>>
>> Stuart
>>
>> Scott Marlow wrote:
>>> I was able to reproduce the CNFE issue reported in AS7-5496 (using MySQL
>>> + the test case attached to the jira).
>>>
>>> The jira reports that the CNFE problem only occurs with Hibernate (using
>>> EclipseLink is a workaround).  I suspect that EclipseLink might not be
>>> using a proxy for the lazy association but not really sure.  According
>>> to the jira, this also used to work with AS5 (older Hibernate).
>>>
>>> During the first EJB client invocation, an entity is returned that
>>> contains a (lazy assocation) proxy that seems to be handled by a call to
>>> readResolve().  During the readResolve(), the original
>>> org.hibernate.proxy.pojo.javassist.SerializableProxy instance is
>>> replaced with a newly generated class
>>> de.seimet.photo.entity.Location_$$_javassist_2 instance.
>>>
>>> However, when the returned entity is passed to the other EJB client
>>> invocation (as a parameter), the generated class
>>> de.seimet.photo.entity.Location_$$_javassist_2, will not be known on the
>>> server side (causing the cnfe.)
>>>
>>> More details are in the jira.
>>>
>>> I'll try using the older version of Hibernate and see if that helps.
>>>
>>> Any other suggestions?
>>>
>>> Scott
>>> _______________________________________________
>>> jboss-as7-dev mailing list
>>> jboss-as7-dev at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/jboss-as7-dev
>> _______________________________________________
>> jboss-as7-dev mailing list
>> jboss-as7-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/jboss-as7-dev
>>
>
>



More information about the jboss-as7-dev mailing list