public static final class HttpReporter.Builder
extends java.lang.Object
HttpReporter
.Constructor and Description |
---|
Builder(SingleAddressHttpClientBuilder<?,?> clientBuilder)
Create a new
HttpReporter.Builder using the passed SingleAddressHttpClientBuilder . |
Modifier and Type | Method and Description |
---|---|
HttpReporter.Builder |
batchSpans(int batchSizeHint,
java.time.Duration maxBatchDuration)
Configure batching of spans before sending it to the zipkin collector.
|
HttpReporter |
build()
Builds a new
HttpReporter instance with this builder's options. |
HttpReporter.Builder |
codec(Codec codec)
Sets the
Codec to encode the Spans with. |
HttpReporter.Builder |
disableSpanBatching()
Disable batching of spans before sending them to the zipkin collector.
|
HttpReporter.Builder |
maxConcurrentReports(int maxConcurrentReports)
Sets the maximum number of concurrent requests that will be made to the zipkin collector at any time.
|
public Builder(SingleAddressHttpClientBuilder<?,?> clientBuilder)
HttpReporter.Builder
using the passed SingleAddressHttpClientBuilder
.clientBuilder
- the collector SocketAddresspublic HttpReporter.Builder codec(Codec codec)
Codec
to encode the Spans with.codec
- the codec to use for this span.this
public HttpReporter.Builder maxConcurrentReports(int maxConcurrentReports)
maxConcurrentReports
- maximum number of concurrent requests that will be made to the zipkin collector
at any time.this
.public HttpReporter.Builder batchSpans(int batchSizeHint, java.time.Duration maxBatchDuration)
batchSizeHint
- Hint of how many spans should be batched together.maxBatchDuration
- Duration
of time to wait for batchSizeHint
spans in a batch.this
.public HttpReporter.Builder disableSpanBatching()
this
.public HttpReporter build()
HttpReporter
instance with this builder's options.HttpReporter