- java.lang.Object
-
- zipkin2.Component
-
- zipkin2.reporter.Sender
-
- zipkin2.reporter.okhttp3.OkHttpSender
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classOkHttpSender.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description zipkin2.CheckResultcheck()Sends an empty json message to the configured endpoint.voidclose()Waits up to a second for in-flight requests to finish before cancelling themstatic OkHttpSendercreate(java.lang.String endpoint)Creates a sender that postsEncoding.JSONmessages.zipkin2.codec.Encodingencoding()intmessageMaxBytes()intmessageSizeInBytes(int encodedSizeInBytes)intmessageSizeInBytes(java.util.List<byte[]> encodedSpans)static OkHttpSender.BuildernewBuilder()zipkin2.Call<java.lang.Void>sendSpans(java.util.List<byte[]> encodedSpans)The returned call sends spans as a POST toOkHttpSender.Builder.endpoint(String).OkHttpSender.BuildertoBuilder()Creates a builder out of this object.java.lang.StringtoString()
-
-
-
Method Detail
-
create
public static OkHttpSender create(java.lang.String endpoint)
Creates a sender that postsEncoding.JSONmessages.
-
newBuilder
public static OkHttpSender.Builder newBuilder()
-
toBuilder
public final OkHttpSender.Builder toBuilder()
Creates a builder out of this object. Note: if theOkHttpSender.Builder.clientBuilder()was customized, you'll need to re-apply those customizations.
-
messageSizeInBytes
public int messageSizeInBytes(java.util.List<byte[]> encodedSpans)
- Specified by:
messageSizeInBytesin classSender
-
messageSizeInBytes
public int messageSizeInBytes(int encodedSizeInBytes)
- Overrides:
messageSizeInBytesin classSender
-
messageMaxBytes
public int messageMaxBytes()
- Specified by:
messageMaxBytesin classSender
-
sendSpans
public zipkin2.Call<java.lang.Void> sendSpans(java.util.List<byte[]> encodedSpans)
The returned call sends spans as a POST toOkHttpSender.Builder.endpoint(String).
-
check
public zipkin2.CheckResult check()
Sends an empty json message to the configured endpoint.- Overrides:
checkin classzipkin2.Component
-
close
public void close()
Waits up to a second for in-flight requests to finish before cancelling them- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- Overrides:
closein classzipkin2.Component
-
toString
public final java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-