Skip to content

Commit

Permalink
feat(mongodb4): added mongodb4 instrumentation (open-telemetry#869)
Browse files Browse the repository at this point in the history
* feat(mongodb4): added mongodb4 instrumentation

* feat(mongodb4): updated mongo hostname

* feat(mongodb4): fixed Amir's CR

* feat(mongodb4): fixed Amir's CR
  • Loading branch information
osherv authored Feb 9, 2022
1 parent fbceaf8 commit 47700e1
Show file tree
Hide file tree
Showing 9 changed files with 993 additions and 219 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
RUN_REDIS_TESTS: 1
CASSANDRA_HOST: localhost
MONGODB_DB: opentelemetry-tests
MONGODB_HOST: localhost
MONGODB_HOST: 127.0.0.1
MONGODB_PORT: 27017
MSSQL_PASSWORD: mssql_passw0rd
MYSQL_DATABASE: circle_database
Expand Down
7 changes: 5 additions & 2 deletions plugins/node/opentelemetry-instrumentation-mongodb/.tav.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
mongodb:
versions: ">=3.3 <4"
commands: npm run test
jobs:
- versions: ">=3.3 <4"
commands: npm run test
- versions: ">=4"
commands: npm run test-new-versions

# Fix missing `contrib-test-utils` package
pretest: npm run --prefix ../../../ lerna:link
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ npm install --save @opentelemetry/instrumentation-mongodb

### Supported Versions

- `>=3.3 <4`
- `>=3.3 <5`

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@
"types": "build/src/index.d.ts",
"repository": "open-telemetry/opentelemetry-js-contrib",
"scripts": {
"docker:start": "docker run -e MONGODB_DB=opentelemetry-tests -e MONGODB_PORT=27017 -e MONGODB_HOST=localhost -p 27017:27017 --rm mongo",
"test": "nyc ts-mocha -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**/*.test.ts'",
"docker:start": "docker run -e MONGODB_DB=opentelemetry-tests -e MONGODB_PORT=27017 -e MONGODB_HOST=127.0.0.1 -p 27017:27017 --rm mongo",
"test": "nyc ts-mocha -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**/mongodb-v3.test.ts'",
"test-new-versions": "nyc ts-mocha -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**mongodb-v4.test.ts'",
"test-all-versions": "tav",
"codecov": "nyc report --reporter=json && codecov -f coverage/*.json -p ../../",
"tdd": "npm run test -- --watch-extensions ts --watch",
Expand Down
Loading

0 comments on commit 47700e1

Please sign in to comment.