@opentelemetry/instrumentation-http 0.201.1 → 0.202.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/build/src/index.d.ts +1 -1
- package/build/src/index.js.map +1 -1
- package/build/src/types.d.ts +1 -1
- package/build/src/types.js.map +1 -1
- package/build/src/version.d.ts +1 -1
- package/build/src/version.js +1 -1
- package/build/src/version.js.map +1 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -82,7 +82,7 @@ See the [HTTP semconv migration plan for OpenTelemetry JS instrumentations](http
|
|
|
82
82
|
To select which semconv version(s) is emitted from this instrumentation, use the `OTEL_SEMCONV_STABILITY_OPT_IN` environment variable.
|
|
83
83
|
|
|
84
84
|
- `http`: emit the new (stable) v1.23.0+ semantics
|
|
85
|
-
- `http/
|
|
85
|
+
- `http/dup`: emit **both** the old v1.7.0 and the new (stable) v1.23.0+ semantics
|
|
86
86
|
- By default, if `OTEL_SEMCONV_STABILITY_OPT_IN` includes neither of the above tokens, the old v1.7.0 semconv is used.
|
|
87
87
|
|
|
88
88
|
### Attributes collected
|
package/build/src/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { HttpInstrumentation } from './http';
|
|
2
|
-
export { HttpCustomAttributeFunction, HttpInstrumentationConfig, HttpRequestCustomAttributeFunction, HttpResponseCustomAttributeFunction, IgnoreIncomingRequestFunction, IgnoreOutgoingRequestFunction, StartIncomingSpanCustomAttributeFunction, StartOutgoingSpanCustomAttributeFunction, } from './types';
|
|
2
|
+
export type { HttpCustomAttributeFunction, HttpInstrumentationConfig, HttpRequestCustomAttributeFunction, HttpResponseCustomAttributeFunction, IgnoreIncomingRequestFunction, IgnoreOutgoingRequestFunction, StartIncomingSpanCustomAttributeFunction, StartOutgoingSpanCustomAttributeFunction, } from './types';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
package/build/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,+BAA6C;AAApC,2GAAA,mBAAmB,OAAA","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport { HttpInstrumentation } from './http';\nexport {\n HttpCustomAttributeFunction,\n HttpInstrumentationConfig,\n HttpRequestCustomAttributeFunction,\n HttpResponseCustomAttributeFunction,\n IgnoreIncomingRequestFunction,\n IgnoreOutgoingRequestFunction,\n StartIncomingSpanCustomAttributeFunction,\n StartOutgoingSpanCustomAttributeFunction,\n} from './types';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,+BAA6C;AAApC,2GAAA,mBAAmB,OAAA","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport { HttpInstrumentation } from './http';\nexport type {\n HttpCustomAttributeFunction,\n HttpInstrumentationConfig,\n HttpRequestCustomAttributeFunction,\n HttpResponseCustomAttributeFunction,\n IgnoreIncomingRequestFunction,\n IgnoreOutgoingRequestFunction,\n StartIncomingSpanCustomAttributeFunction,\n StartOutgoingSpanCustomAttributeFunction,\n} from './types';\n"]}
|
package/build/src/types.d.ts
CHANGED
|
@@ -24,7 +24,7 @@ export interface StartOutgoingSpanCustomAttributeFunction {
|
|
|
24
24
|
(request: RequestOptions): Attributes;
|
|
25
25
|
}
|
|
26
26
|
/**
|
|
27
|
-
* Options available for the HTTP instrumentation (see [documentation](https://github.com/open-telemetry/opentelemetry-js/tree/main/packages/opentelemetry-instrumentation-http#http-instrumentation-options))
|
|
27
|
+
* Options available for the HTTP instrumentation (see [documentation](https://github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-instrumentation-http#http-instrumentation-options))
|
|
28
28
|
*/
|
|
29
29
|
export interface HttpInstrumentationConfig extends InstrumentationConfig {
|
|
30
30
|
/** Not trace all incoming requests that matched with custom function */
|
package/build/src/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { Span, Attributes } from '@opentelemetry/api';\nimport {\n ClientRequest,\n IncomingMessage,\n ServerResponse,\n RequestOptions,\n} from 'http';\nimport { InstrumentationConfig } from '@opentelemetry/instrumentation';\n\nexport interface HttpCustomAttributeFunction {\n (\n span: Span,\n request: ClientRequest | IncomingMessage,\n response: IncomingMessage | ServerResponse\n ): void;\n}\n\nexport interface IgnoreIncomingRequestFunction {\n (request: IncomingMessage): boolean;\n}\n\nexport interface IgnoreOutgoingRequestFunction {\n (request: RequestOptions): boolean;\n}\n\nexport interface HttpRequestCustomAttributeFunction {\n (span: Span, request: ClientRequest | IncomingMessage): void;\n}\n\nexport interface HttpResponseCustomAttributeFunction {\n (span: Span, response: IncomingMessage | ServerResponse): void;\n}\n\nexport interface StartIncomingSpanCustomAttributeFunction {\n (request: IncomingMessage): Attributes;\n}\n\nexport interface StartOutgoingSpanCustomAttributeFunction {\n (request: RequestOptions): Attributes;\n}\n\n/**\n * Options available for the HTTP instrumentation (see [documentation](https://github.com/open-telemetry/opentelemetry-js/tree/main/packages/opentelemetry-instrumentation-http#http-instrumentation-options))\n */\nexport interface HttpInstrumentationConfig extends InstrumentationConfig {\n /** Not trace all incoming requests that matched with custom function */\n ignoreIncomingRequestHook?: IgnoreIncomingRequestFunction;\n /** Not trace all outgoing requests that matched with custom function */\n ignoreOutgoingRequestHook?: IgnoreOutgoingRequestFunction;\n /** If set to true, incoming requests will not be instrumented at all. */\n disableIncomingRequestInstrumentation?: boolean;\n /** If set to true, outgoing requests will not be instrumented at all. */\n disableOutgoingRequestInstrumentation?: boolean;\n /** Function for adding custom attributes after response is handled */\n applyCustomAttributesOnSpan?: HttpCustomAttributeFunction;\n /** Function for adding custom attributes before request is handled */\n requestHook?: HttpRequestCustomAttributeFunction;\n /** Function for adding custom attributes before response is handled */\n responseHook?: HttpResponseCustomAttributeFunction;\n /** Function for adding custom attributes before a span is started in incomingRequest */\n startIncomingSpanHook?: StartIncomingSpanCustomAttributeFunction;\n /** Function for adding custom attributes before a span is started in outgoingRequest */\n startOutgoingSpanHook?: StartOutgoingSpanCustomAttributeFunction;\n /** The primary server name of the matched virtual host. */\n serverName?: string;\n /** Require parent to create span for outgoing requests */\n requireParentforOutgoingSpans?: boolean;\n /** Require parent to create span for incoming requests */\n requireParentforIncomingSpans?: boolean;\n /** Map the following HTTP headers to span attributes. */\n headersToSpanAttributes?: {\n client?: { requestHeaders?: string[]; responseHeaders?: string[] };\n server?: { requestHeaders?: string[]; responseHeaders?: string[] };\n };\n /**\n * Enable automatic population of synthetic source type based on the user-agent header\n * @experimental\n **/\n enableSyntheticSourceDetection?: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { Span, Attributes } from '@opentelemetry/api';\nimport {\n ClientRequest,\n IncomingMessage,\n ServerResponse,\n RequestOptions,\n} from 'http';\nimport { InstrumentationConfig } from '@opentelemetry/instrumentation';\n\nexport interface HttpCustomAttributeFunction {\n (\n span: Span,\n request: ClientRequest | IncomingMessage,\n response: IncomingMessage | ServerResponse\n ): void;\n}\n\nexport interface IgnoreIncomingRequestFunction {\n (request: IncomingMessage): boolean;\n}\n\nexport interface IgnoreOutgoingRequestFunction {\n (request: RequestOptions): boolean;\n}\n\nexport interface HttpRequestCustomAttributeFunction {\n (span: Span, request: ClientRequest | IncomingMessage): void;\n}\n\nexport interface HttpResponseCustomAttributeFunction {\n (span: Span, response: IncomingMessage | ServerResponse): void;\n}\n\nexport interface StartIncomingSpanCustomAttributeFunction {\n (request: IncomingMessage): Attributes;\n}\n\nexport interface StartOutgoingSpanCustomAttributeFunction {\n (request: RequestOptions): Attributes;\n}\n\n/**\n * Options available for the HTTP instrumentation (see [documentation](https://github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-instrumentation-http#http-instrumentation-options))\n */\nexport interface HttpInstrumentationConfig extends InstrumentationConfig {\n /** Not trace all incoming requests that matched with custom function */\n ignoreIncomingRequestHook?: IgnoreIncomingRequestFunction;\n /** Not trace all outgoing requests that matched with custom function */\n ignoreOutgoingRequestHook?: IgnoreOutgoingRequestFunction;\n /** If set to true, incoming requests will not be instrumented at all. */\n disableIncomingRequestInstrumentation?: boolean;\n /** If set to true, outgoing requests will not be instrumented at all. */\n disableOutgoingRequestInstrumentation?: boolean;\n /** Function for adding custom attributes after response is handled */\n applyCustomAttributesOnSpan?: HttpCustomAttributeFunction;\n /** Function for adding custom attributes before request is handled */\n requestHook?: HttpRequestCustomAttributeFunction;\n /** Function for adding custom attributes before response is handled */\n responseHook?: HttpResponseCustomAttributeFunction;\n /** Function for adding custom attributes before a span is started in incomingRequest */\n startIncomingSpanHook?: StartIncomingSpanCustomAttributeFunction;\n /** Function for adding custom attributes before a span is started in outgoingRequest */\n startOutgoingSpanHook?: StartOutgoingSpanCustomAttributeFunction;\n /** The primary server name of the matched virtual host. */\n serverName?: string;\n /** Require parent to create span for outgoing requests */\n requireParentforOutgoingSpans?: boolean;\n /** Require parent to create span for incoming requests */\n requireParentforIncomingSpans?: boolean;\n /** Map the following HTTP headers to span attributes. */\n headersToSpanAttributes?: {\n client?: { requestHeaders?: string[]; responseHeaders?: string[] };\n server?: { requestHeaders?: string[]; responseHeaders?: string[] };\n };\n /**\n * Enable automatic population of synthetic source type based on the user-agent header\n * @experimental\n **/\n enableSyntheticSourceDetection?: boolean;\n}\n"]}
|
package/build/src/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.202.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/build/src/version.js
CHANGED
package/build/src/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,4DAA4D;AAC/C,QAAA,OAAO,GAAG,SAAS,CAAC","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// this is autogenerated file, see scripts/version-update.js\nexport const VERSION = '0.
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,4DAA4D;AAC/C,QAAA,OAAO,GAAG,SAAS,CAAC","sourcesContent":["/*\n * Copyright The OpenTelemetry Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// this is autogenerated file, see scripts/version-update.js\nexport const VERSION = '0.202.0';\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opentelemetry/instrumentation-http",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.202.0",
|
|
4
4
|
"description": "OpenTelemetry instrumentation for `node:http` and `node:https` http client and server modules",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"types": "build/src/index.d.ts",
|
|
@@ -73,11 +73,11 @@
|
|
|
73
73
|
},
|
|
74
74
|
"dependencies": {
|
|
75
75
|
"@opentelemetry/core": "2.0.1",
|
|
76
|
-
"@opentelemetry/instrumentation": "0.
|
|
76
|
+
"@opentelemetry/instrumentation": "0.202.0",
|
|
77
77
|
"@opentelemetry/semantic-conventions": "^1.29.0",
|
|
78
78
|
"forwarded-parse": "2.1.2"
|
|
79
79
|
},
|
|
80
80
|
"homepage": "https://github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-instrumentation-http",
|
|
81
81
|
"sideEffects": false,
|
|
82
|
-
"gitHead": "
|
|
82
|
+
"gitHead": "55f8c20b19777602f993328fe07f523cf465dea3"
|
|
83
83
|
}
|