@imqueue/opentelemetry-instrumentation-imqueue
Version:
This module provides OpenTelemetry instrumentation for @imqueue
54 lines (39 loc) • 1.45 kB
Markdown
<h1 align="center">/opentelemetry-instrumentation-imqueue</h1>
<hr>
<p align="center">
<strong>This module provides automatic opentelemetry instrumentation for the </strong>
</p>
<hr>
## What Is This?
This library provides a clean way to integrate
[/rpc](https://github.com/imqueue/rpc) with
[OpenTelemetry](https://github.com/open-telemetry).
## Install
~~~bash
npm i --save /opentelemtry-instrumentation-imqueue
~~~
## Usage & API
OpenTelemetry Imqueue Instrumentation allows the user to automatically collect trace data and export them to their backend of choice, to give observability to distributed systems.
```typescript
import { NodeTracerProvider } from '@opentelemetry/sdk-trace-node';
import { registerInstrumentations } from '@opentelemetry/instrumentation';
import {
ImqueueInstrumentation,
} from '@imqueue/opentelemetry-instrumentation-imqueue';
const provider = new NodeTracerProvider();
provider.register();
registerInstrumentations({
instrumentations: [
new ImqueueInstrumentation(),
],
});
```
## Contributing
Any contributions are greatly appreciated. Feel free to fork, propose PRs, open
issues, do whatever you think may be helpful to this project. PRs which passes
all tests and do not brake tslint rules are first-class candidates to be
accepted!
## License
This project is licensed under the GNU General Public License v3.0.
See the [LICENSE](LICENSE)
Happy Coding!