org.eclipse.jetty.util.log.Logger.info()方法的使用及代码示例

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

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

Logger.info介绍

[英]Logs the given message at info level, with Throwable information.
[中]在信息级别记录给定的消息,其中包含可丢弃的信息。

代码示例

代码示例来源:origin: org.eclipse.jetty/jetty-webapp

  1. private void dumpUrl()
  2. {
  3. Connector[] connectors = getServer().getConnectors();
  4. for (int i=0;i<connectors.length;i++)
  5. {
  6. String displayName = getDisplayName();
  7. if (displayName == null)
  8. displayName = "WebApp@"+Arrays.hashCode(connectors);
  9. LOG.info(displayName + " at http://" + connectors[i].toString() + getContextPath());
  10. }
  11. }

代码示例来源:origin: org.eclipse.jetty/jetty-webapp

  1. LOG.info("NO JSP Support for {}, did not find {}", context.getContextPath(), servlet_class);
  2. servlet_class = "org.eclipse.jetty.servlet.NoJspServlet";

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. private void printInfoOnLeases()
  2. {
  3. leases.forEach(lease-> LOG.info("{} requires {} threads from {}",lease.leasee,lease.getThreads(),pool));
  4. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. protected void processIncludeCipherSuites(String[] supportedCipherSuites, List<String> selected_ciphers)
  2. {
  3. for (String cipherSuite : _includeCipherSuites)
  4. {
  5. Pattern p = Pattern.compile(cipherSuite);
  6. boolean added = false;
  7. for (String supportedCipherSuite : supportedCipherSuites)
  8. {
  9. Matcher m = p.matcher(supportedCipherSuite);
  10. if (m.matches())
  11. {
  12. added = true;
  13. selected_ciphers.add(supportedCipherSuite);
  14. }
  15. }
  16. if (!added)
  17. LOG.info("No Cipher matching '{}' is supported", cipherSuite);
  18. }
  19. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. private synchronized void hook()
  2. {
  3. try
  4. {
  5. if (!_hooked)
  6. Runtime.getRuntime().addShutdownHook(this);
  7. _hooked=true;
  8. }
  9. catch(Exception e)
  10. {
  11. LOG.ignore(e);
  12. LOG.info("shutdown already commenced");
  13. }
  14. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. selected_protocols.add(protocol);
  2. else
  3. LOG.info("Protocol {} not supported in {}", protocol, Arrays.asList(supportedProtocols));

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. /**
  2. * <p>Checks leases against the given number of {@code maxThreads}.</p>
  3. *
  4. * @param maxThreads A proposed change to the maximum threads to check.
  5. * @return true if passes check, false if otherwise (see logs for details)
  6. * @throws IllegalStateException if insufficient threads are configured.
  7. */
  8. public boolean check(int maxThreads) throws IllegalStateException
  9. {
  10. int required = leases.stream()
  11. .mapToInt(Lease::getThreads)
  12. .sum();
  13. int left = maxThreads - required;
  14. if (left <= 0)
  15. {
  16. printInfoOnLeases();
  17. throw new IllegalStateException(String.format("Insufficient configured threads: required=%d < max=%d for %s", required, maxThreads, pool));
  18. }
  19. if (left < warnAt)
  20. {
  21. if (warned.compareAndSet(false,true))
  22. {
  23. printInfoOnLeases();
  24. LOG.info("Low configured threads: (max={} - required={})={} < warnAt={} for {}", maxThreads, required, left, warnAt, pool);
  25. }
  26. return false;
  27. }
  28. return true;
  29. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. LOG.info("Using Non-Native Java {}",pollingWatchServiceClass.getName());
  2. Class<?> c = Class.forName("com.sun.nio.file.SensitivityWatchEventModifier");
  3. Field f = c.getField("HIGH");

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. LOG.info(String.format("Logging initialized @%dms to %s",Uptime.getUptime(),LOG.getClass().getName()));

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. @Override
  2. public void run()
  3. {
  4. List<Sweepable> refs = items.get();
  5. if (refs == null)
  6. return;
  7. for (Sweepable sweepable : refs)
  8. {
  9. try
  10. {
  11. if (sweepable.sweep())
  12. {
  13. refs.remove(sweepable);
  14. if (LOG.isDebugEnabled())
  15. LOG.debug("Resource swept {}", sweepable);
  16. }
  17. }
  18. catch (Throwable x)
  19. {
  20. LOG.info("Exception while sweeping " + sweepable, x);
  21. }
  22. }
  23. activate();
  24. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. JLOG.info(msg,cause);
  2. JLOG.info(msg);

代码示例来源:origin: i2p/i2p.i2p

  1. Log.getLogger((String)null).info("Opened "+getDatedFilename());

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

  1. @Override
  2. public void log(String msg)
  3. {
  4. _logger.info(msg);
  5. }

代码示例来源:origin: org.eclipse.jetty/jetty-util

  1. LOG.info("x509={} for {}", x509, this);

代码示例来源:origin: org.eclipse.jetty/jetty-client

  1. private void notifyCommit(Request.CommitListener listener, Request request)
  2. {
  3. try
  4. {
  5. listener.onCommit(request);
  6. }
  7. catch (Throwable x)
  8. {
  9. LOG.info("Exception while notifying listener " + listener, x);
  10. }
  11. }

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

  1. public void bindUserTransaction (WebAppContext context)
  2. throws Exception
  3. {
  4. try
  5. {
  6. Transaction.bindToENC();
  7. }
  8. catch (NameNotFoundException e)
  9. {
  10. LOG.info("No Transaction manager found - if your webapp requires one, please configure one.");
  11. }
  12. }

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

  1. public void processBinding(Node node, App app) throws Exception
  2. {
  3. LOG.info("processBinding {} {}",node,app.getContextHandler());
  4. }
  5. }

代码示例来源:origin: org.eclipse.jetty/jetty-deploy

  1. @Override
  2. public void processBinding(Node node, App app) throws Exception
  3. {
  4. LOG.info("processBinding {} {}",node,app.getContextHandler());
  5. }
  6. }

代码示例来源:origin: org.eclipse.jetty/jetty-client

  1. private void notifyContent(Request.ContentListener listener, Request request, ByteBuffer content)
  2. {
  3. try
  4. {
  5. listener.onContent(request, content);
  6. }
  7. catch (Throwable x)
  8. {
  9. LOG.info("Exception while notifying listener " + listener, x);
  10. }
  11. }

代码示例来源:origin: org.eclipse.jetty/jetty-client

  1. private void notifyFailure(Request.FailureListener listener, Request request, Throwable failure)
  2. {
  3. try
  4. {
  5. listener.onFailure(request, failure);
  6. }
  7. catch (Throwable x)
  8. {
  9. LOG.info("Exception while notifying listener " + listener, x);
  10. }
  11. }
  12. }

相关文章