Package zipkin2.reporter.libthrift
Class LibthriftSender
- java.lang.Object
-
- zipkin2.Component
-
- zipkin2.reporter.Sender
-
- zipkin2.reporter.libthrift.LibthriftSender
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public final class LibthriftSender extends zipkin2.reporter.SenderBlocking reporter that sends spans to Zipkin via Scribe.This sender is not thread-safe.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classLibthriftSender.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description zipkin2.CheckResultcheck()Sends an empty log message to the configured host.voidclose()static LibthriftSendercreate(String host)Creates a sender that sendsEncoding.THRIFTmessages.zipkin2.codec.Encodingencoding()intmessageMaxBytes()intmessageSizeInBytes(int encodedSizeInBytes)intmessageSizeInBytes(List<byte[]> encodedSpans)Size of the Thrift RPC messagestatic LibthriftSender.BuildernewBuilder()zipkin2.Call<Void>sendSpans(List<byte[]> encodedSpans)LibthriftSender.BuildertoBuilder()StringtoString()
-
-
-
Method Detail
-
create
public static LibthriftSender create(String host)
Creates a sender that sendsEncoding.THRIFTmessages.
-
newBuilder
public static LibthriftSender.Builder newBuilder()
-
toBuilder
public LibthriftSender.Builder toBuilder()
-
encoding
public zipkin2.codec.Encoding encoding()
- Specified by:
encodingin classzipkin2.reporter.Sender
-
messageMaxBytes
public int messageMaxBytes()
- Specified by:
messageMaxBytesin classzipkin2.reporter.Sender
-
messageSizeInBytes
public int messageSizeInBytes(int encodedSizeInBytes)
- Overrides:
messageSizeInBytesin classzipkin2.reporter.Sender
-
messageSizeInBytes
public int messageSizeInBytes(List<byte[]> encodedSpans)
Size of the Thrift RPC message- Specified by:
messageSizeInBytesin classzipkin2.reporter.Sender
-
sendSpans
public zipkin2.Call<Void> sendSpans(List<byte[]> encodedSpans)
- Specified by:
sendSpansin classzipkin2.reporter.Sender
-
check
public zipkin2.CheckResult check()
Sends an empty log message to the configured host.- Overrides:
checkin classzipkin2.Component
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classzipkin2.Component- Throws:
IOException
-
-