We're using a solution somewhat like this but we only cache for a
session/transaction and has no need for the invalidating. But we do retrieve
data "lazily" from the EJBs.
Better solution is: Keep as little code as possible in the JSP-page, that
coding is often subject to much change, instead build a JavaBean which
automagically retrieves fresh data if invalidated.

This performs "extremely" well since compiled JSP communicating with
JavaBeans is extremely fast (of course depending on servlet-engine
implementation).

> -----Original Message-----
> From: A mailing list for Enterprise JavaBeans development
> [mailto:[EMAIL PROTECTED]]On Behalf Of Ted Kahn
> Sent: den 23 september 1999 19:55
> To: [EMAIL PROTECTED]
> Subject: Re: JSP-EJB and caching
>
>
> Hi Rick- Consider making the cache a JavaBean, not the JSP. Provide
> properties in the bean that allow access (from the JSP) to the info. In
> the property getter, look at the isDirty state of a boolean that tracks
> if data has been changed. If true, than update, otherwise return cached
> data.
>
> cheers, -ted
>
> Rick Gibbs wrote:
> >
> > We are in the process of implementing a JSP-EJB solution and I had an
> > idea that might help increase the performance of our application and
> > wanted to see what people thought.
> >
> > Our application is very read intensive and the data is updated on a
> > limited basis.  What I would like to do is implement a caching system
> > on the JSP side.  The cache would store summary objects that were a
> > result of some query.  When an item was updated via an EJB, a message
> > would be sent out to the cache marking it as dirty so then next time it
> > was accessed it would access the EJB.  This way any access to the data
> > would be in memory and would speed up actions such as sorting.
> >
> > Does anyone see any potential problems with this approach?
> >
> > Thanks
> >
> >  Rick
> > _________________________________
> > Rick Gibbs
> > earthcars.com, Inc.
> > [EMAIL PROTECTED]
> > http://earthcars.com
> >
> >
> ==================================================================
> =========
> > To unsubscribe, send email to [EMAIL PROTECTED] and include
> in the body
> > of the message "signoff EJB-INTEREST".  For general help, send email to
> > [EMAIL PROTECTED] and include in the body of the message "help".
>
> --
> ---------------
> Ted Kahn
> [EMAIL PROTECTED]
>
> ==================================================================
> =========
> To unsubscribe, send email to [EMAIL PROTECTED] and include
> in the body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to