test_class.declarator: reporter
test_class.modifier: private
test_class.original_string: private ElasticsearchSpanReporter reporter;
test_class.type: ElasticsearchSpanReporter
test_class.var_name: reporter
test_class.file: stagemonitor-tracing-elasticsearch/src/test/java/org/stagemonitor/tracing/elasticsearch/ElasticsearchSpanReporterTest.java
test_class.identifier: ElasticsearchSpanReporterTest
test_class.superclass: extends AbstractElasticsearchSpanReporterTest
test_case.body: @Test
  	public void testLogReportSpan() throws Exception {
  		Mockito.when(elasticsearchTracingPlugin.isOnlyLogElasticsearchSpanReports()).thenReturn(true);
  		final SpanContextInformation spanContext = reportSpanWithCallTree(1000, "Report Me");
  
  		final List<MockSpan> sampledSpans = getSampledSpans();
  		assertThat(sampledSpans).hasSize(1);
  		Mockito.verify(httpClient, Mockito.times(0)).send(any(), any(), any(), any(), any());
  		Mockito.verify(spanLogger).info(ArgumentMatchers.startsWith("{\"index\":{\"_index\":\"stagemonitor-spans-" + StringUtils.getLogstashStyleDate() + "\",\"_type\":\"spans\"}}\n"));
  		Assert.assertTrue(reporter.isActive(spanContext));
  	}
test_case.class_method_signature: ElasticsearchSpanReporterTest.testLogReportSpan()
test_case.full_signature: @Test public void testLogReportSpan()
test_case.identifier: testLogReportSpan
test_case.invocations: thenReturn when isOnlyLogElasticsearchSpanReports reportSpanWithCallTree getSampledSpans hasSize assertThat send verify times any any any any any info verify startsWith getLogstashStyleDate assertTrue isActive
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testLogReportSpan()
focal_class.declarator: spansDroppedMetricName = name("elasticsearch_spans_dropped").build()
focal_class.modifier: static final
focal_class.original_string: static final MetricName spansDroppedMetricName = name("elasticsearch_spans_dropped").build();
focal_class.type: MetricName
focal_class.var_name: spansDroppedMetricName
focal_class.declarator: bulkSizeMetricName = name("elasticsearch_spans_bulk_size").build()
focal_class.modifier: static final
focal_class.original_string: static final MetricName bulkSizeMetricName = name("elasticsearch_spans_bulk_size").build();
focal_class.type: MetricName
focal_class.var_name: bulkSizeMetricName
focal_class.declarator: ES_SPAN_LOGGER = "ElasticsearchSpanReporter"
focal_class.modifier: static final
focal_class.original_string: static final String ES_SPAN_LOGGER = "ElasticsearchSpanReporter";
focal_class.type: String
focal_class.var_name: ES_SPAN_LOGGER
focal_class.declarator: UTF_8 = Charset.forName("UTF-8")
focal_class.modifier: static final
focal_class.original_string: static final Charset UTF_8 = Charset.forName("UTF-8");
focal_class.type: Charset
focal_class.var_name: UTF_8
focal_class.declarator: indexHeader = "{\"index\":{}}\n".getBytes(UTF_8)
focal_class.modifier: private static final
focal_class.original_string: private static final byte[] indexHeader = "{\"index\":{}}\n".getBytes(UTF_8);
focal_class.type: byte[]
focal_class.var_name: indexHeader
focal_class.declarator: SPANS_TYPE = "spans"
focal_class.modifier: private static final
focal_class.original_string: private static final String SPANS_TYPE = "spans";
focal_class.type: String
focal_class.var_name: SPANS_TYPE
focal_class.declarator: logger = LoggerFactory.getLogger(ElasticsearchSpanReporter.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger logger = LoggerFactory.getLogger(ElasticsearchSpanReporter.class);
focal_class.type: Logger
focal_class.var_name: logger
focal_class.declarator: spanLogger
focal_class.modifier: private final
focal_class.original_string: private final Logger spanLogger;
focal_class.type: Logger
focal_class.var_name: spanLogger
focal_class.declarator: spanFlushingRunnable
focal_class.modifier: private
focal_class.original_string: private SpanFlushingRunnable spanFlushingRunnable;
focal_class.type: SpanFlushingRunnable
focal_class.var_name: spanFlushingRunnable
focal_class.declarator: elasticsearchTracingPlugin
focal_class.modifier: private
focal_class.original_string: private ElasticsearchTracingPlugin elasticsearchTracingPlugin;
focal_class.type: ElasticsearchTracingPlugin
focal_class.var_name: elasticsearchTracingPlugin
focal_class.declarator: elasticsearchClient
focal_class.modifier: private
focal_class.original_string: private ElasticsearchClient elasticsearchClient;
focal_class.type: ElasticsearchClient
focal_class.var_name: elasticsearchClient
focal_class.declarator: bulkQueue
focal_class.modifier: private
focal_class.original_string: private BlockingQueue<OutputStreamHandler> bulkQueue;
focal_class.type: BlockingQueue<OutputStreamHandler>
focal_class.var_name: bulkQueue
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: metricRegistry
focal_class.modifier: private
focal_class.original_string: private Metric2Registry metricRegistry;
focal_class.type: Metric2Registry
focal_class.var_name: metricRegistry
focal_class.declarator: scheduler
focal_class.modifier: private
focal_class.original_string: private ScheduledThreadPoolExecutor scheduler;
focal_class.type: ScheduledThreadPoolExecutor
focal_class.var_name: scheduler
focal_class.declarator: updateReporter
focal_class.modifier: private
focal_class.original_string: private ElasticsearchUpdateSpanReporter updateReporter;
focal_class.type: ElasticsearchUpdateSpanReporter
focal_class.var_name: updateReporter
focal_class.file: stagemonitor-tracing-elasticsearch/src/main/java/org/stagemonitor/tracing/elasticsearch/ElasticsearchSpanReporter.java
focal_class.identifier: ElasticsearchSpanReporter
focal_class.class_method_signature: ElasticsearchSpanReporter.ElasticsearchSpanReporter()
focal_class.full_signature: public  ElasticsearchSpanReporter()
focal_class.identifier: ElasticsearchSpanReporter
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  ElasticsearchSpanReporter()
focal_class.class_method_signature: ElasticsearchSpanReporter.ElasticsearchSpanReporter(Logger spanLogger)
focal_class.full_signature:   ElasticsearchSpanReporter(Logger spanLogger)
focal_class.identifier: ElasticsearchSpanReporter
focal_class.parameters: (Logger spanLogger)
focal_class.signature:  ElasticsearchSpanReporter(Logger spanLogger)
focal_class.class_method_signature: ElasticsearchSpanReporter.init(ConfigurationRegistry configuration)
focal_class.full_signature: @Override public void init(ConfigurationRegistry configuration)
focal_class.identifier: init
focal_class.modifiers: @Override public
focal_class.parameters: (ConfigurationRegistry configuration)
focal_class.return: void
focal_class.signature: void init(ConfigurationRegistry configuration)
focal_class.class_method_signature: ElasticsearchSpanReporter.report(SpanContextInformation spanContext, final SpanWrapper spanWrapper)
focal_class.full_signature: @Override public void report(SpanContextInformation spanContext, final SpanWrapper spanWrapper)
focal_class.identifier: report
focal_class.modifiers: @Override public
focal_class.parameters: (SpanContextInformation spanContext, final SpanWrapper spanWrapper)
focal_class.return: void
focal_class.signature: void report(SpanContextInformation spanContext, final SpanWrapper spanWrapper)
focal_class.class_method_signature: ElasticsearchSpanReporter.scheduleSendBulk(OutputStreamHandler bulkBytes)
focal_class.full_signature:  void scheduleSendBulk(OutputStreamHandler bulkBytes)
focal_class.identifier: scheduleSendBulk
focal_class.parameters: (OutputStreamHandler bulkBytes)
focal_class.return: void
focal_class.signature: void scheduleSendBulk(OutputStreamHandler bulkBytes)
focal_class.class_method_signature: ElasticsearchSpanReporter.scheduleFlushIfBulkQueueExceedsMaxBatchSize()
focal_class.full_signature: private void scheduleFlushIfBulkQueueExceedsMaxBatchSize()
focal_class.identifier: scheduleFlushIfBulkQueueExceedsMaxBatchSize
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void scheduleFlushIfBulkQueueExceedsMaxBatchSize()
focal_class.class_method_signature: ElasticsearchSpanReporter.getTodaysIndexName()
focal_class.full_signature: static String getTodaysIndexName()
focal_class.identifier: getTodaysIndexName
focal_class.modifiers: static
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getTodaysIndexName()
focal_class.class_method_signature: ElasticsearchSpanReporter.isActive(SpanContextInformation spanContext)
focal_class.full_signature: @Override public boolean isActive(SpanContextInformation spanContext)
focal_class.identifier: isActive
focal_class.modifiers: @Override public
focal_class.parameters: (SpanContextInformation spanContext)
focal_class.return: boolean
focal_class.signature: boolean isActive(SpanContextInformation spanContext)
focal_class.class_method_signature: ElasticsearchSpanReporter.updateSpan(B3HeaderFormat.B3Identifiers spanIdentifiers, B3HeaderFormat.B3Identifiers newSpanIdentifiers, Map<String, Object> tagsToUpdate)
focal_class.full_signature: @Override public void updateSpan(B3HeaderFormat.B3Identifiers spanIdentifiers, B3HeaderFormat.B3Identifiers newSpanIdentifiers, Map<String, Object> tagsToUpdate)
focal_class.identifier: updateSpan
focal_class.modifiers: @Override public
focal_class.parameters: (B3HeaderFormat.B3Identifiers spanIdentifiers, B3HeaderFormat.B3Identifiers newSpanIdentifiers, Map<String, Object> tagsToUpdate)
focal_class.return: void
focal_class.signature: void updateSpan(B3HeaderFormat.B3Identifiers spanIdentifiers, B3HeaderFormat.B3Identifiers newSpanIdentifiers, Map<String, Object> tagsToUpdate)
focal_class.class_method_signature: ElasticsearchSpanReporter.getUpdateReporter()
focal_class.full_signature:  ElasticsearchUpdateSpanReporter getUpdateReporter()
focal_class.identifier: getUpdateReporter
focal_class.parameters: ()
focal_class.return: ElasticsearchUpdateSpanReporter
focal_class.signature: ElasticsearchUpdateSpanReporter getUpdateReporter()
focal_class.superclass: extends SpanReporter
focal_method.body: @Override
  	public boolean isActive(SpanContextInformation spanContext) {
  		final boolean logOnly = elasticsearchTracingPlugin.isOnlyLogElasticsearchSpanReports();
  		return elasticsearchClient.isElasticsearchAvailable() || logOnly;
  	}
focal_method.class_method_signature: ElasticsearchSpanReporter.isActive(SpanContextInformation spanContext)
focal_method.full_signature: @Override public boolean isActive(SpanContextInformation spanContext)
focal_method.identifier: isActive
focal_method.invocations: isOnlyLogElasticsearchSpanReports isElasticsearchAvailable
focal_method.modifiers: @Override public
focal_method.parameters: (SpanContextInformation spanContext)
focal_method.return: boolean
focal_method.signature: boolean isActive(SpanContextInformation spanContext)