Skip to content

Commit

Permalink
Merge branch 'main' into feat/unify-with-bind
Browse files Browse the repository at this point in the history
  • Loading branch information
dyladan authored Jun 30, 2021
2 parents 07c0b4c + 0141897 commit 4616497
Show file tree
Hide file tree
Showing 55 changed files with 620 additions and 462 deletions.
4 changes: 2 additions & 2 deletions backwards-compatability/node10/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"@opentelemetry/tracing": "0.22.0"
},
"devDependencies": {
"@types/node": "10.17.59",
"typescript": "4.3.2"
"@types/node": "10.17.60",
"typescript": "4.3.4"
},
"author": "OpenTelemetry Authors",
"license": "Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions backwards-compatability/node12/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"@opentelemetry/tracing": "0.22.0"
},
"devDependencies": {
"@types/node": "12.20.11",
"typescript": "4.3.2"
"@types/node": "12.20.15",
"typescript": "4.3.4"
},
"author": "OpenTelemetry Authors",
"license": "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion backwards-compatability/node8/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
},
"devDependencies": {
"@types/node": "8.10.66",
"typescript": "4.3.2"
"typescript": "4.3.4"
},
"author": "OpenTelemetry Authors",
"license": "Apache-2.0"
Expand Down
2 changes: 2 additions & 0 deletions examples/opentracing-shim/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
"@opentelemetry/exporter-zipkin": "0.22.0",
"@opentelemetry/instrumentation": "0.22.0",
"@opentelemetry/node": "0.22.0",
"@opentelemetry/resources": "0.22.0",
"@opentelemetry/semantic-conventions": "0.22.0",
"@opentelemetry/shim-opentracing": "0.22.0",
"@opentelemetry/tracing": "0.22.0",
"opentracing": "^0.14.4"
Expand Down
2 changes: 1 addition & 1 deletion examples/opentracing-shim/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ async function handleRequest(req, res) {

res.writeHead(200, { 'Content-Type': 'application/json' });
res.write(
JSON.stringify({ status: 'OK', traceId: span.spanContext().toTraceId() }),
JSON.stringify({ status: 'OK', traceId: span.context().toTraceId() }),
);

res.end();
Expand Down
16 changes: 8 additions & 8 deletions examples/opentracing-shim/shim.js
Original file line number Diff line number Diff line change
@@ -1,33 +1,33 @@
'use strict';

const { registerInstrumentations } = require('@opentelemetry/instrumentation');
const { ResourceAttributes } = require('@opentelemetry/semantic-conventions');
const { Resource } = require('@opentelemetry/resources');
const { NodeTracerProvider } = require('@opentelemetry/node');
const { SimpleSpanProcessor } = require('@opentelemetry/tracing');
const { JaegerExporter } = require('@opentelemetry/exporter-jaeger');
const { ZipkinExporter } = require('@opentelemetry/exporter-zipkin');
const { TracerShim } = require('@opentelemetry/shim-opentracing');

function shim(serviceName) {
const provider = new NodeTracerProvider();
const provider = new NodeTracerProvider({
resource: new Resource({ [ResourceAttributes.SERVICE_NAME]: serviceName }),
});

provider.addSpanProcessor(new SimpleSpanProcessor(getExporter(serviceName)));
// Initialize the OpenTelemetry APIs to use the NodeTracerProvider bindings
provider.register();

registerInstrumentations({
});

return new TracerShim(provider.getTracer('opentracing-shim'));
}

function getExporter(serviceName) {
function getExporter() {
const type = process.env.EXPORTER.toLowerCase() || 'jaeger';

if (type.startsWith('z')) {
return new ZipkinExporter({ serviceName });
return new ZipkinExporter();
}

return new JaegerExporter({ serviceName, flushInterval: 100 });
return new JaegerExporter();
}

exports.shim = shim;
2 changes: 1 addition & 1 deletion getting-started/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ To create traces on NodeJS, you need `@opentelemetry/node`, `@opentelemetry/core

```sh
$ npm install \
@opentelemetry/core \
@opentelemetry/api \
@opentelemetry/node \
@opentelemetry/instrumentation-http \
@opentelemetry/instrumentation-express \
Expand Down
2 changes: 1 addition & 1 deletion getting-started/traced-example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"@opentelemetry/exporter-zipkin": "0.22.0",
"@opentelemetry/node": "0.22.0",
"@opentelemetry/instrumentation": "0.22.0",
"@opentelemetry/instrumentation-express": "^0.16.0",
"@opentelemetry/instrumentation-express": "^0.22.0",
"@opentelemetry/instrumentation-http": "0.22.0",
"@opentelemetry/tracing": "0.22.0",
"axios": "^0.21.0",
Expand Down
4 changes: 2 additions & 2 deletions getting-started/ts-example/example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"author": "OpenTelemetry Authors",
"license": "Apache-2.0",
"devDependencies": {
"@types/express": "4.17.11",
"@types/node": "14.14.43",
"@types/express": "4.17.12",
"@types/node": "14.17.4",
"ts-node": "8.10.2"
},
"dependencies": {
Expand Down
4 changes: 2 additions & 2 deletions getting-started/ts-example/monitored-example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"author": "OpenTelemetry Authors",
"license": "Apache-2.0",
"devDependencies": {
"@types/express": "4.17.11",
"@types/node": "14.14.43",
"@types/express": "4.17.12",
"@types/node": "14.17.4",
"ts-node": "8.10.2"
},
"dependencies": {
Expand Down
6 changes: 3 additions & 3 deletions getting-started/ts-example/traced-example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@
"author": "OpenTelemetry Authors",
"license": "Apache-2.0",
"devDependencies": {
"@types/express": "4.17.11",
"@types/node": "14.14.43",
"@types/express": "4.17.12",
"@types/node": "14.17.4",
"ts-node": "9.1.1"
},
"dependencies": {
"@opentelemetry/core": "0.22.0",
"@opentelemetry/exporter-zipkin": "0.22.0",
"@opentelemetry/instrumentation": "0.22.0",
"@opentelemetry/node": "0.22.0",
"@opentelemetry/instrumentation-express": "^0.16.0",
"@opentelemetry/instrumentation-express": "^0.22.0",
"@opentelemetry/instrumentation-http": "0.22.0",
"@opentelemetry/tracing": "0.22.0",
"axios": "^0.21.0",
Expand Down
6 changes: 3 additions & 3 deletions integration-tests/propagation-validation-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
"express": "4.17.1"
},
"devDependencies": {
"@opentelemetry/api": "^1.0.0",
"typescript": "4.3.2"
"@opentelemetry/api": "^1.0.1",
"typescript": "4.3.4"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0"
"@opentelemetry/api": "^1.0.1"
}
}
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,24 +46,24 @@
"author": "OpenTelemetry Authors",
"license": "Apache-2.0",
"devDependencies": {
"@commitlint/cli": "12.1.1",
"@commitlint/config-conventional": "12.1.1",
"@typescript-eslint/eslint-plugin": "4.25.0",
"@typescript-eslint/parser": "4.25.0",
"@commitlint/cli": "12.1.4",
"@commitlint/config-conventional": "12.1.4",
"@typescript-eslint/eslint-plugin": "4.28.1",
"@typescript-eslint/parser": "4.28.1",
"beautify-benchmark": "0.2.4",
"benchmark": "2.1.4",
"eslint": "7.27.0",
"eslint": "7.29.0",
"eslint-config-airbnb-base": "14.2.1",
"eslint-plugin-header": "3.1.1",
"eslint-plugin-import": "2.23.3",
"eslint-plugin-import": "2.23.4",
"eslint-plugin-node": "11.1.0",
"gh-pages": "3.1.0",
"gh-pages": "3.2.3",
"husky": "4.3.8",
"lerna": "3.22.1",
"lerna-changelog": "1.0.1",
"markdownlint-cli": "0.27.1",
"typescript": "4.3.2",
"update-ts-references": "2.3.0"
"typescript": "4.3.4",
"update-ts-references": "2.4.0"
},
"husky": {
"hooks": {
Expand Down
10 changes: 5 additions & 5 deletions packages/opentelemetry-api-metrics/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@
"access": "public"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0"
"@opentelemetry/api": "^1.0.1"
},
"devDependencies": {
"@opentelemetry/api": "^1.0.0",
"@opentelemetry/api": "^1.0.1",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/node": "14.17.4",
"@types/webpack-env": "1.16.0",
"codecov": "3.8.2",
"istanbul-instrumenter-loader": "3.0.1",
Expand All @@ -70,9 +70,9 @@
"karma-webpack": "4.0.2",
"mocha": "7.2.0",
"nyc": "15.1.0",
"ts-loader": "8.2.0",
"ts-loader": "8.3.0",
"ts-mocha": "8.0.0",
"typescript": "4.3.2",
"typescript": "4.3.4",
"webpack": "4.46.0"
}
}
10 changes: 5 additions & 5 deletions packages/opentelemetry-context-async-hooks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,19 +40,19 @@
"access": "public"
},
"devDependencies": {
"@opentelemetry/api": "^1.0.0",
"@opentelemetry/api": "^1.0.1",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/node": "14.17.4",
"@types/shimmer": "1.0.1",
"codecov": "^3.8.2",
"codecov": "3.8.2",
"mocha": "7.2.0",
"nyc": "15.1.0",
"rimraf": "3.0.2",
"ts-mocha": "8.0.0",
"ts-node": "9.1.1",
"typescript": "4.3.2"
"typescript": "4.3.4"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0"
"@opentelemetry/api": "^1.0.1"
}
}
14 changes: 7 additions & 7 deletions packages/opentelemetry-context-zone-peer-dep/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@
"access": "public"
},
"devDependencies": {
"@babel/core": "7.14.0",
"@opentelemetry/api": "^1.0.0",
"@babel/core": "7.14.6",
"@opentelemetry/api": "^1.0.1",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/node": "14.17.4",
"@types/sinon": "9.0.11",
"@types/webpack-env": "1.16.0",
"@types/zone.js": "0.5.12",
Expand All @@ -65,16 +65,16 @@
"nyc": "15.1.0",
"rimraf": "3.0.2",
"sinon": "10.0.0",
"ts-loader": "8.2.0",
"ts-loader": "8.3.0",
"ts-mocha": "8.0.0",
"ts-node": "9.1.1",
"typescript": "4.3.2",
"typescript": "4.3.4",
"webpack": "4.46.0",
"webpack-cli": "4.6.0",
"webpack-cli": "4.7.2",
"zone.js": "0.11.4"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0",
"@opentelemetry/api": "^1.0.1",
"zone.js": "^0.10.2 || ^0.11.0"
},
"sideEffects": false
Expand Down
12 changes: 6 additions & 6 deletions packages/opentelemetry-context-zone/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@
"access": "public"
},
"devDependencies": {
"@babel/core": "7.14.0",
"@babel/core": "7.14.6",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/node": "14.17.4",
"@types/sinon": "9.0.11",
"@types/webpack-env": "1.16.0",
"babel-loader": "8.2.2",
Expand All @@ -58,13 +58,13 @@
"nyc": "15.1.0",
"rimraf": "3.0.2",
"sinon": "10.0.0",
"ts-loader": "8.2.0",
"ts-loader": "8.3.0",
"ts-mocha": "8.0.0",
"ts-node": "9.1.1",
"typescript": "4.3.2",
"typescript": "4.3.4",
"webpack": "4.46.0",
"webpack-cli": "4.6.0",
"webpack-merge": "5.7.3"
"webpack-cli": "4.7.2",
"webpack-merge": "5.8.0"
},
"dependencies": {
"@opentelemetry/context-zone-peer-dep": "0.22.0",
Expand Down
12 changes: 6 additions & 6 deletions packages/opentelemetry-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@
"access": "public"
},
"devDependencies": {
"@opentelemetry/api": "^1.0.0",
"@opentelemetry/api": "^1.0.1",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/semver": "7.3.5",
"@types/node": "14.17.4",
"@types/semver": "7.3.6",
"@types/sinon": "9.0.11",
"@types/webpack-env": "1.16.0",
"codecov": "3.8.2",
Expand All @@ -73,14 +73,14 @@
"nyc": "15.1.0",
"rimraf": "3.0.2",
"sinon": "10.0.0",
"ts-loader": "8.2.0",
"ts-loader": "8.3.0",
"ts-mocha": "8.0.0",
"ts-node": "9.1.1",
"typescript": "4.3.2",
"typescript": "4.3.4",
"webpack": "4.46.0"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0"
"@opentelemetry/api": "^1.0.1"
},
"dependencies": {
"@opentelemetry/semantic-conventions": "0.22.0",
Expand Down
12 changes: 6 additions & 6 deletions packages/opentelemetry-exporter-collector-grpc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,25 +45,25 @@
"access": "public"
},
"devDependencies": {
"@babel/core": "7.14.0",
"@opentelemetry/api": "^1.0.0",
"@babel/core": "7.14.6",
"@opentelemetry/api": "^1.0.1",
"@opentelemetry/api-metrics": "0.22.0",
"@types/mocha": "8.2.2",
"@types/node": "14.14.43",
"@types/node": "14.17.4",
"@types/sinon": "9.0.11",
"codecov": "3.8.2",
"cpx": "1.5.0",
"mocha": "7.2.0",
"nyc": "15.1.0",
"rimraf": "3.0.2",
"sinon": "10.0.0",
"ts-loader": "8.2.0",
"ts-loader": "8.3.0",
"ts-mocha": "8.0.0",
"ts-node": "9.1.1",
"typescript": "4.3.2"
"typescript": "4.3.4"
},
"peerDependencies": {
"@opentelemetry/api": "^1.0.0"
"@opentelemetry/api": "^1.0.1"
},
"dependencies": {
"@grpc/grpc-js": "^1.2.12",
Expand Down
Loading

0 comments on commit 4616497

Please sign in to comment.