File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and other Java EE Technologies and the fly likes Problem in data integrity when using read only entity bean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Problem in data integrity when using read only entity bean" Watch "Problem in data integrity when using read only entity bean" New topic
Author

Problem in data integrity when using read only entity bean

Vicky Mohan
Ranch Hand

Joined: Oct 14, 2004
Posts: 130
On weblogic server 6.1, we tried to write some entity beans strictly for read only purpose. We were using DAO before, just thought of learning entity beans .

<max-beans-in-cache>100</max-beans-in-cache>
<idle-timeout-seconds>600</idle-timeout-seconds>
<read-timeout-seconds>60</read-timeout-seconds>
<concurrency-strategy>ReadOnly</concurrency-strategy>

When i deployed with this configuration, i could see ejbLoad() being called for the first time. After an interval of 60 seconds ( due to the property read-timeout-seconds set ) , it makes a call to ejbLoad(). But the wierd part is, i updated some data through toad in the database and i dont see that change at all. But if i use concurrency-strategy as Database, it retrieves the values from database but it calls ejbLoad() and ejbStor() all the time.

Last but not the least, the data i am retrieving is a Collection of entities ( not more than 50). Is it ok to use Entity Beans or continue DAO,as we have been doing all the time

Replied will be appreciated,as i gotto move along one of the two options
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem in data integrity when using read only entity bean