struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shane Mingins <shane.ming...@assureinternational.com>
Subject RE: Struts with OJB
Date Wed, 28 Apr 2004 20:48:52 GMT
You can also set the cache settings in the OJB property file from memory.

Have u done a simple test:

Load list.
Edit item in list
Persist list
Check List shows (or does not show) changed item.

IOW are dead certain that it is OJB caching the old list or is the problem
somewhere between there and your JSP?

What OJB API are you using?  Behaviour does differ between them from memory
... I had similar problems that you describe.

I think if the above test shows that it is a caching issue then you are
looking at OJB and can move your queries to that list.

HTH
Shane


> -----Original Message-----
> From: Daniel Perry [mailto:d.perry@netcase.co.uk]
> Sent: Wednesday, 28 April 2004 11:54 p.m.
> To: Struts Users Mailing List
> Subject: RE: Struts with OJB
> 
> Assuming you aren't storing them beyond a single request, the items are
> being cached in OJB.  You need to clear the cache after updating objects.
> 
> To fix this, after any inserts/updates in your java code, do:
> 
> PersistenceBrokerFactory.defaultPersistenceBroker().clearCache();
> 
> Daniel.
> 
> -----Original Message-----
> From: Murali Ravipudi [mailto:murali_ravipudi@adp.com]
> Sent: 28 April 2004 11:11
> To: 'Struts Users Mailing List'
> Subject: Struts with OJB
> 
> 
> 
> Hi,
> 
> I am using Struts 1.1 with OJB 1.0rc5. In my application, there is a "list
> items" page where items are listed.
> I get the items to be displayed into an ArrayList using OJB and do
> request.setAttribute("RESULT", allItems);
> In the JSP, I request.getAttribute("RESULT"); and <logic:iterate . . .> to
> display.
> The problem I am facing is this: when an item is edited using this
> application, the changes are propogated to the database, but on visiting
> the
> "list items" page again, I do not see the updated item. It shows the old
> version.
> I could not find out where the old version is being cached.
> Any clues on this are appreciated.
> 
> Thanks
> Murali
> 
> 
> 
> 
> 
> 
> This message is confidential and may also be legally privileged. If you
> are
> not the intended recipient, please notify postmaster@adpwilco.com
> immediately. You should not copy it or use it for any purpose, nor
> disclose
> its contents to any other person. The views and opinions expressed in this
> e-mail message are the author's own and may not reflect the views and
> opinions of ADP Wilco.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message