test_class.file: stagemonitor-tracing/src/test/java/org/stagemonitor/tracing/RequestMonitorTest.java
test_class.identifier: RequestMonitorTest
test_class.superclass: extends AbstractRequestMonitorTest
test_case.body: @Test
  	public void testInternalMetricsActive() throws Exception {
  		doReturn(true).when(corePlugin).isInternalMonitoringActive();
  
  		requestMonitor.monitor(createMonitoredRequest());
  		verify(registry).timer(name("internal_overhead_request_monitor").build());
  	}
test_case.class_method_signature: RequestMonitorTest.testInternalMetricsActive()
test_case.full_signature: @Test public void testInternalMetricsActive()
test_case.identifier: testInternalMetricsActive
test_case.invocations: isInternalMonitoringActive when doReturn monitor createMonitoredRequest timer verify build name
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testInternalMetricsActive()
focal_class.declarator: internalOverheadMetricName = name("internal_overhead_request_monitor").build()
focal_class.modifier: private final
focal_class.original_string: private final MetricName internalOverheadMetricName = name("internal_overhead_request_monitor").build();
focal_class.type: MetricName
focal_class.var_name: internalOverheadMetricName
focal_class.declarator: metricRegistry
focal_class.modifier: private
focal_class.original_string: private Metric2Registry metricRegistry;
focal_class.type: Metric2Registry
focal_class.var_name: metricRegistry
focal_class.declarator: corePlugin
focal_class.modifier: private
focal_class.original_string: private CorePlugin corePlugin;
focal_class.type: CorePlugin
focal_class.var_name: corePlugin
focal_class.declarator: tracingPlugin
focal_class.modifier: private
focal_class.original_string: private TracingPlugin tracingPlugin;
focal_class.type: TracingPlugin
focal_class.var_name: tracingPlugin
focal_class.declarator: currentScopeMapThreadLocal = new ThreadLocal<Map<Span, Scope>>()
focal_class.modifier: private static final
focal_class.original_string: private static final ThreadLocal<Map<Span, Scope>> currentScopeMapThreadLocal = new ThreadLocal<Map<Span, Scope>>();
focal_class.type: ThreadLocal<Map<Span, Scope>>
focal_class.var_name: currentScopeMapThreadLocal
focal_class.file: stagemonitor-tracing/src/main/java/org/stagemonitor/tracing/RequestMonitor.java
focal_class.identifier: RequestMonitor
focal_class.class_method_signature: RequestMonitor.RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry)
focal_class.full_signature: public  RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry)
focal_class.identifier: RequestMonitor
focal_class.modifiers: public
focal_class.parameters: (ConfigurationRegistry configuration, Metric2Registry registry)
focal_class.signature:  RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry)
focal_class.class_method_signature: RequestMonitor.RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry, TracingPlugin tracingPlugin)
focal_class.full_signature: private  RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry, TracingPlugin tracingPlugin)
focal_class.identifier: RequestMonitor
focal_class.modifiers: private
focal_class.parameters: (ConfigurationRegistry configuration, Metric2Registry registry, TracingPlugin tracingPlugin)
focal_class.signature:  RequestMonitor(ConfigurationRegistry configuration, Metric2Registry registry, TracingPlugin tracingPlugin)
focal_class.class_method_signature: RequestMonitor.monitorStart(MonitoredRequest monitoredRequest)
focal_class.full_signature: public SpanContextInformation monitorStart(MonitoredRequest monitoredRequest)
focal_class.identifier: monitorStart
focal_class.modifiers: public
focal_class.parameters: (MonitoredRequest monitoredRequest)
focal_class.return: SpanContextInformation
focal_class.signature: SpanContextInformation monitorStart(MonitoredRequest monitoredRequest)
focal_class.class_method_signature: RequestMonitor.monitorStart(MonitoredRequest monitoredRequest, boolean activateSpan)
focal_class.full_signature: private SpanContextInformation monitorStart(MonitoredRequest monitoredRequest, boolean activateSpan)
focal_class.identifier: monitorStart
focal_class.modifiers: private
focal_class.parameters: (MonitoredRequest monitoredRequest, boolean activateSpan)
focal_class.return: SpanContextInformation
focal_class.signature: SpanContextInformation monitorStart(MonitoredRequest monitoredRequest, boolean activateSpan)
focal_class.class_method_signature: RequestMonitor.getSpanContextInformation(long start, Span span)
focal_class.full_signature: private SpanContextInformation getSpanContextInformation(long start, Span span)
focal_class.identifier: getSpanContextInformation
focal_class.modifiers: private
focal_class.parameters: (long start, Span span)
focal_class.return: SpanContextInformation
focal_class.signature: SpanContextInformation getSpanContextInformation(long start, Span span)
focal_class.class_method_signature: RequestMonitor.monitorStop()
focal_class.full_signature: public void monitorStop()
focal_class.identifier: monitorStop
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void monitorStop()
focal_class.class_method_signature: RequestMonitor.monitorStop(Scope scope, Span span)
focal_class.full_signature: private void monitorStop(Scope scope, Span span)
focal_class.identifier: monitorStop
focal_class.modifiers: private
focal_class.parameters: (Scope scope, Span span)
focal_class.return: void
focal_class.signature: void monitorStop(Scope scope, Span span)
focal_class.class_method_signature: RequestMonitor.monitor(MonitoredRequest monitoredRequest)
focal_class.full_signature: public SpanContextInformation monitor(MonitoredRequest monitoredRequest)
focal_class.identifier: monitor
focal_class.modifiers: public
focal_class.parameters: (MonitoredRequest monitoredRequest)
focal_class.return: SpanContextInformation
focal_class.signature: SpanContextInformation monitor(MonitoredRequest monitoredRequest)
focal_class.class_method_signature: RequestMonitor.recordException(Exception e)
focal_class.full_signature: public void recordException(Exception e)
focal_class.identifier: recordException
focal_class.modifiers: public
focal_class.parameters: (Exception e)
focal_class.return: void
focal_class.signature: void recordException(Exception e)
focal_class.class_method_signature: RequestMonitor.trackOverhead(long overhead1, long overhead2)
focal_class.full_signature: private void trackOverhead(long overhead1, long overhead2)
focal_class.identifier: trackOverhead
focal_class.modifiers: private
focal_class.parameters: (long overhead1, long overhead2)
focal_class.return: void
focal_class.signature: void trackOverhead(long overhead1, long overhead2)
focal_method.body: public SpanContextInformation monitor(MonitoredRequest monitoredRequest) throws Exception {
  		if (corePlugin.isStagemonitorActive()) {
  			final long start = System.nanoTime();
  			final Span span = monitoredRequest.createSpan();
  			final Scope scope = tracingPlugin.getTracer().scopeManager().activate(span);
  			try {
  				final SpanContextInformation info = getSpanContextInformation(start, span);
  				monitoredRequest.execute();
  				return info;
  			} catch (Exception e) {
  				recordException(e);
  				throw e;
  			} finally {
  				monitorStop(scope, span);
  			}
  		}
  		return null;
  	}
focal_method.class_method_signature: RequestMonitor.monitor(MonitoredRequest monitoredRequest)
focal_method.full_signature: public SpanContextInformation monitor(MonitoredRequest monitoredRequest)
focal_method.identifier: monitor
focal_method.invocations: isStagemonitorActive nanoTime createSpan activate scopeManager getTracer getSpanContextInformation execute recordException monitorStop
focal_method.modifiers: public
focal_method.parameters: (MonitoredRequest monitoredRequest)
focal_method.return: SpanContextInformation
focal_method.signature: SpanContextInformation monitor(MonitoredRequest monitoredRequest)