Thanks Simon,
But I am looking for something more technical. Does anyone know if there any code examples for doing anything involving persisting an central object in memory in a struts application? -----Original Message----- From: Simon.Chappell [mailto:[EMAIL PROTECTED]] Sent: Friday, July 12, 2002 11:22 AM To: struts-user Subject: RE: where can caching help performance And to continue my obviously inadequate and lame answer ... Disclaimer: I didn't write the code, I just asked that it be written like this (i.e. I drove the logical design) ... these are the perils of being a tech lead on a project and having to trust that the developers really did what you asked and really implemented it the way that they explained it to you. The behaviour of the system is exactly how I asked for it to be, so I'm happy, but I haven't had much opportunity to peek under the covers yet. The app never touches the cache. It makes requests to the DB subsystem and that makes a request to the cache manager and then receives a business object. The app never knows if the object was their in the cache at request time or if it had to be dynamically fetched. All it knows is that it asked and it received (kinda biblical :-) The cache manager is the only part of the system that knows what it's doing as far as creating, updating and purging cached business objects. Simon >-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED]] >Sent: Friday, July 12, 2002 10:15 AM >To: [EMAIL PROTECTED] >Subject: RE: where can caching help performance > > > >So to continue my dumb question... I would start the servlet when >struts starts up and have it declare my objects as singletons. > Then in >my app I would just create the objects when I needed access to them? > > > >-----Original Message----- >From: Simon.Chappell [mailto:[EMAIL PROTECTED]] >Sent: Friday, July 12, 2002 10:53 AM >To: struts-user >Subject: RE: where can caching help performance > > >We have a servlet that starts up at app server initialisation and it's >init method starts our background caching thread and it's finalize >method stops it. This way the cache is always in memory and >doesn't get >picked up by the GC. > >Simon > >>-----Original Message----- >>From: [EMAIL PROTECTED] >>[mailto:[EMAIL PROTECTED]] >>Sent: Friday, July 12, 2002 9:12 AM >>To: [EMAIL PROTECTED] >>Subject: RE: where can caching help performance >> >> >> >>This may be a dumn question, but since its friday what the heck... >> >>If I wanted to build a bunch of business objects when the >>server starts >>and keep them as singletons or factory objects how would I >get them to >>start up and stay alive after that... if I did it on the >>first request >>once the request finished the object would be cleaned up... >> >>? >> >> >> >> >>-----Original Message----- >>From: jamienz [mailto:[EMAIL PROTECTED]] >>Sent: Friday, July 12, 2002 10:01 AM >>To: struts-user >>Subject: RE: where can caching help performance >> >> >>Out of curiosity, how did you implement the in-memory >>cache? One big (1 gig!) hashmap :-) or something more >>exotic? >> >>-- >>jamie >> >>-----Original Message----- >>From: Simon.Chappell >>[mailto:[EMAIL PROTECTED]] >>Sent: Thursday, July 11, 2002 4:07 PM >>To: struts-user >>Subject: RE: where can caching help performance? >> >> >>We have found that the biggest bang for the buck comes >>with pre-fetching >>data out of the database and building our business >>objects ahead of time >>and storing them in an in-memory cache. This means >>that we have a very >>large cache (we estimate at least a gig when we get >>fully ramped up for >>phase one and more after that), but we get phenominal >>throughput from >>it. Our reason for this was a maximum processing time >>of 3.6 seconds and >>we knew that we could not allow the database access to >>be the choke >>point in the system. >> >>__________________________________________________ >>Do You Yahoo!? >>Sign up for SBC Yahoo! Dial - First Month Free >>http://sbc.yahoo.com >> >>-- >>To unsubscribe, e-mail: >><mailto:[EMAIL PROTECTED]> >>For additional commands, e-mail: >><mailto:[EMAIL PROTECTED]> >> >> >> >>-- >>To unsubscribe, e-mail: ><mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: ><mailto:[EMAIL PROTECTED]> > > >-- >To unsubscribe, e-mail: ><mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: ><mailto:[EMAIL PROTECTED]> > > > >-- >To unsubscribe, e-mail: ><mailto:struts-user->[EMAIL PROTECTED]> >For >additional commands, >e-mail: <mailto:[EMAIL PROTECTED]> > > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>