Package com.jamonapi

Examples of com.jamonapi.MonKeyImp


   * @see com.jamonapi.Monitor#stop
   */
  @Override
  protected Object invokeUnderTrace(MethodInvocation invocation, Log logger) throws Throwable {
    String name = createInvocationTraceName(invocation);
    MonKey key = new MonKeyImp(name, name, "ms.");

    Monitor monitor = MonitorFactory.start(key);
    try {
      return invocation.proceed();
    }
View Full Code Here


  protected void trackException(MonKey key, Throwable ex) {
    String stackTrace = "stackTrace=" + Misc.getExceptionTrace(ex);
    key.setDetails(stackTrace);

    // Specific exception counter. Example: java.lang.RuntimeException
    MonitorFactory.add(new MonKeyImp(ex.getClass().getName(), stackTrace, "Exception"), 1);

    // General exception counter which is a total for all exceptions thrown
    MonitorFactory.add(new MonKeyImp(MonitorFactory.EXCEPTIONS_LABEL, stackTrace, "Exception"), 1);
  }
View Full Code Here

TOP

Related Classes of com.jamonapi.MonKeyImp

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.