use of com.uber.jaeger.senders.HttpSender in project cxf by apache.
the class Client method main.
public static void main(final String[] args) throws Exception {
final Metrics metrics = new Metrics(new StatsFactoryImpl(new NullStatsReporter()));
final Tracer.Builder builder = new Tracer.Builder("cxf-client", new RemoteReporter(new HttpSender("http://localhost:14268/api/traces"), 1000, 100, metrics), new ConstSampler(true));
final OpenTracingClientProvider provider = new OpenTracingClientProvider(builder.build());
final javax.ws.rs.client.Client client = ClientBuilder.newClient().register(provider);
final Response response = client.target("http://localhost:8084/catalog").request().accept(MediaType.APPLICATION_JSON).get();
LOG.info("Response: {}", response.readEntity(String.class));
response.close();
// Allow Tracer to flush
Thread.sleep(1000);
}
use of com.uber.jaeger.senders.HttpSender in project cxf by apache.
the class Server method tracer.
@Bean
Tracer tracer() {
final Metrics metrics = new Metrics(new StatsFactoryImpl(new NullStatsReporter()));
final Tracer.Builder builder = new Tracer.Builder("camel-server", new RemoteReporter(new HttpSender("http://localhost:14268/api/traces"), 1000, 100, metrics), new ConstSampler(true)).registerExtractor(Builtin.TEXT_MAP, new TextMapCodec(true));
return builder.build();
}
use of com.uber.jaeger.senders.HttpSender in project jaeger-client-java by jaegertracing.
the class ConfigurationTest method testSenderWithEndpointWithoutAuthData.
@Test
public void testSenderWithEndpointWithoutAuthData() {
System.setProperty(Configuration.JAEGER_ENDPOINT, "https://jaeger-collector:14268/api/traces");
Sender sender = Configuration.SenderConfiguration.fromEnv().getSender();
assertTrue(sender instanceof HttpSender);
}
Aggregations