Originally posted by KasiMurugan Ramasamy:
Hi Manish,
I think yours primary key class is not seems to be ok. You have to implement serializable. Because the container might be maintains the primary key objects in the secondary storage, when the corresponding EJBObjects take rest( I mean the corresponding Entity Bean instance goes to the pooled state from read state).That is my guess, iam not sure about why primary key class should implements Serializable.
Regards
Kasimurugan R.
In the pooled state, bean instances looses its state, ie its not associated with any data. So I dont think the container would store the primary keys. It needs to be serialized because we have getPrimaryKey() method in the component interface, which means the PrimaryKey instance should be wired to the client. Hence should be serialized.