gloeglm wrote:
Why dont you just include hibernate.jar in the classpath of you client? I never had any problems working with the hibernate collections on a remote client.
My clients are a variety of different departments within a large organization. If I include hibernate implementation classes in my remote interfaces, I would not be able to update my hibernate version without forcing all my clients to change. Hibernate is part of my implementation, it shouldn't be part of my interface.
gavin wrote:
No, this is not supposed to happen. The collection wrapper carries a snapshot around with it. This makes update() much more efficient.
That snapshot can't possibly be useful after serialization, can it? If I serialize an entity and send it across a wire, it's pretty effectively cut off from the session... why not strip out any hibernate implementation classes?
What would be the problem if the hibernate collection classes implemented writeObject() to write out their "normal" jdk-collection implementations (ie HashSet)?
Maybe this conversation should be moved to hibernate-devel.