hi, I wonder that when we insert a row to database through entitybean and we delete the row by other system, how entitybean keep the the synchronization with the datatbase? Does appserver delete the entitybean? If not so, when we get the data through the entitybean, we will get the data out of season. I have tesed the point with BMP.I inserted rows to database through entitybean and deleted them through sqlplus.Then i inserted the same rows into the database through entitybean again,i got the result that the rows will insert into the database again on weblogic,but there will be a exception showing the entity bean already exist on jboss. Does this is relative to the concurrent strage of appserver?
as for my understanding the bean only updates the database state when ejbLoad() and ejbStore() is called. although i cant be of any help i fear, since i know weblogic and dont have any experience with jboss. maybe the bean was still existent in the intern cache of jboss, but that is only a guess. but i also would be quite interested to know why and how this happens.
Student of Business Informatics<br />Kepler University Linz, Austria
There is no magic in any application server. Synchronization is always through the database as max hinted above. That is why with the most common bean caching option (Option C) a bean has a lifetime for the length of the EJB transaction -- this means that access can be serialized through the database via database locking. Kyle