[core-tracing] Update to OpenTelemetry 0.6 (#7998)

* Migrate all packages to OpenTelemetry 0.6.1.
* Update inter-package dependencies to express the new requirements.
This commit is contained in:
Jeff Fisher 2020-04-23 15:39:57 -07:00 коммит произвёл GitHub
Родитель b964568653
Коммит 1b7428dffc
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
138 изменённых файлов: 462 добавлений и 412 удалений

Просмотреть файл

@ -42,9 +42,6 @@
*/
"allowedAlternativeVersions": {
"@azure/ms-rest-js": ["^2.0.0"],
"@azure/core-http": ["^1.1.0"],
"@azure/core-auth": ["^1.1.0"],
"@azure/core-tracing": ["1.0.0-preview.7"],
/**
* For example, allow some projects to use an older TypeScript compiler
* (in addition to whatever "usual" version is being used by other projects in the repo):

Просмотреть файл

@ -297,6 +297,20 @@ packages:
node: '>=6.0'
resolution:
integrity: sha512-xB+w7ZDAu3YBzqH44rCmG9/RlrOmFuDPt/bpf17eJr8eZSrLt7nc7LnWdxM9Mmoj/YKMHpxRg28txu3TcpiL+g==
/@opentelemetry/api/0.6.1:
dependencies:
'@opentelemetry/context-base': 0.6.1
dev: false
engines:
node: '>=8.0.0'
resolution:
integrity: sha512-wpufGZa7tTxw7eAsjXJtiyIQ42IWQdX9iUQp7ACJcKo1hCtuhLU+K2Nv1U6oRwT1oAlZTE6m4CgWKZBhOiau3Q==
/@opentelemetry/context-base/0.6.1:
dev: false
engines:
node: '>=8.0.0'
resolution:
integrity: sha512-5bHhlTBBq82ti3qPT15TRxkYTFPPQWbnkkQkmHPtqiS1XcTB69cEKd3Jm7Cfi/vkPoyxapmePE9tyA7EzLt8SQ==
/@opentelemetry/types/0.2.0:
deprecated: 'Package renamed to @opentelemetry/api, see https://github.com/open-telemetry/opentelemetry-js'
dev: false
@ -7287,13 +7301,14 @@ packages:
dev: false
name: '@rush-temp/abort-controller'
resolution:
integrity: sha512-gBGWFXTiVwNMoGJXXqwNHOQrxCGKga7Y3L6aU0gFlJOJfb0WJQ7cJ7Yib/8iQvzEsPhwx1SrGT7xIHEuHomuVg==
integrity: sha512-RfxPiKRYi0OQWzvGc7CGYlnbKScPQXBYaZpl+tTUd+Rye247kbuXP1GUl6h3/EGJipl9R8JNAgtbAmbsU/vtgg==
tarball: 'file:projects/abort-controller.tgz'
version: 0.0.0
'file:projects/ai-form-recognizer.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -7345,13 +7360,14 @@ packages:
dev: false
name: '@rush-temp/ai-form-recognizer'
resolution:
integrity: sha512-JHa0cIllPe4paUNuPPmFMz4L2QUdiWQMfHFBKH0J9/jvY6BV8qK8XnWn4QPNsRjavFSGdWHQE0S91I7kPPzQXg==
integrity: sha512-K8ztyYIvX2Of04tOP/9ZlAEoognuZEAx93aE2TstS/cePUcSWavQHM0YW74B7m7KxHM0Qjsh0FoiQPmVyLr1yg==
tarball: 'file:projects/ai-form-recognizer.tgz'
version: 0.0.0
'file:projects/ai-text-analytics.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -7404,15 +7420,17 @@ packages:
dev: false
name: '@rush-temp/ai-text-analytics'
resolution:
integrity: sha512-UaEof86AEpNg3wI9zq3agnfxIOB66LrEtywTCoAmp1K1JLWz4uEBlRfc93q3ON6Q5x5Uxj6FgoCH048EHTqSaw==
integrity: sha512-mpRxa18VIB62TO11E48bcpwfYHu4QBQBNc71rQJDOIXgurKazz5709iROIhfOm/0j60FNzVTOwBbeyTpaN574Q==
tarball: 'file:projects/ai-text-analytics.tgz'
version: 0.0.0
'file:projects/app-configuration.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
'@rollup/plugin-node-resolve': 7.1.1_rollup@1.32.1
'@rollup/plugin-replace': 2.3.1_rollup@1.32.1
@ -7428,6 +7446,7 @@ packages:
eslint-plugin-no-null: 1.0.2_eslint@6.8.0
eslint-plugin-no-only-tests: 2.4.0
eslint-plugin-promise: 4.2.1
esm: 3.2.25
mocha: 7.1.1
mocha-junit-reporter: 1.23.3_mocha@7.1.1
nock: 11.9.1
@ -7445,7 +7464,7 @@ packages:
dev: false
name: '@rush-temp/app-configuration'
resolution:
integrity: sha512-R7JV/P7e/Eu6FajLnhPwGhLltGCn9kxlJB93C2Gm8I6vH5fS8iBXci95yxdYmvC3Kx1Xdrft7DyJkubU20LP6A==
integrity: sha512-wYG9oog4OfKhAAU8nKXIIS2zbwa5mxJjcvYVhcVuDW/qd4ZIInp1Isn7NbusbM8cGpT6Th2mTnvSu+lkv4+3hA==
tarball: 'file:projects/app-configuration.tgz'
version: 0.0.0
'file:projects/core-amqp.tgz':
@ -7511,7 +7530,7 @@ packages:
dev: false
name: '@rush-temp/core-amqp'
resolution:
integrity: sha512-E2QCk2xFqHgAwqOU0R16+CrpV5VpJFsVRUVKOfJQ5e+XqJDZhM/pR4XjBOmex82Ved+RW5lCK4YYthKzvDL4Ig==
integrity: sha512-zK3WSYxcD7JGgI4vzDrpxnCQ2ZeNRWu/TpJz1GhkkTcPyU0nuw/iOWblfVCHl2E2w/YoMm0YtZ7EcOJOBusdcQ==
tarball: 'file:projects/core-amqp.tgz'
version: 0.0.0
'file:projects/core-arm.tgz':
@ -7544,7 +7563,7 @@ packages:
dev: false
name: '@rush-temp/core-arm'
resolution:
integrity: sha512-PCWnl8IizEtfiwRmLnaibfP7ZKEHmHFm1W+ngSTEsnhx37lxOEgj+Kc9JXy3jaQ1ZJj1RrbrCsoykjLSk9EqwA==
integrity: sha512-N3E8RYGfsXpEzYJB4S6Zx+0gaFGweFYUNRxb0C3AZ9+nO8qKrP3eESTPf6xH+cYhlYkORnqfgm7xrxx02GzNZQ==
tarball: 'file:projects/core-arm.tgz'
version: 0.0.0
'file:projects/core-asynciterator-polyfill.tgz':
@ -7562,7 +7581,7 @@ packages:
dev: false
name: '@rush-temp/core-asynciterator-polyfill'
resolution:
integrity: sha512-wcvU9xzocDcf6JqxBwlUIbDtU8XGBkq8n5TjQ4QYlRSFOUqjEX64a6XdMQr4dcga+OSoZw/QV/12HYPuUypK9w==
integrity: sha512-jDLggg/4sSiSb9xXQUsivEzh+w65cXOMPe/kPArXFs+LmAHaK1Et7soO3hxgmVW7AZ/5lVp8jcfW3hDXbKIFXQ==
tarball: 'file:projects/core-asynciterator-polyfill.tgz'
version: 0.0.0
'file:projects/core-auth.tgz':
@ -7570,6 +7589,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -7603,7 +7623,7 @@ packages:
dev: false
name: '@rush-temp/core-auth'
resolution:
integrity: sha512-aO0EUjVu272cbI7cz4oPe7j8/7U7mybU6OXOB0bqoGdS/mnNjADaAzZUqgZC8l4/3QSEVSAe3RqtfN9GoiLL/g==
integrity: sha512-CxMzXs+jFSjH65PB4sPZckFddDyIgImPcQO6FfxE8dGWmQkGZRn546ImUcjc6qkieSw2Xdja4njvJJlwEuNtbA==
tarball: 'file:projects/core-auth.tgz'
version: 0.0.0
'file:projects/core-http.tgz':
@ -7611,6 +7631,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@azure/logger-js': 1.3.2
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -7679,13 +7700,14 @@ packages:
dev: false
name: '@rush-temp/core-http'
resolution:
integrity: sha512-z2CqjExYE4+voKyzqewGQfH5B6KwUSCW3s4J7WHZwrzuq27x9GqKh/37xssgqdh6KTJRCpPfKUzk0o2Ep5MvyA==
integrity: sha512-zc4SXjsyuUfZG0PgMMhA6iN8exZ7Ytbwofo0/fEdRmkcABMuyFT5F5W4Io1m8n7vBj+M6smzNO6hue8Mntc1xA==
tarball: 'file:projects/core-http.tgz'
version: 0.0.0
'file:projects/core-lro.tgz':
dependencies:
'@azure/core-arm': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -7734,7 +7756,7 @@ packages:
dev: false
name: '@rush-temp/core-lro'
resolution:
integrity: sha512-i3bODjm8Lbt32ttNBV0sDmI/4FtTbrr+0RJNzn2TbJSWU1TKrhj3gLBpAIETwZv2zeN28L6grfXOMuwWCbAQIg==
integrity: sha512-bo9fWZFaJeBQmV99RfH8HpoEi/PUrBvzri15E9kcrSVf4bSbXRutJ273RLYHMzXPjCn71WCD9L9ToNEFw9Tkig==
tarball: 'file:projects/core-lro.tgz'
version: 0.0.0
'file:projects/core-paging.tgz':
@ -7752,7 +7774,7 @@ packages:
dev: false
name: '@rush-temp/core-paging'
resolution:
integrity: sha512-HtQeUV6/jtHxcEJSGOLfZj58FrapAsPl4Lirod7Yib/yXMrDIBYkkkI3Wwx5mGap+6ChPvmsBeskFIii1ZKcJg==
integrity: sha512-rRAaeqAsySfmVMMf46j6TljIPw2xVRZBVuyU9wrvQKJb1VzIEBZayG1jm9iTyyqUdFOEMn759//IfYP7KkhJNQ==
tarball: 'file:projects/core-paging.tgz'
version: 0.0.0
'file:projects/core-tracing.tgz':
@ -7760,6 +7782,7 @@ packages:
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opencensus/web-types': 0.0.7
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -7792,7 +7815,7 @@ packages:
dev: false
name: '@rush-temp/core-tracing'
resolution:
integrity: sha512-epNRqy3NyVaAMraITA7kHK3VLEWvuaobjDrCamqdJlHTEgRQel+hccelKimX4muG5Uq///tT485k9QTl8x0HXg==
integrity: sha512-zzxT9jIVWoB1sTI+P7S1JW6FMna8txObbpk2X49j8lECSXuoVMLqOEk2R7sGVjbzbL2r7ao5omfCepp/VmMYzA==
tarball: 'file:projects/core-tracing.tgz'
version: 0.0.0
'file:projects/cosmos.tgz':
@ -7853,7 +7876,7 @@ packages:
dev: false
name: '@rush-temp/cosmos'
resolution:
integrity: sha512-OgTypsYI6l4/q+Q72gEKExjsKsYogbWEFhf68oX9DCJeA3LXPh1T+VdbpWUrAg2f39Li7qnP+oHD14arFRvPQA==
integrity: sha512-D4BTSZt6/VnjR0cJx5YnIPl//42URe2aJVGUPmUWRZFXRohPgl6mzO86AbrquB4v58eVcHpKgbm5u4k3+5uYPQ==
tarball: 'file:projects/cosmos.tgz'
version: 0.0.0
'file:projects/eslint-plugin-azure-sdk.tgz':
@ -7886,7 +7909,7 @@ packages:
dev: false
name: '@rush-temp/eslint-plugin-azure-sdk'
resolution:
integrity: sha512-vDkjvie+Lt33SvBQm1/YCJGhXSIe8fRg28qxPEU2N8w6IeoSZ/Kkj5FMFW/5vBVloV/9pLKcAUla/BMmcbLSSw==
integrity: sha512-ZxedM0WTtdZDhBZ7WcjQon13C9kNvVfFk19Hz2P+cQfBj05X1LQkDiswtvP0aqCOXljBPMX/LnJPDEV+d9gNMA==
tarball: 'file:projects/eslint-plugin-azure-sdk.tgz'
version: 0.0.0
'file:projects/event-hubs.tgz':
@ -7894,6 +7917,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-inject': 4.0.1_rollup@1.32.1
@ -7964,7 +7988,7 @@ packages:
dev: false
name: '@rush-temp/event-hubs'
resolution:
integrity: sha512-CvG7r5u0JlEx6AQNVK8ehh/vnWl4tT7noTObs3AksWecHoTo/R2AbtrrS8yAvmOb1ZAyBL4bWPEsOkrgKNUWFw==
integrity: sha512-XcArDfJ1RnpY7zBibihjsHZrPVygPE1NZT1Qf28thsdi0nUo4/C1B09GvYKMlbDMZdwbTls0ub65R9jmbNz83Q==
tarball: 'file:projects/event-hubs.tgz'
version: 0.0.0
'file:projects/event-processor-host.tgz':
@ -8021,7 +8045,7 @@ packages:
dev: false
name: '@rush-temp/event-processor-host'
resolution:
integrity: sha512-hYT4SwUiZgwOlwCECcjdIyOsqhlScOWdGW5OK6T2HPyEKu2bhCFcz/C2u7yzLYL000ZBfDf7GGMaMbc6HGI3gA==
integrity: sha512-jMfybrIYGqOpFuH4rePgaQAzrG6XhcRWzmRMn1VRsWI3e6LB270YxlifWWXNHDyVkB5rsqv+GQGFQhOA1/ZFkQ==
tarball: 'file:projects/event-processor-host.tgz'
version: 0.0.0
'file:projects/eventhubs-checkpointstore-blob.tgz':
@ -8085,13 +8109,14 @@ packages:
dev: false
name: '@rush-temp/eventhubs-checkpointstore-blob'
resolution:
integrity: sha512-DXZkOK9YYemKAiq5ZIBhJB7PLfamVMe6xfovI0iYWVGOZPPNszxv9qJMCWp0/f70gaF+4cTPRQT6aRoUcYGLIQ==
integrity: sha512-DWpQOU2GJDz+sORUlex4GLuMmlydYRkiOxBeHpdCbOC+jrEjY4n2pTFxJU5LJn2n1sNmgFs+w3eBmLzHzFCz2g==
tarball: 'file:projects/eventhubs-checkpointstore-blob.tgz'
version: 0.0.0
'file:projects/identity.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8141,7 +8166,7 @@ packages:
dev: false
name: '@rush-temp/identity'
resolution:
integrity: sha512-p6BDMfvjDY6flRqZtgBOCpHVsw6WvMmnKXMO4dPS8/aymBmgOMCgn6guGfwJatko2sGOh81jedOJolzNrK1Jgg==
integrity: sha512-DDkmVi+cbgVHQovLokF7aOiI2M+m2gXmXvWm56qQuK/EaPlpTP4rL2GVCKm0Zk6hTxKxyTqSBSVgahG0PN99/w==
tarball: 'file:projects/identity.tgz'
version: 0.0.0
'file:projects/keyvault-certificates.tgz':
@ -8149,6 +8174,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8206,7 +8232,7 @@ packages:
dev: false
name: '@rush-temp/keyvault-certificates'
resolution:
integrity: sha512-zkoGg0gLf11kAFOxbtgMKCyxdZCh3NXdoQvH5oENi7NhKik4Zu0OS6HWIclJZGpsZkOBsJN/lLs2IpNQiaH/lw==
integrity: sha512-wGHtdm6msinghC/vEc5h0zdrzdtARb7kMpV2Ai12HfNL/xhefuOvyfpWMG/665f+3+KRMxJKLq9aMwmugJqUeQ==
tarball: 'file:projects/keyvault-certificates.tgz'
version: 0.0.0
'file:projects/keyvault-keys.tgz':
@ -8214,6 +8240,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8271,7 +8298,7 @@ packages:
dev: false
name: '@rush-temp/keyvault-keys'
resolution:
integrity: sha512-HY324iezOdI7/oSMZ7EzBmSDcbavPbqqED12jXGaflbFUweqP1vKy0lVYnMn4S438y1n6fP2cQ2lLIfymVA+tg==
integrity: sha512-H+dSUq2BNFWG1/ACXuFqGP3Ixxiqzb7n3A9ve7AhKQiCuvZN2Ql8rLTTUnTf4aJZaV1VrsOseXltuAMhZAExwQ==
tarball: 'file:projects/keyvault-keys.tgz'
version: 0.0.0
'file:projects/keyvault-secrets.tgz':
@ -8279,6 +8306,7 @@ packages:
'@azure/core-tracing': 1.0.0-preview.7
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8336,7 +8364,7 @@ packages:
dev: false
name: '@rush-temp/keyvault-secrets'
resolution:
integrity: sha512-7NMpd0WnshkIeFhxqXo4fMOMNntT9fwnpDCQlpVGk3bo+nfrBHm2xnd0hPcCvvajHa0r/0jy1U6no0eLYHvdcQ==
integrity: sha512-CMf2OQzjA6YqC0/pHm3s3/uXBP777Owf+S7iDwcTA3o2URSwDMdnoDsTod2z42hjiHXxqMG+85P4+H2nq7XPJw==
tarball: 'file:projects/keyvault-secrets.tgz'
version: 0.0.0
'file:projects/logger.tgz':
@ -8389,13 +8417,14 @@ packages:
dev: false
name: '@rush-temp/logger'
resolution:
integrity: sha512-sBb1WqdClKFgTqcpBPUfP57iL4K1CbYKJSseLiSsK/eYRU32g9goRQE87rLBiygGHyR8rJ2KbYX8bFH7CZM+dw==
integrity: sha512-RVHVwRxDRhvffBiRXckWK6rsfdWgvd6hXrZWe1r3xT2rf9hWkB0DQ41SuiFyAn+4DdwGxwZZAMwdgIyTqTkYBg==
tarball: 'file:projects/logger.tgz'
version: 0.0.0
'file:projects/search-documents.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8448,13 +8477,14 @@ packages:
dev: false
name: '@rush-temp/search-documents'
resolution:
integrity: sha512-f4chM4T34e/RV0rYSHlyurnX9lwAkuDjCeRNlzqD7SjxwdY12tXHznmNuTpdNZ5meIrj5ykBZ/NNUCcEtauMPg==
integrity: sha512-K2RRCxL+dwXM9QVce48tpCuiczH/cIgu5OOy4SlQxXgH/PpZblrtsx1BzncRcJ0YYSnx3+CL4EG2r+f+kweOAQ==
tarball: 'file:projects/search-documents.tgz'
version: 0.0.0
'file:projects/service-bus.tgz':
dependencies:
'@azure/eslint-plugin-azure-sdk': 2.0.1_9e31f0f459c1656d0a7ef30429cc70f8
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-inject': 4.0.1_rollup@1.32.1
@ -8525,13 +8555,14 @@ packages:
dev: false
name: '@rush-temp/service-bus'
resolution:
integrity: sha512-kZCvW2SsVE6cmxuPm9K+Duz+zKbHwvOTpWhmw8Q92A1AaUDqZ7+MmdkJ4HZNhDfkIMKvz+zeSlEZHCq1m0x/BQ==
integrity: sha512-GDOxspRuVpFa2yvMFbBfDgbrKN8a/VNArrbwLX7RauxqDyfs1fAL4yLQEx2GbmKa1Nzdu7SPpkm2fs6tHp9lxw==
tarball: 'file:projects/service-bus.tgz'
version: 0.0.0
'file:projects/storage-blob.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -8586,13 +8617,14 @@ packages:
dev: false
name: '@rush-temp/storage-blob'
resolution:
integrity: sha512-nBq5Bu/dFXbcpLWz5+/mYIYfHU0ALy+0/+Sc8T5+fHX5Qym1CWZcug3d62r7ByrGbC1cp56prjCeQicJlbU/RQ==
integrity: sha512-phMvPXjbsXsip+koU642FfnFcKAYwgDMpfD8w1I4TWJiOsTww/EWkgjOb8bsApaVvnR38uWocAFCjWL4Roo+6Q==
tarball: 'file:projects/storage-blob.tgz'
version: 0.0.0
'file:projects/storage-file-datalake.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -8655,13 +8687,14 @@ packages:
dev: false
name: '@rush-temp/storage-file-datalake'
resolution:
integrity: sha512-4nXFDw21uCz8IzhZPyY+1iiVjQoILaT4TquYdQh+Zxd/0yo9bTtGD3RS+0kTL7oTeBWWH7wtm1itXZMWn9m8PA==
integrity: sha512-mL/wbnrnwMnD9Yw+5HAQkF3M4QdSrlycMHv7h94b4j5ZeQI9F8lKtiSosIa6rwXIwziiNtYb/ew3/rhVAUYZ8w==
tarball: 'file:projects/storage-file-datalake.tgz'
version: 0.0.0
'file:projects/storage-file-share.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -8716,13 +8749,14 @@ packages:
dev: false
name: '@rush-temp/storage-file-share'
resolution:
integrity: sha512-dqZEqYR6AOQ+j0TwqDHxwn8m9m59ULA0L+/BspZF4byqa1wzFQcWz/AbNkiRmSWUbnoFsINYHm/GRdZAdknr6A==
integrity: sha512-eQxCyPrRlOhUGsyKZOvKIig8/67r9vMHT4yG7nFxaTQ5XZdJx6EZHTlVJIoqMdIgMtiJLaR2tpseJUkixXmocw==
tarball: 'file:projects/storage-file-share.tgz'
version: 0.0.0
'file:projects/storage-queue.tgz':
dependencies:
'@azure/core-tracing': 1.0.0-preview.7
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -8776,12 +8810,13 @@ packages:
dev: false
name: '@rush-temp/storage-queue'
resolution:
integrity: sha512-Kk3PKjIXM7Qy7JYXBw6GgzpgmU6sLc35jg69liQia1SOa9q31wn+aywNbz3IyzzYPcrE7MUXPC9BgqXMkSOlzw==
integrity: sha512-ddU1bPpnC4zVKJtLij/LXJHFQ4h6Lz8o/FLSLesL1zVJn1Glcb9vvQhUmvcCmHPDGVi4UFksw32zxyXZf4BD+A==
tarball: 'file:projects/storage-queue.tgz'
version: 0.0.0
'file:projects/template.tgz':
dependencies:
'@microsoft/api-extractor': 7.7.11
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.0.2_rollup@1.32.1
@ -8826,11 +8861,12 @@ packages:
dev: false
name: '@rush-temp/template'
resolution:
integrity: sha512-dszq34YcE8ZfzfXzutsZwBXOQwa8Yn8Mki4gLB1cXxMDayJ19y9q+n0SGbaIBoMjhemKSepf01SnEqo18t+S8Q==
integrity: sha512-V2FjezpR9jYsIuKKANe1NnLaOegIdnpcFZBUtanRXd06pXRU+o/SaWxXjUq52OiInPE3maWVtWSyDBr7rkA1HA==
tarball: 'file:projects/template.tgz'
version: 0.0.0
'file:projects/test-utils-perfstress.tgz':
dependencies:
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@types/minimist': 1.2.0
'@types/node': 8.10.59
@ -8852,11 +8888,12 @@ packages:
dev: false
name: '@rush-temp/test-utils-perfstress'
resolution:
integrity: sha512-N9gjt7GrKmNuXzs9V4oJXO2tREypshK02OyYlBNejFgJqU5iHYRJGrXDCFx/HyaAqxtChsluS3SZevAzritlxA==
integrity: sha512-llteIrgXbkpAekAEi1MP2B61P/AkhA/sruWYjGVALQ8uEM6oDCvzZFvZJhLbxCUMICdOK0R+uRgwKd/vNFNZ5w==
tarball: 'file:projects/test-utils-perfstress.tgz'
version: 0.0.0
'file:projects/test-utils-recorder.tgz':
dependencies:
'@opentelemetry/api': 0.6.1
'@opentelemetry/types': 0.2.0
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.0_rollup@1.32.1
@ -8912,7 +8949,7 @@ packages:
dev: false
name: '@rush-temp/test-utils-recorder'
resolution:
integrity: sha512-9Cn45LhtWZRAbMjxiC7hLJrWxuZooFx3fFRk2QahqytfPrqa/UDIjDf/9X6astvWT9f2xsjjCCPOiUtBbrzXnw==
integrity: sha512-9sPUutu18XFjg3dxFCXUqEzjbNelany0C/7Z00k9QGXWyOQ6whujs2bf5s616v63Zs4zAQT+WwMq2m8nVW51Ag==
tarball: 'file:projects/test-utils-recorder.tgz'
version: 0.0.0
'file:projects/testhub.tgz':
@ -8933,7 +8970,7 @@ packages:
dev: false
name: '@rush-temp/testhub'
resolution:
integrity: sha512-dW7m2LfMTGWZVxeZCvuHSzjBQBmz1868xK4zIx5AQifXDsBDrrQ3wdPHnarQV4yI0wcyzcI0QnVzRJ42++O4Hg==
integrity: sha512-guDU8PdEdKCVnGxNd1JEkmqukDoc1wodkEqQCWpY1+bX4ZT+ZY520gfVcMeMHYCEO8TAAhScGNke/y7p9qBArA==
tarball: 'file:projects/testhub.tgz'
version: 0.0.0
registry: ''

Просмотреть файл

@ -51,6 +51,10 @@
{
"path": "sdk\\eventhub\\event-processor-host"
},
{
"path": "sdk\\formrecognizer\\ai-form-recognizer",
"name": "form-recognizer"
},
{
"path": "sdk\\eventhub\\testhub"
},
@ -103,6 +107,9 @@
{
"name": "eslint plugin",
"path": "common\\tools\\eslint-plugin-azure-sdk"
},
{
"path": "sdk\\test-utils\\perfstress"
}
],
"settings": {

Просмотреть файл

@ -74,10 +74,10 @@
},
"dependencies": {
"@azure/core-asynciterator-polyfill": "^1.0.0",
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -2,7 +2,8 @@
// Licensed under the MIT License.
import { getTracer } from "@azure/core-tracing";
import { Span, SpanOptions, SpanKind, CanonicalCode } from "@opentelemetry/types";
import { Span, SpanKind, CanonicalCode } from "@opentelemetry/api";
import { SpanOptions } from "@azure/core-tracing";
import { RestError } from "@azure/core-http";
@ -90,7 +91,7 @@ export class Spanner<TClient> {
...options,
spanOptions: {
...spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.AppConfiguration"

Просмотреть файл

@ -4,7 +4,9 @@
import { Spanner } from "../src/internal/tracingHelpers";
import { RestError } from "@azure/core-http";
import { getTracer } from "@azure/core-tracing";
import { SpanOptions, SpanKind, CanonicalCode } from "@opentelemetry/types";
import { SpanKind, CanonicalCode } from "@opentelemetry/api";
import { SpanOptions } from "@azure/core-tracing";
import * as assert from "assert";
interface FakeOptions {
@ -17,7 +19,6 @@ describe("tracingHelpers", () => {
const fakeOptions: FakeOptions = {
name: "fakeName",
spanOptions: {
kind: SpanKind.PRODUCER,
attributes: {
testAttribute: "testAttributeValue"
}
@ -31,8 +32,7 @@ describe("tracingHelpers", () => {
const newOptions = Spanner["addParentToOptions"](fakeOptions, parentSpan);
assert.equal("fakeName", newOptions.name);
assert.equal(parentSpan, newOptions.spanOptions.parent);
assert.equal(SpanKind.PRODUCER, newOptions.spanOptions.kind);
assert.deepEqual(parentSpan.context(), newOptions.spanOptions.parent);
assert.ok(newOptions.spanOptions.attributes, "Should have attributes set");
if (newOptions.spanOptions.attributes) {
assert.equal("Microsoft.AppConfiguration", newOptions.spanOptions.attributes["az.namespace"]);

Просмотреть файл

@ -99,7 +99,7 @@
]
},
"dependencies": {
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -66,7 +66,7 @@
"dependencies": {
"@azure/abort-controller": "^1.0.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -5,7 +5,7 @@
```ts
import { AbortSignalLike } from '@azure/abort-controller';
import { SpanOptions } from '@opentelemetry/types';
import { SpanOptions } from '@azure/core-tracing';
// @public
export interface AccessToken {

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT License.
import { AbortSignalLike } from "@azure/abort-controller";
import { SpanOptions } from "@opentelemetry/types";
import { SpanOptions } from "@azure/core-tracing";
/**
* Represents a credential capable of providing an authentication token.

Просмотреть файл

@ -130,7 +130,7 @@
"@azure/core-auth": "^1.1.2",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"@types/node-fetch": "^2.5.0",
"@types/tunnel": "^0.0.1",
"cross-env": "^6.0.3",

Просмотреть файл

@ -87,7 +87,7 @@ export function browserConfig(test = false, production = false) {
namedExports: {
chai: ["assert", "AssertionError", "should", "expect"],
events: ["EventEmitter"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),
viz({ filename: "dist-browser/browser-stats.html", sourcemap: false })

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT License.
import { getTracer, getTraceParentHeader } from "@azure/core-tracing";
import { SpanOptions, SpanKind } from "@opentelemetry/types";
import { SpanOptions, SpanKind } from "@opentelemetry/api";
import {
RequestPolicyFactory,
RequestPolicy,

Просмотреть файл

@ -9,7 +9,7 @@ import { HttpOperationResponse } from "./httpOperationResponse";
import { OperationResponse } from "./operationResponse";
import { ProxySettings } from "./serviceClient";
import { AbortSignalLike } from "@azure/abort-controller";
import { SpanOptions } from "@opentelemetry/types";
import { SpanOptions } from "@azure/core-tracing";
export type HttpMethods =
| "GET"

Просмотреть файл

@ -9,7 +9,7 @@ import {
HttpHeaders,
RequestPolicyOptions
} from "../../src/coreHttp";
import { SpanOptions, SpanContext, TraceFlags } from "@opentelemetry/types";
import { SpanOptions, SpanContext, TraceFlags } from "@opentelemetry/api";
import { setTracer, NoOpTracer, NoOpSpan } from "@azure/core-tracing";
import { tracingPolicy } from "../../src/policies/tracingPolicy";
@ -60,7 +60,7 @@ class MockTracer extends NoOpTracer {
constructor(
private traceId = "",
private spanId = "",
private flags = TraceFlags.UNSAMPLED,
private flags = TraceFlags.NONE,
private state = ""
) {
super();
@ -114,7 +114,7 @@ describe("tracingPolicy", function() {
setTracer(mockTracer);
const request = new WebResource();
request.spanOptions = {
parent: ROOT_SPAN
parent: ROOT_SPAN.context()
};
const policy = tracingPolicy().create(mockPolicy, new RequestPolicyOptions());
await policy.sendRequest(request);
@ -141,7 +141,7 @@ describe("tracingPolicy", function() {
setTracer(mockTracer);
const request = new WebResource();
request.spanOptions = {
parent: ROOT_SPAN
parent: ROOT_SPAN.context()
};
const policy = tracingPolicy().create(mockPolicy, new RequestPolicyOptions());
await policy.sendRequest(request);
@ -168,7 +168,7 @@ describe("tracingPolicy", function() {
setTracer(mockTracer);
const request = new WebResource();
request.spanOptions = {
parent: ROOT_SPAN
parent: ROOT_SPAN.context()
};
const policy = tracingPolicy().create(mockPolicy, new RequestPolicyOptions());
await policy.sendRequest(request);
@ -195,7 +195,7 @@ describe("tracingPolicy", function() {
setTracer(mockTracer);
const request = new WebResource();
request.spanOptions = {
parent: ROOT_SPAN
parent: ROOT_SPAN.context()
};
const policy = tracingPolicy().create(
{
@ -233,7 +233,7 @@ describe("tracingPolicy", function() {
setTracer(new NoOpTracer());
const request = new WebResource();
request.spanOptions = {
parent: ROOT_SPAN
parent: ROOT_SPAN.context()
};
const policy = tracingPolicy().create(mockPolicy, new RequestPolicyOptions());
await policy.sendRequest(request);

Просмотреть файл

@ -95,12 +95,12 @@
"sideEffects": false,
"dependencies": {
"@azure/abort-controller": "^1.0.0",
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"events": "^3.0.0",
"tslib": "^1.10.0"
},
"devDependencies": {
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"@microsoft/api-extractor": "7.7.11",
"@rollup/plugin-commonjs": "^11.0.1",
"@rollup/plugin-multi-entry": "^3.0.0",

Просмотреть файл

@ -119,7 +119,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
assert: ["ok", "equal", "strictEqual"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
})
]

Просмотреть файл

@ -3,6 +3,11 @@
## 1.0.0-preview.8 (Unreleased)
- Update `TestSpan` to allow setting span attributes [PR link](https://github.com/Azure/azure-sdk-for-js/pull/6565).
- [BREAKING] Migrate to OpenTelemetry 0.6 using the new `@opentelemetry/api` package. There were a few breaking changes:
- `SpanContext` now requires traceFlags to be set.
- `Tracer` has removed `recordSpanData`, `getBinaryFormat`, and `getHttpTextFormat`.
- `Tracer.getCurrentSpan` returns `undefined` instead of `null` when unset.
- `Link` objects renamed `spanContext` property to `context`.
## 1.0.0-preview.7 (2019-12-03)

Просмотреть файл

@ -59,7 +59,7 @@
"sideEffects": false,
"dependencies": {
"@opencensus/web-types": "0.0.7",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -4,18 +4,16 @@
```ts
import { Attributes } from '@opentelemetry/types';
import { BinaryFormat } from '@opentelemetry/types';
import { HttpTextFormat } from '@opentelemetry/types';
import { Attributes } from '@opentelemetry/api';
import { Span as OpenCensusSpan } from '@opencensus/web-types';
import { Tracer as OpenCensusTracer } from '@opencensus/web-types';
import { Span } from '@opentelemetry/types';
import { SpanContext } from '@opentelemetry/types';
import { SpanKind } from '@opentelemetry/types';
import { SpanOptions } from '@opentelemetry/types';
import { Status } from '@opentelemetry/types';
import { TimeInput } from '@opentelemetry/types';
import { Tracer } from '@opentelemetry/types';
import { SpanContext as OTSpanContext } from '@opentelemetry/api';
import { SpanOptions as OTSpanOptions } from '@opentelemetry/api';
import { Span } from '@opentelemetry/api';
import { SpanKind } from '@opentelemetry/api';
import { Status } from '@opentelemetry/api';
import { TimeInput } from '@opentelemetry/api';
import { Tracer } from '@opentelemetry/api';
import { TracerBase } from '@opencensus/web-types';
// @public
@ -30,7 +28,7 @@ export function getTracer(): Tracer;
// @public
export class NoOpSpan implements Span {
addEvent(_name: string, _attributes?: Attributes): this;
context(): SpanContext;
context(): OTSpanContext;
end(_endTime?: number): void;
isRecording(): boolean;
setAttribute(_key: string, _value: unknown): this;
@ -42,11 +40,8 @@ export class NoOpSpan implements Span {
// @public
export class NoOpTracer implements Tracer {
bind<T>(target: T, _span?: Span): T;
getBinaryFormat(): BinaryFormat;
getCurrentSpan(): Span;
getHttpTextFormat(): HttpTextFormat;
recordSpanData(_span: Span): void;
startSpan(_name: string, _options?: SpanOptions): Span;
startSpan(_name: string, _options?: OTSpanOptions): Span;
withSpan<T extends (...args: unknown[]) => ReturnType<T>>(_span: Span, fn: T): ReturnType<T>;
}
@ -55,9 +50,9 @@ export { OpenCensusSpan }
// @public
export class OpenCensusSpanWrapper implements Span {
constructor(span: OpenCensusSpan);
constructor(tracer: OpenCensusTracerWrapper, name: string, options?: SpanOptions);
constructor(tracer: OpenCensusTracerWrapper, name: string, options?: OTSpanOptions);
addEvent(_name: string, _attributes?: Attributes): this;
context(): SpanContext;
context(): OTSpanContext;
end(_endTime?: number): void;
getWrappedSpan(): OpenCensusSpan;
isRecording(): boolean;
@ -73,12 +68,9 @@ export { OpenCensusTracer }
export class OpenCensusTracerWrapper implements Tracer {
constructor(tracer: TracerBase);
bind<T>(_target: T, _span?: Span): T;
getBinaryFormat(): BinaryFormat;
getCurrentSpan(): Span | null;
getHttpTextFormat(): HttpTextFormat;
getCurrentSpan(): Span | undefined;
getWrappedTracer(): TracerBase;
recordSpanData(_span: Span): void;
startSpan(name: string, options?: SpanOptions): Span;
startSpan(name: string, options?: OTSpanOptions): Span;
withSpan<T extends (...args: unknown[]) => unknown>(_span: Span, _fn: T): ReturnType<T>;
}
@ -87,9 +79,20 @@ export interface OperationTracingOptions {
spanOptions?: SpanOptions;
}
export { OTSpanContext }
export { OTSpanOptions }
// @public
export function setTracer(tracer: Tracer): void;
// @public
export interface SpanContext {
spanId: string;
traceFlags: number;
traceId: string;
}
// @public
export interface SpanGraph {
roots: SpanGraphNode[];
@ -101,11 +104,19 @@ export interface SpanGraphNode {
name: string;
}
// @public
export interface SpanOptions {
attributes?: {
[key: string]: unknown;
};
parent?: SpanContext | null;
}
// @public
export class TestSpan extends NoOpSpan {
constructor(parentTracer: TestTracer, name: string, context: SpanContext, kind: SpanKind, parentSpanId?: string, startTime?: TimeInput);
constructor(parentTracer: TestTracer, name: string, context: OTSpanContext, kind: SpanKind, parentSpanId?: string, startTime?: TimeInput);
readonly attributes: Attributes;
context(): SpanContext;
context(): OTSpanContext;
end(_endTime?: number): void;
endCalled: boolean;
isRecording(): boolean;
@ -126,9 +137,15 @@ export class TestTracer extends NoOpTracer {
getKnownSpans(): TestSpan[];
getRootSpans(): TestSpan[];
getSpanGraph(traceId: string): SpanGraph;
startSpan(name: string, options?: SpanOptions): TestSpan;
startSpan(name: string, options?: OTSpanOptions): TestSpan;
}
// @public
export const enum TraceFlags {
NONE = 0,
SAMPLED = 1
}
// (No @packageDocumentation comment for this package)

Просмотреть файл

@ -82,7 +82,7 @@ export function browserConfig(test = false) {
}),
cjs({
namedExports: {
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"],
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"],
assert: ["ok", "fail", "equal", "deepEqual", "deepStrictEqual", "strictEqual"]
}
}),

Просмотреть файл

@ -11,6 +11,12 @@ export { OpenCensusTracerWrapper } from "./tracers/opencensus/openCensusTracerWr
export { TestTracer, SpanGraph, SpanGraphNode } from "./tracers/test/testTracer";
export { TestSpan } from "./tracers/test/testSpan";
// Shared interfaces
export { SpanContext, SpanOptions, TraceFlags } from "./interfaces";
// OT interfaces
export { SpanContext as OTSpanContext, SpanOptions as OTSpanOptions } from "@opentelemetry/api";
// Utilities
export {
extractSpanContextFromTraceParentHeader,

Просмотреть файл

@ -1,14 +1,56 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { SpanOptions } from "@opentelemetry/types";
/**
* Shorthand enum for common traceFlags values inside SpanContext
*/
export const enum TraceFlags {
/** No flag set. */
NONE = 0x0,
/** Caller is collecting trace information. */
SAMPLED = 0x1
}
/**
* A light interface that tries to be structurally compatible with OpenTelemetry
*/
export interface SpanContext {
/**
* UUID of a trace.
*/
traceId: string;
/**
* UUID of a Span.
*/
spanId: string;
/**
* https://www.w3.org/TR/trace-context/#trace-flags
*/
traceFlags: number;
}
/**
* An interface that enables manual propagation of Spans
*/
export interface SpanOptions {
/**
* The SpanContext that refers to a parent span, if any.
* A null value indicates that this should be a new root span,
* rather than potentially detecting a span via a context manager.
*/
parent?: SpanContext | null;
/**
* Attributes to set on the Span
*/
attributes?: { [key: string]: unknown };
}
/**
* Tracing options to set on an operation.
*/
export interface OperationTracingOptions {
/**
* OpenTelemetry SpanOptions used to create a span when tracing is enabled.
*/
spanOptions?: SpanOptions
}
/**
* OpenTelemetry SpanOptions used to create a span when tracing is enabled.
*/
spanOptions?: SpanOptions;
}

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT License.
import { NoOpTracer } from "./tracers/noop/noOpTracer";
import { Tracer } from "@opentelemetry/types";
import { Tracer } from "@opentelemetry/api";
import { getCache } from "./utils/cache";
let defaultTracer: Tracer;

Просмотреть файл

@ -1,22 +0,0 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { BinaryFormat, SpanContext } from "@opentelemetry/types";
/**
* A no-op implementation of BinaryFormat to be used when tracing is disabled.
*/
export class NoOpBinaryFormat implements BinaryFormat {
/** Serialize the given SpanContext to a buffer */
toBytes(_spanContext: SpanContext): ArrayBuffer {
return new ArrayBuffer(0);
}
/**
* Deserialize a SpanContext from binary encoding.
* Returns null if the buffer does not contain a valid SpanContext.
*/
fromBytes(_buffer: ArrayBuffer): SpanContext | null {
return null;
}
}

Просмотреть файл

@ -1,25 +0,0 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { HttpTextFormat, SpanContext } from "@opentelemetry/types";
/**
* A no-op implementation of HttpTextFormat to be used when tracing is disabled.
*/
export class NoOpHttpTextFormat implements HttpTextFormat {
/**
* Injects the given SpanContext for transmitting to a remote server.
* @param _spanContext The SpanContext to transmit
* @param _format The format of the carrier
* @param _carrier The carrier to propagate through, e.g. an HTTP request
*/
inject(_spanContext: SpanContext, _format: string, _carrier: unknown): void {}
/**
* Returns a SpanContext intance extracted from the carrier.
* @param _format the format of the carrier
* @param _carrier The carrier being used for propagation, e.g. an HTTP request
*/
extract(_format: string, _carrier: unknown): SpanContext | null {
return null;
}
}

Просмотреть файл

@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { Span, SpanContext, Attributes, Status } from "@opentelemetry/types";
import { Span, SpanContext, Attributes, Status, TraceFlags } from "@opentelemetry/api";
/**
* A no-op implementation of Span that can safely be used without side-effects.
@ -12,7 +12,8 @@ export class NoOpSpan implements Span {
context(): SpanContext {
return {
spanId: "",
traceId: ""
traceId: "",
traceFlags: TraceFlags.NONE
};
}

Просмотреть файл

@ -1,9 +1,7 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { NoOpSpan } from "./noOpSpan";
import { BinaryFormat, HttpTextFormat, Tracer, Span, SpanOptions } from "@opentelemetry/types";
import { NoOpBinaryFormat } from "./noOpBinaryFormat";
import { NoOpHttpTextFormat } from "./noOpHttpTextFormat";
import { Tracer, Span, SpanOptions } from "@opentelemetry/api";
/**
* A no-op implementation of Tracer that can be used when tracing
@ -43,26 +41,4 @@ export class NoOpTracer implements Tracer {
bind<T>(target: T, _span?: Span): T {
return target;
}
/**
* Send a pre-populated Span object to the exporter.
* @param _span The span to pass along.
*/
recordSpanData(_span: Span): void {
/* NOOP */
}
/**
* Returns the BinaryFormat interface for serializing/deserializing Spans.
*/
getBinaryFormat(): BinaryFormat {
return new NoOpBinaryFormat();
}
/**
* Returns the HttpTextFormat interface for injecting/extracting Spans.
*/
getHttpTextFormat(): HttpTextFormat {
return new NoOpHttpTextFormat();
}
}

Просмотреть файл

@ -1,11 +1,11 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { SpanContext, Span, SpanOptions, Attributes, Status } from "@opentelemetry/types";
import { SpanContext, Span, SpanOptions, Attributes, Status, TraceFlags } from "@opentelemetry/api";
import { OpenCensusTraceStateWrapper } from "./openCensusTraceStateWrapper";
import { OpenCensusTracerWrapper } from "./openCensusTracerWrapper";
import { Attributes as OpenCensusAttributes, Span as OpenCensusSpan } from "@opencensus/web-types";
function isWrappedSpan(span?: Span | SpanContext): span is OpenCensusSpanWrapper {
function isWrappedSpan(span?: Span | SpanContext | null): span is OpenCensusSpanWrapper {
return !!span && (span as OpenCensusSpanWrapper).getWrappedSpan !== undefined;
}
@ -56,8 +56,8 @@ export class OpenCensusSpanWrapper implements Span {
for (const link of options.links) {
// Since there is no way to set the link relationship, leave it as Unspecified.
this._span.addLink(
link.spanContext.traceId,
link.spanContext.spanId,
link.context.traceId,
link.context.spanId,
0 /* LinkType.UNSPECIFIED */,
link.attributes as OpenCensusAttributes
);
@ -86,7 +86,7 @@ export class OpenCensusSpanWrapper implements Span {
return {
spanId: openCensusSpanContext.spanId,
traceId: openCensusSpanContext.traceId,
traceFlags: openCensusSpanContext.options,
traceFlags: openCensusSpanContext.options as TraceFlags,
traceState: new OpenCensusTraceStateWrapper(openCensusSpanContext.traceState)
};
}

Просмотреть файл

@ -1,7 +1,7 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { TraceState } from "@opentelemetry/types";
import { TraceState } from "@opentelemetry/api";
/**
* @ignore

Просмотреть файл

@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { BinaryFormat, HttpTextFormat, Tracer, Span, SpanOptions } from "@opentelemetry/types";
import { Tracer, Span, SpanOptions } from "@opentelemetry/api";
import { OpenCensusSpanWrapper } from "./openCensusSpanWrapper";
import { TracerBase as OpenCensusTracer } from "@opencensus/web-types";
@ -37,8 +37,8 @@ export class OpenCensusTracerWrapper implements Tracer {
/**
* Returns the current Span from the current context, if available.
*/
getCurrentSpan(): Span | null {
return null;
getCurrentSpan(): Span | undefined {
return undefined;
}
/**
@ -58,26 +58,4 @@ export class OpenCensusTracerWrapper implements Tracer {
bind<T>(_target: T, _span?: Span): T {
throw new Error("Method not implemented.");
}
/**
* Send a pre-populated Span object to the exporter.
* @param _span The span to pass along.
*/
recordSpanData(_span: Span): void {
throw new Error("Method not implemented.");
}
/**
* Returns the BinaryFormat interface for serializing/deserializing Spans.
*/
getBinaryFormat(): BinaryFormat {
throw new Error("Method not implemented.");
}
/**
* Returns the HttpTextFormat interface for injecting/extracting Spans.
*/
getHttpTextFormat(): HttpTextFormat {
throw new Error("Method not implemented.");
}
}

Просмотреть файл

@ -1,6 +1,5 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { NoOpSpan } from "../noop/noOpSpan";
import {
TimeInput,
Tracer,
@ -9,7 +8,8 @@ import {
SpanContext,
CanonicalCode,
Attributes
} from "@opentelemetry/types";
} from "@opentelemetry/api";
import { NoOpSpan } from "../noop/noOpSpan";
import { TestTracer } from "./testTracer";
/**

Просмотреть файл

@ -1,8 +1,8 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { NoOpTracer } from "../noop/noOpTracer";
import { TestSpan } from "./testSpan";
import { SpanContext, SpanKind, SpanOptions } from "@opentelemetry/types";
import { NoOpTracer } from "../noop/noOpTracer";
import { SpanContext, SpanKind, SpanOptions, TraceFlags } from "@opentelemetry/api";
/**
* Simple representation of a Span that only has name and child relationships.
@ -130,7 +130,8 @@ export class TestTracer extends NoOpTracer {
const context: SpanContext = {
traceId,
spanId: this.getNextSpanId()
spanId: this.getNextSpanId(),
traceFlags: TraceFlags.NONE
};
const span = new TestSpan(
this,

Просмотреть файл

@ -1,10 +1,13 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { Tracer } from "@opentelemetry/types";
import { Tracer } from "@opentelemetry/api";
import { getGlobalObject } from "./global";
const GLOBAL_TRACER_VERSION = 2;
// V1 = OpenTelemetry 0.1
// V2 = OpenTelemetry 0.2
// V3 = OpenTelemetry 0.6.1
const GLOBAL_TRACER_VERSION = 3;
// preview5 shipped with @azure/core-tracing.tracerCache
// and didn't have smart detection for collisions
const GLOBAL_TRACER_SYMBOL = Symbol.for("@azure/core-tracing.tracerCache2");

Просмотреть файл

@ -1,7 +1,7 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import { SpanContext, TraceFlags } from "@opentelemetry/types";
import { SpanContext, TraceFlags } from "../interfaces";
const VERSION = "00";
@ -54,7 +54,7 @@ export function getTraceParentHeader(spanContext: SpanContext): string | undefin
return;
}
const flags = spanContext.traceFlags || TraceFlags.UNSAMPLED;
const flags = spanContext.traceFlags || TraceFlags.NONE;
const hexFlags = flags.toString(16);
const traceFlags = hexFlags.length === 1 ? `0${hexFlags}` : hexFlags;

Просмотреть файл

@ -0,0 +1,36 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import * as assert from "assert";
import { SpanContext, TraceFlags, SpanOptions } from "../src";
import { SpanContext as OTSpanContext, SpanOptions as OTSpanOptions } from "@opentelemetry/api";
describe("interface compatibility", () => {
it("SpanContext is assignable", () => {
const context: SpanContext = {
spanId: "",
traceId: "",
traceFlags: TraceFlags.NONE
};
const OTContext: OTSpanContext = context;
const context2: SpanContext = OTContext;
assert.ok(context2);
});
it("SpanOptions can be passed to OT", () => {
const context: SpanContext = {
spanId: "",
traceId: "",
traceFlags: TraceFlags.NONE
};
const spanOptions: SpanOptions = {
parent: context
};
const OTSpanOptions: OTSpanOptions = spanOptions;
assert.ok(OTSpanOptions);
});
});

Просмотреть файл

@ -3,7 +3,7 @@
import * as assert from "assert";
import { extractSpanContextFromTraceParentHeader, getTraceParentHeader } from "../src";
import { TraceFlags, SpanContext } from "@opentelemetry/types";
import { TraceFlags, SpanContext } from "@opentelemetry/api";
describe("traceParentHeader", () => {
describe("#extractSpanContextFromTraceParentHeader", () => {
@ -22,7 +22,7 @@ describe("traceParentHeader", () => {
assert.equal(spanContext.spanId, spanId, "Extracted spanId does not match expectation.");
assert.equal(
spanContext.traceFlags,
TraceFlags.UNSAMPLED,
TraceFlags.NONE,
"Extracted traceFlags do not match expectations."
);
});
@ -77,7 +77,8 @@ describe("traceParentHeader", () => {
it("should set the traceFlag to UNSAMPLED if not provided in SpanContext", () => {
const spanContext: SpanContext = {
spanId: "2222222222222222",
traceId: "11111111111111111111111111111111"
traceId: "11111111111111111111111111111111",
traceFlags: TraceFlags.NONE
};
const traceParentHeader = getTraceParentHeader(spanContext);

Просмотреть файл

@ -75,7 +75,7 @@
"@azure/core-asynciterator-polyfill": "^1.0.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"async-lock": "^1.1.3",
"buffer": "^5.2.1",
"debug": "^4.1.1",

Просмотреть файл

@ -8,8 +8,8 @@ import { AbortSignalLike } from '@azure/abort-controller';
import { MessagingError } from '@azure/core-amqp';
import { OperationTracingOptions } from '@azure/core-tracing';
import { RetryOptions } from '@azure/core-amqp';
import { Span } from '@opentelemetry/types';
import { SpanContext } from '@opentelemetry/types';
import { Span } from '@opentelemetry/api';
import { SpanContext } from '@opentelemetry/api';
import { TokenCredential } from '@azure/core-amqp';
import { WebSocketImpl } from 'rhea-promise';
import { WebSocketOptions } from '@azure/core-amqp';

Просмотреть файл

@ -132,7 +132,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
events: ["EventEmitter"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT License.
import { getTraceParentHeader, extractSpanContextFromTraceParentHeader } from "@azure/core-tracing";
import { Span, SpanContext } from "@opentelemetry/types";
import { Span, SpanContext } from "@opentelemetry/api";
import { EventData } from "../eventData";
/**

Просмотреть файл

@ -2,13 +2,13 @@
// Licensed under the MIT License.
import { getTracer } from "@azure/core-tracing";
import { Span, SpanContext, SpanKind } from "@opentelemetry/types";
import { Span, SpanContext, SpanKind } from "@opentelemetry/api";
/**
* @internal
* @ignore
*/
export function createMessageSpan(parentSpan?: Span | SpanContext): Span {
export function createMessageSpan(parentSpan?: Span | SpanContext | null): Span {
const tracer = getTracer();
const span = tracer.startSpan("Azure.EventHubs.message", {
kind: SpanKind.PRODUCER,

Просмотреть файл

@ -6,7 +6,7 @@ import { ConnectionContext } from "./connectionContext";
import { AmqpMessage } from "@azure/core-amqp";
import { message } from "rhea-promise";
import { throwTypeErrorIfParameterMissing } from "./util/error";
import { Span, SpanContext } from "@opentelemetry/types";
import { Span, SpanContext } from "@opentelemetry/api";
import { instrumentEventData, TRACEPARENT_PROPERTY } from "./diagnostics/instrumentEventData";
import { createMessageSpan } from "./diagnostics/messageSpan";
@ -37,11 +37,11 @@ export interface TryAddOptions {
/**
* An interface representing a batch of events which can be used to send events to Event Hub.
*
*
* To create the batch, use the `createBatch()` method on the `EventHubProducerClient`.
* To send the batch, use the `sendBatch()` method on the same client.
* To fill the batch, use the `tryAdd()` method on the batch itself.
*
*
*/
export interface EventDataBatch {
/**
@ -98,7 +98,7 @@ export interface EventDataBatch {
* The AMQP message containing encoded events that were added to the batch.
* Used internally by the `sendBatch()` method on the `EventHubProducerClient`.
* This is not meant for the user to use directly.
*
*
* @readonly
* @internal
* @ignore
@ -116,7 +116,7 @@ export interface EventDataBatch {
/**
* An internal class representing a batch of events which can be used to send events to Event Hub.
*
*
* @class
* @internal
* @ignore

Просмотреть файл

@ -21,7 +21,7 @@ import { EventHubProducer } from "../sender";
import { EventHubConsumer } from "../receiver";
import { throwTypeErrorIfParameterMissing, throwErrorIfConnectionClosed } from "../util/error";
import { getTracer } from "@azure/core-tracing";
import { SpanContext, Span, SpanKind, CanonicalCode } from "@opentelemetry/types";
import { SpanContext, Span, SpanKind, CanonicalCode } from "@opentelemetry/api";
import { getParentSpan } from "../util/operationOptions";
import { OperationNames, EventHubProducerOptions } from "../models/private";
import {
@ -214,7 +214,7 @@ export class EventHubClient {
private _createClientSpan(
operationName: OperationNames,
parentSpan?: Span | SpanContext,
parentSpan?: Span | SpanContext | null,
internal: boolean = false
): Span {
const tracer = getTracer();
@ -397,7 +397,7 @@ export class EventHubClient {
...options,
tracingOptions: {
spanOptions: {
parent: clientSpan
parent: clientSpan.context()
}
}
});

Просмотреть файл

@ -12,7 +12,7 @@ import { AbortController } from "@azure/abort-controller";
import { MessagingError } from "@azure/core-amqp";
import { getParentSpan, OperationOptions } from "./util/operationOptions";
import { getTracer } from "@azure/core-tracing";
import { Span, SpanKind, Link, CanonicalCode } from "@opentelemetry/types";
import { Span, SpanKind, Link, CanonicalCode } from "@opentelemetry/api";
import { extractSpanContextFromEventData } from "./diagnostics/instrumentEventData";
import { ReceivedEventData } from "./eventData";
@ -181,7 +181,7 @@ export function createProcessingSpan(
}
links.push({
spanContext
context: spanContext
});
}

Просмотреть файл

@ -10,7 +10,7 @@ import { logger, logErrorStackTrace } from "./log";
import { throwErrorIfConnectionClosed, throwTypeErrorIfParameterMissing } from "./util/error";
import { EventDataBatch, isEventDataBatch, EventDataBatchImpl } from "./eventDataBatch";
import { getTracer } from "@azure/core-tracing";
import { SpanContext, Span, SpanKind, CanonicalCode, Link } from "@opentelemetry/types";
import { SpanContext, Span, SpanKind, CanonicalCode, Link } from "@opentelemetry/api";
import { instrumentEventData, TRACEPARENT_PROPERTY } from "./diagnostics/instrumentEventData";
import { createMessageSpan } from "./diagnostics/messageSpan";
import { getParentSpan } from "./util/operationOptions";
@ -245,12 +245,12 @@ export class EventHubProducer {
}
private _createSendSpan(
parentSpan?: Span | SpanContext,
parentSpan?: Span | SpanContext | null,
spanContextsToLink: SpanContext[] = []
): Span {
const links: Link[] = spanContextsToLink.map((spanContext) => {
const links: Link[] = spanContextsToLink.map((context) => {
return {
spanContext
context
};
});
const tracer = getTracer();

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT License.
import { AbortSignalLike } from "@azure/abort-controller";
import { Span, SpanContext } from "@opentelemetry/types";
import { Span, SpanContext } from "@opentelemetry/api";
import { OperationTracingOptions } from "@azure/core-tracing";
/**
@ -27,11 +27,6 @@ export interface OperationOptions {
*/
export function getParentSpan(
options: Pick<OperationOptions, "tracingOptions">
): Span | SpanContext | undefined {
return (
options &&
options.tracingOptions &&
options.tracingOptions.spanOptions &&
options.tracingOptions.spanOptions.parent
);
): Span | SpanContext | null | undefined {
return options.tracingOptions?.spanOptions?.parent;
}

Просмотреть файл

@ -84,7 +84,7 @@ describe("RuntimeInformation", function(): void {
const ids = await client.getPartitionIds({
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});
@ -158,7 +158,7 @@ describe("RuntimeInformation", function(): void {
const hubRuntimeInfo = await client.getProperties({
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});
@ -270,7 +270,7 @@ describe("RuntimeInformation", function(): void {
const partitionRuntimeInfo = await client.getPartitionProperties("0", {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -22,7 +22,7 @@ import {
TRACEPARENT_PROPERTY,
extractSpanContextFromEventData
} from "../src/diagnostics/instrumentEventData";
import { TraceFlags } from "@opentelemetry/types";
import { TraceFlags } from "@opentelemetry/api";
import { EventHubConsumer } from "../src/receiver";
import { SubscriptionHandlerForTests } from "./utils/subscriptionHandlerForTests";
const env = getEnvVars();
@ -355,7 +355,7 @@ describe("Misc tests", function(): void {
should.equal(spanContext!.spanId, spanId, "Extracted spanId does not match expectation.");
should.equal(
spanContext!.traceFlags,
TraceFlags.UNSAMPLED,
TraceFlags.NONE,
"Extracted traceFlags do not match expectations."
);
});

Просмотреть файл

@ -2,8 +2,8 @@
// Licensed under the MIT License.
import { createProcessingSpan, trace } from "../src/partitionPump";
import { NoOpSpan, TestTracer, setTracer, TestSpan } from "@azure/core-tracing";
import { CanonicalCode, SpanOptions, SpanKind } from "@opentelemetry/types";
import { TestTracer, setTracer, TestSpan, NoOpSpan } from "@azure/core-tracing";
import { CanonicalCode, SpanOptions, SpanKind } from "@opentelemetry/api";
import chai from "chai";
import { ReceivedEventData } from "../src/eventData";
import { instrumentEventData } from "../src/diagnostics/instrumentEventData";
@ -33,14 +33,14 @@ describe("PartitionPump", () => {
}
it("basic span properties are set", async () => {
const fakeParentSpan = new NoOpSpan();
const fakeParentSpanContext = new NoOpSpan().context();
const tracer = new TestTracer2();
setTracer(tracer);
await createProcessingSpan([], eventHubProperties, {
tracingOptions: {
spanOptions: {
parent: fakeParentSpan
parent: fakeParentSpanContext
}
}
});
@ -49,17 +49,15 @@ describe("PartitionPump", () => {
should.exist(tracer.spanOptions);
tracer.spanOptions!.kind!.should.equal(SpanKind.CONSUMER);
tracer.spanOptions!.parent!.should.equal(fakeParentSpan);
tracer.spanOptions!.parent!.should.equal(fakeParentSpanContext);
// TODO: re-enable the following verification after moving to @azure/core-tracing 1.0.0-preview.8
// attributes is added after preview.7.
// const attributes = tracer.getRootSpans()[0].attributes;
const attributes = tracer.getRootSpans()[0].attributes;
// attributes!.should.deep.equal({
// component: "eventhubs",
// "message_bus.destination": "theeventhubname",
// "peer.address": "theendpoint"
// });
attributes!.should.deep.equal({
"az.namespace": "Microsoft.EventHub",
"message_bus.destination": "theeventhubname",
"peer.address": "theendpoint"
});
});
it("received events are linked to this span using Diagnostic-Id", async () => {
@ -90,8 +88,8 @@ describe("PartitionPump", () => {
tracer.spanOptions!.links!.length.should.equal(3 - 1);
// the test tracer just hands out a string integer that just gets
// incremented
tracer.spanOptions!.links![0]!.spanContext.traceId.should.equal(firstEvent.context().traceId);
tracer.spanOptions!.links![1]!.spanContext.traceId.should.equal(thirdEvent.context().traceId);
tracer.spanOptions!.links![0]!.context.traceId.should.equal(firstEvent.context().traceId);
tracer.spanOptions!.links![1]!.context.traceId.should.equal(thirdEvent.context().traceId);
});
it("trace - normal", async () => {

Просмотреть файл

@ -125,7 +125,7 @@ describe("EventHub Sender", function(): void {
{
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
}
@ -424,7 +424,7 @@ describe("EventHub Sender", function(): void {
await producerClient.sendBatch(eventDataBatch, {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});
@ -712,7 +712,7 @@ describe("EventHub Sender", function(): void {
await producer.send(events, {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});
@ -778,7 +778,7 @@ describe("EventHub Sender", function(): void {
await producer.send(events, {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -61,7 +61,7 @@
"dependencies": {
"@azure/event-hubs": "^5.0.0",
"@azure/logger": "^1.0.0",
"@azure/storage-blob": "^12.0.0",
"@azure/storage-blob": "^12.2.0",
"debug": "^4.1.1",
"events": "^3.0.0",
"tslib": "^1.10.0"

Просмотреть файл

@ -77,19 +77,19 @@
"autoPublish": false,
"prettier": "@azure/eslint-plugin-azure-sdk/prettier.json",
"dependencies": {
"@azure/core-auth": "^1.1.0",
"@azure/core-auth": "^1.1.2",
"@azure/core-lro": "^1.0.0",
"@azure/core-paging": "^1.1.0",
"@azure/core-http": "^1.0.0",
"@azure/core-tracing": "1.0.0-preview.7",
"@azure/core-http": "^1.1.1",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {
"@azure/eslint-plugin-azure-sdk": "^3.0.0",
"@azure/identity": "1.1.0-preview.2",
"@azure/storage-blob": "^12.0.0",
"@azure/storage-blob": "^12.2.0",
"@azure/test-utils-recorder": "^1.0.0",
"@microsoft/api-extractor": "7.7.11",
"@rollup/plugin-commonjs": "^11.0.1",

Просмотреть файл

@ -87,7 +87,7 @@ export function browserConfig(test = false) {
namedExports: {
chai: ["assert"],
events: ["EventEmitter"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),
viz({ filename: "dist-browser/browser-stats.html", sourcemap: false })

Просмотреть файл

@ -18,7 +18,7 @@ import {
toRequestBody,
getContentType
} from "./common";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { FormRecognizerClient as GeneratedClient } from "./generated/formRecognizerClient";
import {

Просмотреть файл

@ -15,7 +15,7 @@ import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging";
import { SDK_VERSION } from "./constants";
import { logger } from "./logger";
import { createSpan } from "./tracing";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { FormRecognizerClient as GeneratedClient } from "./generated/formRecognizerClient";
import {
FormRecognizerClientGetCustomModelsResponse as ListModelsResponseModel,

Просмотреть файл

@ -1,12 +1,10 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
import { getTracer } from "@azure/core-tracing";
import { Span, SpanOptions, SpanKind } from "@opentelemetry/types";
import { getTracer, OperationTracingOptions } from "@azure/core-tracing";
import { Span, SpanOptions, SpanKind } from "@opentelemetry/api";
import { OperationOptions } from "@azure/core-http";
type OperationTracingOptions = OperationOptions["tracingOptions"];
/**
* Creates a span using the global tracer.
* @ignore
@ -35,7 +33,7 @@ export function createSpan<T extends OperationOptions>(
if (span.isRecording()) {
newSpanOptions = {
...tracingOptions.spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.CognitiveServices"

Просмотреть файл

@ -5,7 +5,7 @@ import { assert } from "chai";
import * as sinon from "sinon";
import { createSpan } from "../src/tracing";
import { setTracer, TestTracer, TestSpan } from "@azure/core-tracing";
import { SpanKind } from "@opentelemetry/types";
import { SpanKind, TraceFlags } from "@opentelemetry/api";
import { OperationOptions } from "@azure/core-http";
describe("tracing.createSpan", () => {
@ -14,7 +14,7 @@ describe("tracing.createSpan", () => {
const testSpan = new TestSpan(
tracer,
"testing",
{ traceId: "", spanId: "" },
{ traceId: "", spanId: "", traceFlags: TraceFlags.NONE },
SpanKind.INTERNAL
);
const setAttributeSpy = sinon.spy(testSpan, "setAttribute");
@ -40,7 +40,7 @@ describe("tracing.createSpan", () => {
const expected: OperationOptions = {
tracingOptions: {
spanOptions: {
parent: span,
parent: span.context(),
attributes: {
"az.namespace": "Microsoft.CognitiveServices"
}
@ -65,7 +65,7 @@ describe("tracing.createSpan", () => {
const expected: OperationOptions = {
tracingOptions: {
spanOptions: {
parent: span,
parent: span.context(),
attributes: {
"az.namespace": "Microsoft.CognitiveServices",
foo: "bar"

Просмотреть файл

@ -76,10 +76,10 @@
"homepage": "https://github.com/azure/azure-sdk-for-js/tree/master/sdk/identity/identity",
"sideEffects": false,
"dependencies": {
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"events": "^3.0.0",
"jws": "^3.2.2",
"keytar": "^5.4.0",

Просмотреть файл

@ -84,7 +84,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
events: ["EventEmitter"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),
viz({ filename: "dist-browser/browser-stats.html", sourcemap: false })

Просмотреть файл

@ -12,7 +12,7 @@ import {
createPipelineFromOptions,
isNode
} from "@azure/core-http";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { AuthenticationError, AuthenticationErrorName } from "./errors";
import { createSpan } from "../util/tracing";
import { logger } from "../util/logging";

Просмотреть файл

@ -6,7 +6,7 @@ import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { TokenCredential, GetTokenOptions, AccessToken } from "@azure/core-http";
import { IdentityClient, TokenResponse, TokenCredentialOptions } from "../client/identityClient";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
/**
* Enables authentication to Azure Active Directory using an authorization code

Просмотреть файл

@ -4,7 +4,7 @@
import { TokenCredential, GetTokenOptions, AccessToken } from "@azure/core-http";
import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { logger } from "../util/logging";
import * as child_process from "child_process";

Просмотреть файл

@ -4,7 +4,7 @@
import { AccessToken, TokenCredential, GetTokenOptions } from "@azure/core-http";
import { AggregateAuthenticationError } from "../client/errors";
import { createSpan } from "../util/tracing";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
/**
* Enables multiple `TokenCredential` implementations to be tried in order

Просмотреть файл

@ -10,7 +10,7 @@ import { TokenCredential, GetTokenOptions, AccessToken } from "@azure/core-http"
import { TokenCredentialOptions, IdentityClient } from "../client/identityClient";
import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
const SelfSignedJwtLifetimeMins = 10;

Просмотреть файл

@ -6,7 +6,7 @@ import { TokenCredential, GetTokenOptions, AccessToken } from "@azure/core-http"
import { TokenCredentialOptions, IdentityClient } from "../client/identityClient";
import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
/**
* Enables authentication to Azure Active Directory using a client secret

Просмотреть файл

@ -7,7 +7,7 @@ import { IdentityClient, TokenResponse, TokenCredentialOptions } from "../client
import { AuthenticationError, AuthenticationErrorName } from "../client/errors";
import { createSpan } from "../util/tracing";
import { delay } from "../util/delay";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { logger } from "../util/logging";
/**

Просмотреть файл

@ -6,7 +6,7 @@ import { TokenCredentialOptions } from "../client/identityClient";
import { ClientSecretCredential } from "./clientSecretCredential";
import { createSpan } from "../util/tracing";
import { AuthenticationError, AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { logger } from "../util/logging";
import { ClientCertificateCredential } from "./clientCertificateCredential";
import { UsernamePasswordCredential } from "./usernamePasswordCredential";

Просмотреть файл

@ -9,7 +9,7 @@ import {
InteractiveBrowserCredentialOptions
} from "./interactiveBrowserCredentialOptions";
import { createSpan } from "../util/tracing";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { DefaultTenantId, DeveloperSignOnClientId } from "../constants";
import { logger } from "../util/logging";

Просмотреть файл

@ -12,7 +12,7 @@ import {
import { IdentityClient, TokenCredentialOptions } from "../client/identityClient";
import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { logger } from "../util/logging";
const DefaultScopeSuffix = "/.default";

Просмотреть файл

@ -6,7 +6,7 @@ import { TokenCredential, GetTokenOptions, AccessToken } from "@azure/core-http"
import { TokenCredentialOptions, IdentityClient } from "../client/identityClient";
import { createSpan } from "../util/tracing";
import { AuthenticationErrorName } from "../client/errors";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
/**
* Enables authentication to Azure Active Directory with a user's

Просмотреть файл

@ -3,7 +3,7 @@
import { GetTokenOptions } from "@azure/core-http";
import { getTracer, OperationTracingOptions } from "@azure/core-tracing";
import { Span, SpanKind, SpanOptions } from "@opentelemetry/types";
import { Span, SpanKind, SpanOptions as OTSpanOptions } from "@opentelemetry/api";
/**
* Creates a span using the global tracer.
@ -21,7 +21,7 @@ export function createSpan(
...options.tracingOptions
};
const spanOptions: SpanOptions = {
const spanOptions: OTSpanOptions = {
...tracingOptions.spanOptions,
kind: SpanKind.INTERNAL
};
@ -37,7 +37,7 @@ export function createSpan(
...tracingOptions,
spanOptions: {
...tracingOptions.spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.AAD"

Просмотреть файл

@ -100,7 +100,7 @@ describe("AuthorizationCodeCredential", function() {
await credential.getToken("scope", {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -97,7 +97,7 @@ describe("ClientCertificateCredential", function() {
await credential.getToken("scope", {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -337,7 +337,7 @@ describe("DeviceCodeCredential", function() {
await credential.getToken("scope", {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -94,7 +94,7 @@ describe("EnvironmentCredential", function() {
await credential.getToken("scope", {
tracingOptions: {
spanOptions: {
parent: rootSpan
parent: rootSpan.context()
}
}
});

Просмотреть файл

@ -84,12 +84,12 @@
},
"dependencies": {
"@azure/abort-controller": "^1.0.0",
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-lro": "^1.0.0",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -126,7 +126,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
assert: ["ok", "equal", "strictEqual"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
})
]

Просмотреть файл

@ -18,7 +18,7 @@ import {
} from "@azure/core-http";
import { getTracer } from "@azure/core-tracing";
import { Span } from "@opentelemetry/types";
import { Span } from "@opentelemetry/api";
import { logger } from "./log";
import { PollerLike } from "@azure/core-lro";
@ -2235,7 +2235,7 @@ export class CertificateClient {
...options,
spanOptions: {
...spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.KeyVault"

Просмотреть файл

@ -82,12 +82,12 @@
]
},
"dependencies": {
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-lro": "^1.0.0",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -124,7 +124,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
assert: ["ok", "equal", "strictEqual"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
})
]

Просмотреть файл

@ -21,7 +21,7 @@ import {
} from "@azure/core-http";
import { getTracer } from "@azure/core-tracing";
import { Span } from "@opentelemetry/types";
import { Span } from "@opentelemetry/api";
import { logger } from "./log";
import { parseKeyvaultIdentifier } from "./core/utils";
import { SDK_VERSION } from "./core/utils/constants";
@ -777,7 +777,7 @@ export class CryptographyClient {
...options,
spanOptions: {
...spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.KeyVault"

Просмотреть файл

@ -13,7 +13,7 @@ import {
} from "@azure/core-http";
import { getTracer } from "@azure/core-tracing";
import { Span } from "@opentelemetry/types";
import { Span } from "@opentelemetry/api";
import { logger } from "./log";
import "@azure/core-paging";
@ -1277,7 +1277,7 @@ export class KeyClient {
...options,
spanOptions: {
...spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.KeyVault"

Просмотреть файл

@ -83,12 +83,12 @@
},
"dependencies": {
"@azure/abort-controller": "^1.0.0",
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-lro": "^1.0.0",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -124,7 +124,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
assert: ["ok", "equal", "strictEqual"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
})
]

Просмотреть файл

@ -13,7 +13,7 @@ import {
} from "@azure/core-http";
import { getTracer } from "@azure/core-tracing";
import { Span } from "@opentelemetry/types";
import { Span } from "@opentelemetry/api";
import { logger } from "./log";
import "@azure/core-paging";
@ -1018,7 +1018,7 @@ export class SecretClient {
...options,
spanOptions: {
...spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.KeyVault"

Просмотреть файл

@ -77,11 +77,11 @@
"sideEffects": false,
"dependencies": {
"@azure/core-auth": "^1.1.2",
"@azure/core-http": "^1.0.0",
"@azure/core-http": "^1.1.1",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"tslib": "^1.10.0"
},
"devDependencies": {

Просмотреть файл

@ -95,7 +95,7 @@ export function browserConfig(test = false) {
cjs({
namedExports: {
chai: ["assert"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),
viz({ filename: "dist-browser/browser-stats.html", sourcemap: false })

Просмотреть файл

@ -24,7 +24,7 @@ import {
IndexDocumentsResult
} from "./generated/data/models";
import { createSpan } from "./tracing";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { deserialize, serialize } from "./serialization";
import {
CountDocumentsOptions,

Просмотреть файл

@ -9,7 +9,7 @@ import {
PipelineOptions,
ServiceClientCredentials
} from "@azure/core-http";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { SDK_VERSION } from "./constants";
import {
AnalyzeResult,

Просмотреть файл

@ -2,7 +2,7 @@
// Licensed under the MIT license.
import { getTracer } from "@azure/core-tracing";
import { Span, SpanOptions, SpanKind } from "@opentelemetry/types";
import { Span, SpanOptions, SpanKind } from "@opentelemetry/api";
import { OperationOptions } from "@azure/core-http";
type OperationTracingOptions = OperationOptions["tracingOptions"];
@ -32,7 +32,7 @@ export function createSpan<T extends OperationOptions>(
if (span.isRecording()) {
newSpanOptions = {
...tracingOptions.spanOptions,
parent: span,
parent: span.context(),
attributes: {
...spanOptions.attributes,
"az.namespace": "Microsoft.Search"

Просмотреть файл

@ -5,7 +5,7 @@ import { assert } from "chai";
import * as sinon from "sinon";
import { createSpan } from "../src/tracing";
import { setTracer, TestTracer, TestSpan } from "@azure/core-tracing";
import { SpanKind } from "@opentelemetry/types";
import { SpanKind, TraceFlags } from "@opentelemetry/api";
import { OperationOptions } from "@azure/core-http";
describe("tracing.createSpan", () => {
@ -14,7 +14,7 @@ describe("tracing.createSpan", () => {
const testSpan = new TestSpan(
tracer,
"testing",
{ traceId: "", spanId: "" },
{ traceId: "", spanId: "", traceFlags: TraceFlags.NONE },
SpanKind.INTERNAL
);
const setAttributeSpy = sinon.spy(testSpan, "setAttribute");
@ -38,7 +38,7 @@ describe("tracing.createSpan", () => {
const expected: OperationOptions = {
tracingOptions: {
spanOptions: {
parent: span,
parent: span.context(),
attributes: {
"az.namespace": "Microsoft.Search"
}
@ -63,7 +63,7 @@ describe("tracing.createSpan", () => {
const expected: OperationOptions = {
tracingOptions: {
spanOptions: {
parent: span,
parent: span.context(),
attributes: {
"az.namespace": "Microsoft.Search",
foo: "bar"

Просмотреть файл

@ -79,8 +79,9 @@
"@azure/core-amqp": "^1.1.1",
"@azure/core-asynciterator-polyfill": "^1.0.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/core-http": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@azure/core-http": "^1.1.1",
"@azure/core-tracing": "1.0.0-preview.8",
"@opentelemetry/api": "^0.6.1",
"@types/is-buffer": "^2.0.0",
"@types/long": "^4.0.0",
"buffer": "^5.2.1",

Просмотреть файл

@ -148,7 +148,7 @@ export function browserConfig(test = false) {
namedExports: {
events: ["EventEmitter"],
long: ["ZERO"],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
}),

Просмотреть файл

@ -4,7 +4,7 @@
// TODO: this code is a straight-copy from EventHubs. Need to merge.
import { AbortSignalLike } from "@azure/abort-controller";
import { Span, SpanContext } from "@opentelemetry/types";
import { Span, SpanContext } from "@opentelemetry/api";
import { OperationTracingOptions } from "@azure/core-tracing";
/**
@ -29,11 +29,6 @@ export interface OperationOptions {
*/
export function getParentSpan(
options: Pick<OperationOptions, "tracingOptions">
): Span | SpanContext | undefined {
return (
options &&
options.tracingOptions &&
options.tracingOptions.spanOptions &&
options.tracingOptions.spanOptions.parent
);
): Span | SpanContext | null | undefined {
return options.tracingOptions?.spanOptions?.parent;
}

Просмотреть файл

@ -99,12 +99,12 @@
},
"dependencies": {
"@azure/abort-controller": "^1.0.0",
"@azure/core-http": "^1.1.0",
"@azure/core-http": "^1.1.1",
"@azure/core-lro": "^1.0.0",
"@azure/core-paging": "^1.1.0",
"@azure/core-tracing": "1.0.0-preview.8",
"@azure/logger": "^1.0.0",
"@opentelemetry/types": "^0.2.0",
"@opentelemetry/api": "^0.6.1",
"events": "^3.0.0",
"tslib": "^1.10.0"
},

Просмотреть файл

@ -146,7 +146,7 @@ export function browserConfig(test = false) {
"notDeepEqual",
"notDeepStrictEqual"
],
"@opentelemetry/types": ["CanonicalCode", "SpanKind", "TraceFlags"]
"@opentelemetry/api": ["CanonicalCode", "SpanKind", "TraceFlags"]
}
})
],

Просмотреть файл

@ -13,7 +13,7 @@ import {
bearerTokenAuthenticationPolicy,
isNode
} from "@azure/core-http";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { AnonymousCredential } from "./credentials/AnonymousCredential";
import { BlobClient, BlobDeleteOptions, BlobSetTierOptions } from "./Clients";
import { AccessTier } from "./generatedModels";

Просмотреть файл

@ -12,7 +12,7 @@ import { BatchResponseParser } from "./BatchResponseParser";
import { utf8ByteLength } from "./BatchUtils";
import { BlobBatch } from "./BlobBatch";
import { AbortSignalLike } from "@azure/abort-controller";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { createSpan } from "./utils/tracing";
import { HttpResponse, TokenCredential } from "@azure/core-http";
import { Service } from "./generated/src/operations";

Просмотреть файл

@ -7,7 +7,7 @@ import {
HttpResponse,
getDefaultProxySettings
} from "@azure/core-http";
import { CanonicalCode } from "@opentelemetry/types";
import { CanonicalCode } from "@opentelemetry/api";
import { AbortSignalLike } from "@azure/abort-controller";
import {
ServiceGetUserDelegationKeyHeaders,

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше