[jboss-user] [EJB 3.0] - Strange behavior

Dens do-not-reply at jboss.com
Fri Sep 8 07:51:11 EDT 2006


design:

Swing <-> SFSB(remote !)
(2 different VM of course)

Description of this strange behavior:

a method of my sfsb returns an object with reference (in the server): 

mY.package.Account at 19

this instance is managed by the persistence manager ( I use
PersistenceContextType.EXTENDED)

In my swing app if I display the object I received, i get:
my.package.Account at 19  (the same)

And, if I send back this object to the server I get always the same reference on the server....
my.package.Account at 19  (the same)

This object is now "theorically" detached from its persistence context.
If i set any of its property, the modificatin does not impact on the db (normal). 

If i merge this object, the merge results reference is:
my.package.Account at 19 (lol)
And now as it is managed, any modification on my entity will reflected in
my db.

All what i have described here is ejb3 conform (need to merge).
but i'm surprised that the refereence after serialization remains... is it a JBoss serialization mechanism specific behavior ????
Thankk you

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3970325#3970325

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3970325



More information about the jboss-user mailing list