On Fri, Dec 07, 2001 at 09:56:41AM -0500, Geoffrey Talvola wrote: > >1. Thread safety -- it's a noble goal with many benefits once you > > achieve it. However, no one will be able to achieve it with > > typical Webware usage as long as the Page servlet is not > > thread-safe. For want of convenience (eg, beging able to call > > self.response() instead of self.trans().response()) we have lost > > thread-safety. I contend that Webware out-of-the-box should be > > thread-safe. I would, however, leave the default value returned > > by Servlet.canBeThreaded() false, so the unsuspecting coder > > doesn't end up in a mess. > > I actually don't see the benefit of thread safety in servlets in > Webware. It's really nice to be able to store stuff in instance variables > during the processing of a request. WebKit creates new servlet instances > to handle simultaneous requests. Where's the big benefit of thread > safety? It leads to more convoluted code in many cases, that's for sure.
Also, the only benefit of thread-safe instances isn't that big: memory. The only difference is 10 instances vs. 1 -- but 1 thread-safe instance will often use nearly the same memory as 10 unsafe instances, since all the state that was kept in instance variables has to be kept somewhere else -- local variables, etc. -- Ian Bicking Colorstudy Web Design [EMAIL PROTECTED] http://www.colorstudy.com 4769 N Talman Ave, Chicago, IL 60625 / (773) 275-7241 _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss
