Search in sources :

Example 6 with StorageComponent

use of zipkin2.storage.StorageComponent in project zipkin by openzipkin.

the class ZipkinGrpcCollector method grpcCollectorConfigurator.

@Bean
ArmeriaServerConfigurator grpcCollectorConfigurator(StorageComponent storage, CollectorSampler sampler, CollectorMetrics metrics) {
    CollectorMetrics grpcMetrics = metrics.forTransport("grpc");
    Collector collector = Collector.newBuilder(getClass()).storage(storage).sampler(sampler).metrics(grpcMetrics).build();
    return sb -> sb.service("/zipkin.proto3.SpanService/Report", new SpanService(collector, grpcMetrics));
}
Also used : CommonPools(com.linecorp.armeria.common.CommonPools) CollectorSampler(zipkin2.collector.CollectorSampler) SpanBytesDecoder(zipkin2.codec.SpanBytesDecoder) Collector(zipkin2.collector.Collector) AbstractUnsafeUnaryGrpcService(com.linecorp.armeria.server.grpc.protocol.AbstractUnsafeUnaryGrpcService) ArmeriaServerConfigurator(com.linecorp.armeria.spring.ArmeriaServerConfigurator) ServiceRequestContext(com.linecorp.armeria.server.ServiceRequestContext) Executor(java.util.concurrent.Executor) CompletableFuture(java.util.concurrent.CompletableFuture) Unpooled(io.netty.buffer.Unpooled) CompletionStage(java.util.concurrent.CompletionStage) ByteBuf(io.netty.buffer.ByteBuf) Callback(zipkin2.Callback) Bean(org.springframework.context.annotation.Bean) CollectorMetrics(zipkin2.collector.CollectorMetrics) StorageComponent(zipkin2.storage.StorageComponent) ConditionalOnProperty(org.springframework.boot.autoconfigure.condition.ConditionalOnProperty) Collector(zipkin2.collector.Collector) CollectorMetrics(zipkin2.collector.CollectorMetrics) Bean(org.springframework.context.annotation.Bean)

Aggregations

StorageComponent (zipkin2.storage.StorageComponent)6 Test (org.junit.Test)3 AtomicInteger (java.util.concurrent.atomic.AtomicInteger)2 Test (org.junit.jupiter.api.Test)2 Call (zipkin2.Call)2 ForwardingStorageComponent (zipkin2.storage.ForwardingStorageComponent)2 CommonPools (com.linecorp.armeria.common.CommonPools)1 ServiceRequestContext (com.linecorp.armeria.server.ServiceRequestContext)1 AbstractUnsafeUnaryGrpcService (com.linecorp.armeria.server.grpc.protocol.AbstractUnsafeUnaryGrpcService)1 ArmeriaServerConfigurator (com.linecorp.armeria.spring.ArmeriaServerConfigurator)1 ByteBuf (io.netty.buffer.ByteBuf)1 Unpooled (io.netty.buffer.Unpooled)1 CompletableFuture (java.util.concurrent.CompletableFuture)1 CompletionStage (java.util.concurrent.CompletionStage)1 Executor (java.util.concurrent.Executor)1 ConditionalOnProperty (org.springframework.boot.autoconfigure.condition.ConditionalOnProperty)1 Bean (org.springframework.context.annotation.Bean)1 Callback (zipkin2.Callback)1 SpanBytesDecoder (zipkin2.codec.SpanBytesDecoder)1 Collector (zipkin2.collector.Collector)1