Package org.objectweb.util.monolog.api

Examples of org.objectweb.util.monolog.api.LoggerFactory


        properties.put("logger.org.objectweb.joram.level", "ERROR");
        // Avoid errors on CNFE (that are handled later) and a class that is missing in new joram version
        properties.put("logger.fr.dyade.aaa.agent.Service.level", "FATAL");
        properties.put("logger.org.objectweb.joram.mom.Destination.level", "FATAL");
        properties.put("logger.org.objectweb.joram.mom.Proxy.level", "FATAL");
        LoggerFactory factory = Monolog.init(properties);

        // Sets the JORAM monolog factory.
        Field field;
        try {
            field = fr.dyade.aaa.common.Debug.class.getDeclaredField("factory");
View Full Code Here


      System.setProperty(JULIA_LOADER, DEFAULT_JULIA_LOADER);
      System.setProperty(JULIA_CONFIG, DEFAULT_JULIA_CONFIG);

      //Allocate a Logger through the LoggerFactory component
      Monolog.initialize();
      LoggerFactory loggerFactory = Monolog.monologFactory;
      logger = loggerFactory.getLogger(LOGGER_NAME);

      //Choose the fractal template according to the JMX option
      String templateName;
      if (props != null && BooleanHelper.parse(
                    getProperty(props, JMX, "false", false), false)) {
View Full Code Here

    new DataStructureCreation().execute(args);
  }

  private void execute(String[] args) {
        System.out.println();
        LoggerFactory lf = Monolog.initialize();
        Logger logger = lf.getLogger(this.getClass().toString());
        logger.setLevel( BasicLevel.LEVEL_DEBUG );

    //Check parameter
    if (args.length == 0) {
      System.err.println("Usage: ");
View Full Code Here

  public void bindFc(String s, Object o) {
    if ("logger".equals(s)) {
      logger = (Logger) o;
    } else if ("monolog-factory".equals(s)) {
            LoggerFactory lf = (LoggerFactory) o;
      kfpncManager.setLogger(lf.getLogger(logger.getName() + ".kfpncmanager"));
            cpm.logger = lf.getLogger(logger.getName() + ".class-properties");
    } else if (MAPPER_BINDING.equals(s)) {
      mapper = (PMapper) o;
            cpm.mapper = mapper;
    } else if (CACHE_MANAGER_BINDING.equals(s)) {
      cache = (CacheManager) o;
View Full Code Here

        + "<logger factory class name B> "
        + "<properties file name B> "
        + "<order: A | B> ");
      System.exit(1);
    }
    LoggerFactory lfa = null;
    LoggerFactory lfb = null;
    try {
      lfa = (LoggerFactory) Class.forName(args[0]).newInstance();
      lfb = (LoggerFactory) Class.forName(args[2]).newInstance();

      Properties pa = new Properties();
View Full Code Here

*
* @author Sebastien Chassande-Barrioz
*/
public class Simple {
  public static void main(String[] args) {
    LoggerFactory lf;
    switch(args.length) {
    case 0:
      //Let monolog find the monolog.properties in the classpath or use
      // the default configuration
      lf = Monolog.initialize();
View Full Code Here

*
* @author Sebastien Chassande-Barrioz
*/
public class JMX implements NotificationListener{
  public static void main(String[] args) {
    LoggerFactory lf;
    switch(args.length) {
    case 0:
      //Let monolog find the monolog.properties in the classpath or use
      // the default configuration
      lf = Monolog.initialize();
View Full Code Here

*
* @author Sebastien Chassande-Barrioz
*/
public class Additivity {
  public static void main(String[] args) {
    LoggerFactory lf;
    switch(args.length) {
    case 0:
      //Let monolog find the monolog.properties in the classpath or use
      // the default configuration
      lf = Monolog.initialize();
      break;
    case 1:
      // A monolog configuration file has been specified, then use it
      lf = Monolog.getMonologFactory(args[0]);
      break;
    default:
      System.out.println("Syntax error!\nUsage: java Additivity [<monolog file name>]");
      return;
    }
    Logger l = lf.getLogger("monolog.examples.additivity.foo.bar");
    l.log(BasicLevel.DEBUG, "This is an additivity example");
  }
View Full Code Here

/**
* @author S.Chassande-Barrioz
*/
public class RollingFile {
    public static void main(String[] args) {
      LoggerFactory lf;
      switch(args.length) {
      case 0:
        //Let monolog find the monolog.properties in the classpath or use
        // the default configuration
        lf = Monolog.initialize();
View Full Code Here

TOP

Related Classes of org.objectweb.util.monolog.api.LoggerFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.