New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@opentelemetry/instrumentation-fetch

Package Overview
Dependencies
Maintainers
2
Versions
190
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@opentelemetry/instrumentation-fetch - npm Package Compare versions

Comparing version

to
0.30.0

1

build/esm/fetch.d.ts

@@ -22,2 +22,3 @@ import * as api from '@opentelemetry/api';

applyCustomAttributesOnSpan?: FetchCustomAttributeFunction;
ignoreNetworkEvents?: boolean;
}

@@ -24,0 +25,0 @@ /**

8

build/esm/fetch.js

@@ -71,3 +71,5 @@ /*

}, api.trace.setSpan(api.context.active(), span));
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
}
childSpan.end(corsPreFlightRequest[web.PerformanceTimingNames.RESPONSE_END]);

@@ -181,3 +183,5 @@ };

}
web.addSpanNetworkEvents(span, mainRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(span, mainRequest);
}
}

@@ -184,0 +188,0 @@ };

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

export declare const VERSION = "0.29.2";
export declare const VERSION = "0.30.0";
//# sourceMappingURL=version.d.ts.map

@@ -17,3 +17,3 @@ /*

// this is autogenerated file, see scripts/version-update.js
export var VERSION = '0.29.2';
export var VERSION = '0.30.0';
//# sourceMappingURL=version.js.map

@@ -22,2 +22,3 @@ import * as api from '@opentelemetry/api';

applyCustomAttributesOnSpan?: FetchCustomAttributeFunction;
ignoreNetworkEvents?: boolean;
}

@@ -24,0 +25,0 @@ /**

@@ -54,3 +54,5 @@ /*

}, api.trace.setSpan(api.context.active(), span));
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
}
childSpan.end(corsPreFlightRequest[web.PerformanceTimingNames.RESPONSE_END]);

@@ -162,3 +164,5 @@ }

}
web.addSpanNetworkEvents(span, mainRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(span, mainRequest);
}
}

@@ -165,0 +169,0 @@ }

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

export declare const VERSION = "0.29.2";
export declare const VERSION = "0.30.0";
//# sourceMappingURL=version.d.ts.map

@@ -17,3 +17,3 @@ /*

// this is autogenerated file, see scripts/version-update.js
export const VERSION = '0.29.2';
export const VERSION = '0.30.0';
//# sourceMappingURL=version.js.map

@@ -22,2 +22,3 @@ import * as api from '@opentelemetry/api';

applyCustomAttributesOnSpan?: FetchCustomAttributeFunction;
ignoreNetworkEvents?: boolean;
}

@@ -24,0 +25,0 @@ /**

@@ -57,3 +57,5 @@ "use strict";

}, api.trace.setSpan(api.context.active(), span));
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(childSpan, corsPreFlightRequest);
}
childSpan.end(corsPreFlightRequest[web.PerformanceTimingNames.RESPONSE_END]);

@@ -165,3 +167,5 @@ }

}
web.addSpanNetworkEvents(span, mainRequest);
if (!this._getConfig().ignoreNetworkEvents) {
web.addSpanNetworkEvents(span, mainRequest);
}
}

@@ -168,0 +172,0 @@ }

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

export declare const VERSION = "0.29.2";
export declare const VERSION = "0.30.0";
//# sourceMappingURL=version.d.ts.map

@@ -20,3 +20,3 @@ "use strict";

// this is autogenerated file, see scripts/version-update.js
exports.VERSION = '0.29.2';
exports.VERSION = '0.30.0';
//# sourceMappingURL=version.js.map
{
"name": "@opentelemetry/instrumentation-fetch",
"version": "0.29.2",
"version": "0.30.0",
"description": "OpenTelemetry fetch automatic instrumentation package.",

@@ -37,3 +37,3 @@ "main": "build/src/index.js",

"engines": {
"node": ">=8.12.0"
"node": ">=14"
},

@@ -60,5 +60,5 @@ "files": [

"@opentelemetry/api": "^1.0.0",
"@opentelemetry/context-zone": "1.3.1",
"@opentelemetry/propagator-b3": "1.3.1",
"@opentelemetry/sdk-trace-base": "1.3.1",
"@opentelemetry/context-zone": "1.4.0",
"@opentelemetry/propagator-b3": "1.4.0",
"@opentelemetry/sdk-trace-base": "1.4.0",
"@types/mocha": "8.2.3",

@@ -92,8 +92,8 @@ "@types/node": "14.17.33",

"dependencies": {
"@opentelemetry/core": "1.3.1",
"@opentelemetry/instrumentation": "0.29.2",
"@opentelemetry/sdk-trace-web": "1.3.1",
"@opentelemetry/semantic-conventions": "1.3.1"
"@opentelemetry/core": "1.4.0",
"@opentelemetry/instrumentation": "0.30.0",
"@opentelemetry/sdk-trace-web": "1.4.0",
"@opentelemetry/semantic-conventions": "1.4.0"
},
"gitHead": "51afd54bd63e46d5d530266761144c7be2f6b3a7"
"gitHead": "e39ab883b18636238ef0fd741df4ce5ed53e8d04"
}

@@ -65,5 +65,6 @@ # OpenTelemetry Fetch Instrumentation for web

| Options | Type | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- | ------------------------------------- |
| [`applyCustomAttributesOnSpan`](https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-instrumentation-fetch/src/fetch.ts#L64) | `HttpCustomAttributeFunction` | Function for adding custom attributes |
| Options | Type | Description |
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------|-----------------------------------------------------------------------------------------|
| [`applyCustomAttributesOnSpan`](https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-instrumentation-fetch/src/fetch.ts#L64) | `HttpCustomAttributeFunction` | Function for adding custom attributes |
| [`ignoreNetworkEvents`](https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-instrumentation-fetch/src/fetch.ts#L67) | `boolean` | Disable network events being added as span events (network events are added by default) |

@@ -70,0 +71,0 @@ ## Useful links

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet