Product
Introducing Enhanced Alert Actions and Triage Functionality
Socket now supports four distinct alert actions instead of the previous two, and alert triaging allows users to override the actions taken for all individual alerts.
@opentelemetry/instrumentation-grpc
Advanced tools
Readme
Note: This is an experimental package under active development. New releases may include breaking changes.
This module provides automatic instrumentation for grpc
and @grpc/grpc-js
. Currently, version 1.x
of grpc
and version 1.x
of @grpc/grpc-js
is supported.
For automatic instrumentation see the @opentelemetry/sdk-trace-node package.
npm install --save @opentelemetry/instrumentation-grpc
OpenTelemetry gRPC Instrumentation allows the user to automatically collect trace data and export them to the backend of choice, to give observability to distributed systems when working with gRPC or (grpc-js).
To load a specific instrumentation (gRPC in this case), specify it in the Node Tracer's configuration.
const { NodeTracerProvider } = require('@opentelemetry/sdk-trace-node');
const { GrpcInstrumentation } = require('@opentelemetry/instrumentation-grpc');
const { registerInstrumentations } = require('@opentelemetry/instrumentation');
const provider = new NodeTracerProvider();
provider.addSpanProcessor(new SimpleSpanProcessor(new ConsoleSpanExporter()));
provider.register();
registerInstrumentations({
instrumentations: [new GrpcInstrumentation()]
});
See examples/grpc or examples/grpc-js for examples.
gRPC instrumentation accepts the following configuration:
Options | Type | Description |
---|---|---|
ignoreGrpcMethods | IgnoreMatcher[] | gRPC instrumentation will not trace any methods that match anything in this list. You may pass a string (case-insensitive match), a RegExp object, or a filter function. |
metadataToSpanAttributes | object | List of case insensitive metadata to convert to span attributes. Client and server (outgoing requests, incoming responses) metadata attributes will be converted to span attributes in the form of rpc.{request\response}.metadata.metadata_key , e.g. rpc.response.metadata.date |
Apache 2.0 - See LICENSE for more information.
FAQs
OpenTelemetry instrumentation for `@grpc/grpc-js` rpc client and server for gRPC framework
The npm package @opentelemetry/instrumentation-grpc receives a total of 1,010,889 weekly downloads. As such, @opentelemetry/instrumentation-grpc popularity was classified as popular.
We found that @opentelemetry/instrumentation-grpc demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket now supports four distinct alert actions instead of the previous two, and alert triaging allows users to override the actions taken for all individual alerts.
Security News
Polyfill.io has been serving malware for months via its CDN, after the project's open source maintainer sold the service to a company based in China.
Security News
OpenSSF is warning open source maintainers to stay vigilant against reputation farming on GitHub, where users artificially inflate their status by manipulating interactions on closed issues and PRs.