@mimik/mongooser 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +1 -2
- package/package.json +4 -4
package/index.js
CHANGED
|
@@ -15,7 +15,6 @@ const { isProd, MASK } = require('@mimik/lib-filters');
|
|
|
15
15
|
const type = 'mongo';
|
|
16
16
|
const correlationId = getCorrelationId(`${type}-database-start`);
|
|
17
17
|
|
|
18
|
-
const VALIDATION_CHECK = 100; // in ms
|
|
19
18
|
const DISCONNECTED = 0;
|
|
20
19
|
const CONNECTED = 1;
|
|
21
20
|
const CONNECTING = 2;
|
|
@@ -146,7 +145,7 @@ module.exports = (config) => {
|
|
|
146
145
|
}
|
|
147
146
|
}, mongoSettings.connectTimeout * 1000); // convert in seconds
|
|
148
147
|
|
|
149
|
-
return Promise.delay(
|
|
148
|
+
return Promise.delay(mongoSettings.validationCheck).then(() => {
|
|
150
149
|
const state = mongoose.connection.readyState;
|
|
151
150
|
|
|
152
151
|
if (state === DISCONNECTED || state === DISCONNECTING) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mimik/mongooser",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "Helper for setting up mongodb using mongoose for mimik microservices",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"engines": {
|
|
@@ -34,15 +34,15 @@
|
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@mimik/lib-filters": "^1.4.6",
|
|
36
36
|
"@mimik/request-helper": "^1.7.8",
|
|
37
|
-
"@mimik/sumologic-winston-logger": "^1.6.
|
|
37
|
+
"@mimik/sumologic-winston-logger": "^1.6.15",
|
|
38
38
|
"bluebird": "3.7.2",
|
|
39
39
|
"lodash": "4.17.21",
|
|
40
|
-
"mongoose": "7.
|
|
40
|
+
"mongoose": "7.1.1"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@mimik/eslint-plugin-dependencies": "^2.4.5",
|
|
44
44
|
"@mimik/eslint-plugin-document-env": "^1.0.5",
|
|
45
|
-
"eslint": "8.
|
|
45
|
+
"eslint": "8.40.0",
|
|
46
46
|
"eslint-config-airbnb": "19.0.4",
|
|
47
47
|
"eslint-plugin-import": "2.27.5",
|
|
48
48
|
"eslint-plugin-jsx-a11y": "6.7.1",
|