This content has been marked as final.
Show 2 replies
-
1. Re: Using an @Logger instance outside of a SEAM POJO
datagazetteer Dec 15, 2006 11:14 AM (in response to datagazetteer)"DataGazetteer" wrote:
I have a feeling I'm doing something very wrong with respect to passing a reference to a log to a non-SEAM object. What happens (running under JBoss AS 4.0.5) is that the first time the non-SEAM object tries to use a log method all log output from the container stops. The application keeps running, and in fact I can remove and add the SEAM application in the deploy directory and have it redeploy but still get no logging output.
Nevermind -- it had nothing to do with SEAM after all. I was making a method call into a JAR file that was stomping on the logger's configuration. After fixing that the symptoms went away. Sorry for the bother... -
2. Re: Using an @Logger instance outside of a SEAM POJO
ccanning Dec 15, 2006 6:38 PM (in response to datagazetteer)This is how I get/create a seam logger outside of seam managed components.
import org.jboss.seam.log.Log; import org.jboss.seam.log.LogImpl; /** * This will provide various utility/helper methods for dealing with seam. * @author Charles Canning */ public class SeamHelper { private SeamHelper() { } public static Log getLogger(Class clazz) { return new LogImpl(clazz); } public static Log getLogger(String name) { return new LogImpl(name); } }