use of com.uber.jaeger.crossdock.resources.behavior.TraceBehavior in project jaeger-client-java by jaegertracing.
the class JerseyServer method main.
public static void main(String[] args) throws Exception {
BasicConfigurator.configure();
String serviceName = serviceNameFromEnv();
JerseyServer server = new JerseyServer("0.0.0.0:8081", serviceName, Arrays.asList(new TraceBehaviorResource(), new EndToEndBehaviorResource(new EndToEndBehavior(getEvn(SAMPLING_HOST_PORT, "jaeger-agent:5778"), "crossdock-" + serviceName, senderFromEnv(getEvn(COLLECTOR_HOST_PORT, "jaeger-collector:14268"), getEvn(AGENT_HOST, "jaeger-agent")))), new HealthResource()));
server.addNetworkListener(new NetworkListener("health", "0.0.0.0", 8080));
Builder tchannelBuilder = new Builder(serviceName);
tchannelBuilder.setServerPort(8082);
new TChannelServer(tchannelBuilder, new TraceBehavior(), server.getTracer()).start();
}
use of com.uber.jaeger.crossdock.resources.behavior.TraceBehavior in project jaeger-client-java by jaegertracing.
the class TraceBehaviorResourceTest method setUp.
@Before
public void setUp() throws Exception {
server = new JerseyServer("127.0.0.1:0", SERVICE_NAME, Collections.singletonList(new TraceBehaviorResource()));
port = String.valueOf(server.getNetworkListeners().get(0).getPort());
hostPort = String.format("127.0.0.1:%s", port);
behavior = new TraceBehavior();
}
Aggregations