You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@sentry/opentelemetry

Package Overview
Dependencies
Maintainers
10
Versions
232
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sentry/opentelemetry - npm Package Compare versions

Comparing version

to
9.31.0

2

build/esm/package.json

@@ -1,1 +0,1 @@

{"type":"module","version":"9.30.0","sideEffects":false}
{"type":"module","version":"9.31.0","sideEffects":false}
import { Context, TextMapGetter, TextMapSetter } from '@opentelemetry/api';
import { W3CBaggagePropagator } from '@opentelemetry/core';
import { continueTrace, DynamicSamplingContext, Options } from '@sentry/core';
import { Client, continueTrace, DynamicSamplingContext, Options, Scope } from '@sentry/core';
import { LRUMap } from '@sentry/core';

@@ -33,4 +33,8 @@ /**

* Get propagation injection data for the given context.
* The additional options can be passed to override the scope and client that is otherwise derived from the context.
*/
export declare function getInjectionData(context: Context): {
export declare function getInjectionData(context: Context, options?: {
scope?: Scope;
client?: Client;
}): {
dynamicSamplingContext: Partial<DynamicSamplingContext> | undefined;

@@ -37,0 +41,0 @@ traceId: string | undefined;

import { ReadableSpan } from '@opentelemetry/sdk-trace-base';
import { TransactionEvent } from '@sentry/core';
import { SpanNode } from './utils/groupSpansWithParents';
type SpanNodeCompleted = SpanNode & {
span: ReadableSpan;
};
/**

@@ -11,3 +7,2 @@ * A Sentry-specific exporter that converts OpenTelemetry Spans to Sentry Spans & Transactions.

export declare class SentrySpanExporter {
private _flushTimeout;
private _finishedSpanBuckets;

@@ -18,2 +13,3 @@ private _finishedSpanBucketSize;

private _sentSpans;
private _debouncedFlush;
constructor(options?: {

@@ -24,22 +20,17 @@ /** Lower bound of time in seconds until spans that are buffered but have not been sent as part of a transaction get cleared from memory. */

/**
* Check if a span with the given ID has already been sent using the `_sentSpans` as a cache.
* Purges "expired" spans from the cache upon checking.
* @param spanId The span id to check.
* @returns Whether the span is already sent in the past X seconds.
* Export a single span.
* This is called by the span processor whenever a span is ended.
*/
isSpanAlreadySent(spanId: string): boolean;
/** Remove "expired" span id entries from the _sentSpans cache. */
flushSentSpanCache(): void;
/** Check if a node is a completed root node or a node whose parent has already been sent */
nodeIsCompletedRootNode(node: SpanNode): node is SpanNodeCompleted;
/** Get all completed root nodes from a list of nodes */
getCompletedRootNodes(nodes: SpanNode[]): SpanNodeCompleted[];
/** Export a single span. */
export(span: ReadableSpan): void;
/** Try to flush any pending spans immediately. */
/**
* Try to flush any pending spans immediately.
* This is called internally by the exporter (via _debouncedFlush),
* but can also be triggered externally if we force-flush.
*/
flush(): void;
/** Clear the exporter. */
/**
* Clear the exporter.
* This is called when the span processor is shut down.
*/
clear(): void;
/** Clear the flush timeout. */
private _clearTimeout;
/**

@@ -55,6 +46,11 @@ * Send the given spans, but only if they are part of a finished transaction.

private _maybeSend;
/** Remove "expired" span id entries from the _sentSpans cache. */
private _flushSentSpanCache;
/** Check if a node is a completed root node or a node whose parent has already been sent */
private _nodeIsCompletedRootNodeOrHasSentParent;
/** Get all completed root nodes from a list of nodes */
private _getCompletedRootNodes;
}
/** Exported only for tests. */
export declare function createTransactionForOtelSpan(span: ReadableSpan): TransactionEvent;
export {};
//# sourceMappingURL=spanExporter.d.ts.map

@@ -1,2 +0,2 @@

import { SerializedTraceData, Span } from '@sentry/core';
import { Client, Scope, SerializedTraceData, Span } from '@sentry/core';
/**

@@ -6,5 +6,7 @@ * Otel-specific implementation of `getTraceData`.

*/
export declare function getTraceData({ span }?: {
export declare function getTraceData({ span, scope, client, }?: {
span?: Span;
scope?: Scope;
client?: Client;
}): SerializedTraceData;
//# sourceMappingURL=getTraceData.d.ts.map
import type { Context, TextMapGetter, TextMapSetter } from '@opentelemetry/api';
import { W3CBaggagePropagator } from '@opentelemetry/core';
import type { continueTrace, DynamicSamplingContext, Options } from '@sentry/core';
import type { Client, continueTrace, DynamicSamplingContext, Options, Scope } from '@sentry/core';
import { LRUMap } from '@sentry/core';

@@ -33,4 +33,8 @@ /**

* Get propagation injection data for the given context.
* The additional options can be passed to override the scope and client that is otherwise derived from the context.
*/
export declare function getInjectionData(context: Context): {
export declare function getInjectionData(context: Context, options?: {
scope?: Scope;
client?: Client;
}): {
dynamicSamplingContext: Partial<DynamicSamplingContext> | undefined;

@@ -37,0 +41,0 @@ traceId: string | undefined;

import type { ReadableSpan } from '@opentelemetry/sdk-trace-base';
import type { TransactionEvent } from '@sentry/core';
import type { SpanNode } from './utils/groupSpansWithParents';
type SpanNodeCompleted = SpanNode & {
span: ReadableSpan;
};
/**

@@ -11,3 +7,2 @@ * A Sentry-specific exporter that converts OpenTelemetry Spans to Sentry Spans & Transactions.

export declare class SentrySpanExporter {
private _flushTimeout;
private _finishedSpanBuckets;

@@ -18,2 +13,3 @@ private _finishedSpanBucketSize;

private _sentSpans;
private _debouncedFlush;
constructor(options?: {

@@ -24,22 +20,17 @@ /** Lower bound of time in seconds until spans that are buffered but have not been sent as part of a transaction get cleared from memory. */

/**
* Check if a span with the given ID has already been sent using the `_sentSpans` as a cache.
* Purges "expired" spans from the cache upon checking.
* @param spanId The span id to check.
* @returns Whether the span is already sent in the past X seconds.
* Export a single span.
* This is called by the span processor whenever a span is ended.
*/
isSpanAlreadySent(spanId: string): boolean;
/** Remove "expired" span id entries from the _sentSpans cache. */
flushSentSpanCache(): void;
/** Check if a node is a completed root node or a node whose parent has already been sent */
nodeIsCompletedRootNode(node: SpanNode): node is SpanNodeCompleted;
/** Get all completed root nodes from a list of nodes */
getCompletedRootNodes(nodes: SpanNode[]): SpanNodeCompleted[];
/** Export a single span. */
export(span: ReadableSpan): void;
/** Try to flush any pending spans immediately. */
/**
* Try to flush any pending spans immediately.
* This is called internally by the exporter (via _debouncedFlush),
* but can also be triggered externally if we force-flush.
*/
flush(): void;
/** Clear the exporter. */
/**
* Clear the exporter.
* This is called when the span processor is shut down.
*/
clear(): void;
/** Clear the flush timeout. */
private _clearTimeout;
/**

@@ -55,6 +46,11 @@ * Send the given spans, but only if they are part of a finished transaction.

private _maybeSend;
/** Remove "expired" span id entries from the _sentSpans cache. */
private _flushSentSpanCache;
/** Check if a node is a completed root node or a node whose parent has already been sent */
private _nodeIsCompletedRootNodeOrHasSentParent;
/** Get all completed root nodes from a list of nodes */
private _getCompletedRootNodes;
}
/** Exported only for tests. */
export declare function createTransactionForOtelSpan(span: ReadableSpan): TransactionEvent;
export {};
//# sourceMappingURL=spanExporter.d.ts.map

@@ -1,2 +0,2 @@

import type { SerializedTraceData, Span } from '@sentry/core';
import type { Client, Scope, SerializedTraceData, Span } from '@sentry/core';
/**

@@ -6,5 +6,7 @@ * Otel-specific implementation of `getTraceData`.

*/
export declare function getTraceData({ span }?: {
export declare function getTraceData({ span, scope, client, }?: {
span?: Span;
scope?: Scope;
client?: Client;
}): SerializedTraceData;
//# sourceMappingURL=getTraceData.d.ts.map
{
"name": "@sentry/opentelemetry",
"version": "9.30.0",
"version": "9.31.0",
"description": "Official Sentry utilities for OpenTelemetry",

@@ -42,3 +42,3 @@ "repository": "git://github.com/getsentry/sentry-javascript.git",

"dependencies": {
"@sentry/core": "9.30.0"
"@sentry/core": "9.31.0"
},

@@ -45,0 +45,0 @@ "peerDependencies": {

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet