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
Add support for MongoDB 3.4 #3185
Conversation
New version of mongoengine added two new attributes to some class "to_mongo" methods. See MongoEngine/mongoengine@2c4536e#diff-7e77fbc1ea05452e8f514b23a52e211a
@enykeev I will probably need to update Circle CI scripts to they support installing and testing with multiple MongoDB versions. I spent time on that in the past for Travis CI and it worked (we had tests running with MongoDB 2.6 and 3.2), but we introduced a "regression" when moving to Circle CI with regards to that aka we now only test with one version :/ I think I already expressed my "concerns" about that in the past, but don't remember why we excluded support for multiple versions. |
Codecov Report@@ Coverage Diff @@
## master #3185 +/- ##
==========================================
+ Coverage 77.81% 77.86% +0.05%
==========================================
Files 433 433
Lines 22390 22398 +8
==========================================
+ Hits 17421 17438 +17
+ Misses 4969 4960 -9
Continue to review full report at Codecov.
|
I got the builds with two different MongoDB versions working on Circle CI (see diff for corresponding circle.yml and script changes). Sadly Circle CI user interface is very user-unfriendly and terrible when running multiple things in parallel (it doesn't support build Matrix like Travis CI does which makes it hard to see what is going on). I will see what I can do to to make it more user-friendly and easier to see which MongoDB version is being used, etc. In addition to that, it looks like there are still some MongoDB 3.4 related code issues I need to fix (3.4 perform more script index validation, etc. - https://docs.mongodb.com/manual/release-notes/3.4-compatibility/#stricter-validation-of-index-specifications) |
failure so it's easier to track what is going on.
performs more strict index validation.
of mongo shell binary.
We want to see the whole log.
Travis cache issue.
All the unit and integration tests are passing with MongoDB 3.2 and 3.4 on CircleCI now. I will do some more polish and work on a corresponding documentation PR then I will consider this done and ready for the review. I plan to update the installer scripts to install 3.4 by default in the near future when we have more testing with 3.4 under the belt, but we should still update the blog and release announcement and let people know that since StackStorm v2.2.0 we now also support MongoDB 3.4. |
CHANGELOG.rst
Outdated
@@ -49,6 +49,8 @@ in development | |||
put the workflow in a PAUSED state in mistral. (improvement) | |||
* Add support for evaluating jinja expressions in mistral workflow definition where yaql | |||
expressions are typically accepted. (improvement) | |||
* Update the dependencies and the code base so we now also support MongoDB 3.4. Officially | |||
supported MongoDB versions are now MongoDB 3.2 and 3.4. (improvement) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would put a note in here that clarifies that the default for the installer is still 3.2
.circle/install-and-run-mongodb.sh
Outdated
|
||
# Note: MongoDB 2.4 and 2.6 don't work with ramdisk since they don't work with | ||
# small files and require at least 3 GB of space | ||
# TODO: Use ramdisk |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this something you wanted to do in this PR or is this for future?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah in the future - but I will actually remove this note all together since on Circle CI ramdisk doesn't seem to make much difference (probably because of virtualzed memory)
.circle/install-and-run-mongodb.sh
Outdated
# Script which installs versions of MongoDB specified using an environment variable | ||
|
||
if [ ! "${MONGODB_VERSION}" ]; then | ||
echo "MONGODB_VERSION environment variable not set" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be nice to provide a list of supported versions in this error message.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed - will update it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, that's a bit hard since it's not a static list - it will work with any version which is available on MongoDB mirrors...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Except for a minor comment on the error message regarding the mongodb version, this patch LGTM.
…rm/st2 into upgrade_pymongo_and_mongoengine
This pull request updates pymongo and mongoengine dependencies to latest versions which also support MongoDB 3.4.
In addition to that it also makes various other changes to the code to make it work with newest versions of those libraries (some backward incompatible changes were introduced).
Closes #3100.
TODO