I wrote this part of code  but i get a warning:
The static method getLogger(class) from the class Logger should be accessed in 
a static way.
I use java 1.5 and jboss SA 4.0

What should i do??
Thanks

import java.rmi.RemoteException;
import javax.ejb.EJBException;
import javax.ejb.SessionBean;
import javax.ejb.SessionContext;

import org.apache.log4j.Level;
import org.apache.log4j.Logger;

public abstract class MasterSessionBean implements SessionBean {
        //Utilities for Logging
        private static Logger logger;
        
        
        public  MasterSessionBean() {
                 
                 logger = logger.getLogger("org.apache");
                
                log("SessionMaster()");
        }
        
        
        protected void log(String message) {
                logger.log(Level.DEBUG, message);
        }
        
        protected void warn(String message) {
                logger.log(Level.ERROR, message);
        }
}

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4107191#4107191

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4107191
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to