I think it is better to start one background worker thread and pass the log requests to that thread with the help of a queue. You can also consider to let the worker cache the DNS lookup results. (Usually you will see requests from the same clients lots of times.)
- Matthias -----Original Message----- From: Jan Mönnich [mailto:[EMAIL PROTECTED] Sent: Thursday, February 14, 2008 4:56 PM To: Tomcat Users List Subject: Logging in separate Thread Hi folks, we want to log just the domain name a user comes from. As the required DNS reverse lookup can take some time, we would like to do the lookup and the logging in a separate thread. Is it a good idea to just start a new thread for that from a servlets doPost() method? Thanks in advance! Jan -- Dipl.-Inf. (FH) Jan Mönnich, PKI Team Phone: +49 40 808077-632, Fax: +49 40 808077-556, [EMAIL PROTECTED] DFN-CERT Services GmbH, https://www.dfn-cert.de, Phone +49 40 808077-555 Sitz / Register: Hamburg, AG Hamburg, HRB 88805, Ust-IdNr.: DE 232129737 Sachsenstraße 5, 20097 Hamburg/Germany, CEO: Dr. Klaus-Peter Kossakowski 15 Jahre DFN-CERT + 15. DFN-Workshop "Sicherheit in vernetzten Systemen" am 13./14. Februar 2008 im CCH Hamburg - https://www.dfn-cert.de/ws2008/ --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]