ch.qos.logback.classic.Logger.info()方法的使用及代码示例

x33g5p2x  于2022-01-23 转载在 其他  
字(4.6k)|赞(0)|评价(0)|浏览(250)

本文整理了Java中ch.qos.logback.classic.Logger.info()方法的一些代码示例,展示了Logger.info()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.info()方法的具体详情如下:
包路径:ch.qos.logback.classic.Logger
类名称:Logger
方法名:info

Logger.info介绍

暂无

代码示例

代码示例来源:origin: SonarSource/sonarqube

@Override
protected void doInfo(String msg) {
 logback.info(msg);
}

代码示例来源:origin: SonarSource/sonarqube

@Override
protected void doInfo(String msg, Object... args) {
 logback.info(msg, args);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(String msg, Throwable e) {
  logger.info(msg, e);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(String msg, Throwable e) {
  logger.info(msg, e);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(String msg) {
  logger.info(msg);
}

代码示例来源:origin: kaaproject/kaa

@Override
 public void append(String event) {
  logger.info(event);
 }
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(String msg) {
  logger.info(msg);
}

代码示例来源:origin: SonarSource/sonarqube

@Override
protected void doInfo(String msg, @Nullable Object arg) {
 logback.info(msg, arg);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(Throwable e) {
  logger.info(e.getMessage(), e);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public void info(Throwable e) {
  logger.info(e.getMessage(), e);
}

代码示例来源:origin: SonarSource/sonarqube

@Override
protected void doInfo(String msg, @Nullable Object arg1, @Nullable Object arg2) {
 logback.info(msg, arg1, arg2);
}

代码示例来源:origin: jmxtrans/jmxtrans

@Override
public void write(String str) throws IOException{
  logger.info(str.replace("\n", "").replace(" ", delimiter));
}

代码示例来源:origin: jmxtrans/jmxtrans

@Override
public void write(char[] cbuf, int off, int len) throws IOException {
  logger.info(String.copyValueOf(cbuf, off, len).replace("\n", "").replace(" ", delimiter));
}

代码示例来源:origin: org.apache.logging.log4j/log4j-core

@Override
  public void log(final String msg) {
    LOGGER.info(msg);
  }
}

代码示例来源:origin: kairosdb/kairosdb

public RecoveryFile() throws IOException
{
  if (!StringUtils.isNullOrEmpty(arguments.exportRecoveryFile))
  {
    recoveryFile = new File(arguments.exportRecoveryFile);
    logger.info("Tracking exported metric names in " + recoveryFile.getAbsolutePath());
    if (recoveryFile.exists())
    {
      logger.info("Skipping metrics found in " + recoveryFile.getAbsolutePath());
      List<String> list = Files.readLines(recoveryFile, Charset.defaultCharset());
      metricsExported.addAll(list);
    }
    writer = new PrintWriter(new FileOutputStream(recoveryFile, true));
  }
}

代码示例来源:origin: kairosdb/kairosdb

public void startServices() throws KairosDBException
{
  Map<Key<?>, Binding<?>> bindings =
      m_injector.getAllBindings();
  for (Key<?> key : bindings.keySet())
  {
    Class<?> bindingClass = key.getTypeLiteral().getRawType();
    if (KairosDBService.class.isAssignableFrom(bindingClass))
    {
      KairosDBService service = (KairosDBService) m_injector.getInstance(bindingClass);
      logger.info("Starting service " + bindingClass);
      service.start();
      m_services.add(service);
    }
  }
}

代码示例来源:origin: ch.qos.logback/logback-classic

logger.info("Caught java.io.EOFException closing connection.");
} catch (java.net.SocketException e) {
  logger.info("Caught java.net.SocketException closing connection.");
} catch (IOException e) {
  logger.info("Caught java.io.IOException: " + e);
  logger.info("Closing connection.");
} catch (Exception e) {
  logger.error("Unexpected exception. Closing connection.", e);

代码示例来源:origin: org.apache.logging.log4j/log4j-core

@Override
public void runThroughputTest(final int lines, final Histogram histogram) {
  final long s1 = System.nanoTime();
  final Logger logger = LOGGER;
  for (int j = 0; j < lines; j++) {
    logger.info(THROUGHPUT_MSG);
  }
  final long s2 = System.nanoTime();
  final long opsPerSec = (1000L * 1000L * 1000L * lines) / (s2 - s1);
  histogram.addObservation(opsPerSec);
}

代码示例来源:origin: ch.qos.logback/logback-classic

logger.info(this + ": connected");
HardenedObjectInputStream ois = null;
try {
  logger.info(this + ": " + ex);
} catch (ClassNotFoundException ex) {
  logger.error(this + ": unknown event class");
  logger.info(this + ": connection closed");

代码示例来源:origin: org.apache.logging.log4j/log4j-core

@Override
public void runLatencyTest(final int samples, final Histogram histogram,
    final long nanoTimeCost, final int threadCount) {
  final Logger logger = LOGGER;
  for (int i = 0; i < samples; i++) {
    final long s1 = System.nanoTime();
    logger.info(LATENCY_MSG);
    final long s2 = System.nanoTime();
    final long value = s2 - s1 - nanoTimeCost;
    if (value > 0) {
      histogram.addObservation(value);
    }
    // wait 1 microsec
    final long PAUSE_NANOS = 10000 * threadCount;
    final long pauseStart = System.nanoTime();
    while (PAUSE_NANOS > (System.nanoTime() - pauseStart)) {
      // busy spin
    }
  }
}

相关文章