Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(mongodb4): added mongodb4 instrumentation #794

Closed
Closed
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
af49bac
feat(mongodb4): added mongodb4 instrumentation
Dec 22, 2021
6de0a73
feat(mongodb4): merged mongodb4 instrumentation to mongodb plugin
Dec 30, 2021
28dd80f
feat(mongodb4): fixed ut
Dec 30, 2021
7a2734b
Merge branch 'main' into feat/add-mongodb4-instrumentation
osherv Dec 30, 2021
af247e4
feat(mongodb4): fixed ut connection timeout
Jan 2, 2022
f171e3d
Merge branch 'main' into feat/add-mongodb4-instrumentation
osherv Jan 2, 2022
87efbc6
feat(mongodb): fixed most of Rauno's CR
Jan 6, 2022
af3f981
feat(mongodb): fixed most of Rauno's CR
Jan 6, 2022
7262944
feat(mongodb): fixed Rauno's CR
Jan 6, 2022
8333e54
feat(mongodb): updated nyrc exclude
Jan 6, 2022
177338f
Merge branch 'main' into feat/add-mongodb4-instrumentation
osherv Jan 6, 2022
33a7294
feat(mongodb): updated README
Jan 6, 2022
d4ea2c6
feat(mongodb): fixed Daniel's CR
Jan 6, 2022
009f16f
feat(mongodb4): trying to remove parallel testing in oreder to fix gi…
Jan 9, 2022
b1d7aad
feat(mongodb4): small change to fix CLA auth
osherv Jan 9, 2022
652ae27
feat(mongodb4): small change to fix CLA auth
osherv Jan 9, 2022
a65c4b3
feat(mongodb4): fixed Amir's CR
osherv Jan 10, 2022
6dbc6d5
feat(mongo): default mongo host is now the IP
osherv Jan 24, 2022
ca4d020
feat(mongo): mongodb4 tests are now using always promises
osherv Jan 25, 2022
fe9bb27
feat(mongo): mongodb3 tests are now using always promises
osherv Jan 25, 2022
196d77e
feat(mongo): fixed Amir's CR
osherv Jan 25, 2022
4fa8252
Merge branch 'main' into feat/add-mongodb4-instrumentation
osherv Jan 25, 2022
a0ab0a4
feat(mongo): fixed Amir's CR
osherv Feb 3, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions plugins/node/opentelemetry-instrumentation-mongodb/.tav.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
mongodb:
versions: ">=3.3 <4"
commands: npm run test
jobs:
- versions: ">=3.3 <4"
commands: npm run test-old-versions
- versions: ">=4"
commands: npm run test
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`

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
"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 --parallel -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**/*.test.ts'",
"test": "nyc ts-mocha --parallel -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**/mongodb-v4.test.ts'",
"test-old-versions": "nyc ts-mocha --parallel -p tsconfig.json --require '@opentelemetry/contrib-test-utils' 'test/**mongodb-v3.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 Expand Up @@ -56,19 +57,21 @@
"@opentelemetry/sdk-trace-node": "1.0.1",
"@types/mocha": "7.0.2",
"@types/node": "14.17.9",
"@types/semver": "7.3.8",
"codecov": "3.8.3",
"gts": "3.1.0",
"mocha": "7.2.0",
"mongodb": "3.6.11",
"mongodb": "4.2.2",
Copy link
Member

@blumamir blumamir Jan 9, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are installing mongodb v4 as dev dependency, which means that v3 tests will not pass, only in tav, right?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about documenting it somehow?
Maybe we can write a comment at the top of the v3 tests file with instructions on how to run them locally.
The next person who will try to run v3 test will see all tests failing and be surprised

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added doc :)

"nyc": "15.1.0",
"rimraf": "3.0.2",
"test-all-versions": "5.0.1",
"ts-mocha": "8.0.0",
"typescript": "4.3.5"
"typescript": "4.3.5",
"semver": "7.3.5"
rauno56 marked this conversation as resolved.
Show resolved Hide resolved
},
"dependencies": {
"@opentelemetry/instrumentation": "^0.27.0",
"@opentelemetry/semantic-conventions": "^1.0.0",
"@types/mongodb": "3.6.20"
"@types/mongodb": "4.0.7"
}
}
}
Loading