On Wed, 11 Dec 2002, Jerome Jacobsen wrote:
> Date: Wed, 11 Dec 2002 13:12:49 -0500 > From: Jerome Jacobsen <[EMAIL PROTECTED]> > Reply-To: Jakarta Commons Users List <[EMAIL PROTECTED]>, > [EMAIL PROTECTED] > To: Jakarta Commons Users List <[EMAIL PROTECTED]> > Subject: RE: [Logging] Thread safety guaruntee of Log classes? > > I guessed that. However one should program to the API contract. One > benefit of using the Commons Logging API wrapper layer was to allow > switching implementations. If you are assuming thread safety as Struts > seems to be, then switching to a non-thread safe implementation would break > your application. > > So, is the contract of Log supposed to guarantee thread-safety? Despite > what Struts assumes I'll assume no until I hear otherwise. > The contract of Log *itself* makes no guarantees about thread safety. It is up to you to use (or write) a thread-safe logging implementation if you use logging in a multi-threaded environment such as a servlet container. Essentially, that's the case for *any* class library used in a multi-thread environment. Logging isn't really a special case. Craig -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
