An open API service indexing awesome lists of open source software.

https://github.com/expediadotcom/haystack-opencensus-exporter-java

OpenCensus Haystack Trace Exporter is an Opencensus exporter that exports data to Haystack.
https://github.com/expediadotcom/haystack-opencensus-exporter-java

distributed-tracing haystack java opencensus

Last synced: 4 months ago
JSON representation

OpenCensus Haystack Trace Exporter is an Opencensus exporter that exports data to Haystack.

Awesome Lists containing this project

README

          

[![Build Status](https://travis-ci.org/ExpediaDotCom/haystack-opencensus-exporter.svg?branch=master)](https://travis-ci.org/ExpediaDotCom/haystack-opencensus-exporter)
[![License](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg)](https://github.com/ExpediaDotCom/haystack/blob/master/LICENSE)

# Opencensus Trace Exporter for Haystack

The OpenCensus Haystack Trace Exporter is a trace exporter that exports data to Haystack.

To know about Haystack checkout [here](https://expediadotcom.github.io/haystack/)

## Quickstart

#### Add the dependencies to your project
For Maven add to your `pom.xml`:
```xml


io.opencensus
opencensus-api
0.17.0


com.expedia.www
opencensus-exporter-trace-haystack
[0.2.1,)


io.opencensus
opencensus-impl
0.17.0
runtime

```

For Gradle add to your dependencies:
```groovy
compile 'io.opencensus:opencensus-api:0.17.0'
compile 'com.expedia.www:opencensus-exporter-trace-haystack:0.2.1'
runtime 'io.opencensus:opencensus-impl:0.17.0'
```

#### Register the exporter

This will export traces to the haystack:

```java
public class MainClass {
public static void main(String[] args) throws Exception {
com.www.expedia.opencensus.exporter.trace.HaystackTraceExporter.createAndRegister(new GrpcAgentDispatcherConfig("haystack-agent", 35000), "my-service");
// ...
}
}
```

You can look into the integration test [here](src/test/scala/com/www/expedia/opencensus/exporter/trace/HaystackExporterIntegrationSpec.scala)