Merge branch 'georouterConfig' into 'main'
Georouter config See merge request v3/service/configuration!30
This commit is contained in:
commit
c0122e395a
|
@ -48,6 +48,10 @@ MARGIN_DURATION=900
|
||||||
MAX_DETOUR_DISTANCE_RATIO=0.3
|
MAX_DETOUR_DISTANCE_RATIO=0.3
|
||||||
MAX_DETOUR_DURATION_RATIO=0.3
|
MAX_DETOUR_DURATION_RATIO=0.3
|
||||||
|
|
||||||
|
# GEOROUTER
|
||||||
|
GEOROUTER_TYPE=graphhopper
|
||||||
|
GEOROUTER_URL=http://51.210.249.175:8989
|
||||||
|
|
||||||
# PAGINATION
|
# PAGINATION
|
||||||
# number of results per page
|
# number of results per page
|
||||||
PER_PAGE=10
|
PER_PAGE=10
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
{
|
{
|
||||||
"name": "@mobicoop/configuration",
|
"name": "@mobicoop/configuration",
|
||||||
"version": "2.3.0",
|
"version": "2.4.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "@mobicoop/configuration",
|
"name": "@mobicoop/configuration",
|
||||||
"version": "2.3.0",
|
"version": "2.4.0",
|
||||||
"license": "AGPL",
|
"license": "AGPL",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@grpc/grpc-js": "^1.9.8",
|
"@grpc/grpc-js": "^1.9.9",
|
||||||
"@grpc/proto-loader": "^0.7.10",
|
"@grpc/proto-loader": "^0.7.10",
|
||||||
"@mobicoop/configuration-module": "^6.1.0",
|
"@mobicoop/configuration-module": "^7.2.1",
|
||||||
"@mobicoop/ddd-library": "^2.1.1",
|
"@mobicoop/ddd-library": "^2.1.1",
|
||||||
"@mobicoop/health-module": "^2.3.1",
|
"@mobicoop/health-module": "^2.3.1",
|
||||||
"@mobicoop/message-broker-module": "^2.1.1",
|
"@mobicoop/message-broker-module": "^2.1.1",
|
||||||
|
@ -33,11 +33,11 @@
|
||||||
"@nestjs/schematics": "^10.0.3",
|
"@nestjs/schematics": "^10.0.3",
|
||||||
"@nestjs/testing": "^10.2.7",
|
"@nestjs/testing": "^10.2.7",
|
||||||
"@types/express": "^4.17.20",
|
"@types/express": "^4.17.20",
|
||||||
"@types/jest": "29.5.6",
|
"@types/jest": "29.5.7",
|
||||||
"@types/node": "^20.8.9",
|
"@types/node": "^20.8.10",
|
||||||
"@types/supertest": "^2.0.15",
|
"@types/supertest": "^2.0.15",
|
||||||
"@typescript-eslint/eslint-plugin": "^6.9.0",
|
"@typescript-eslint/eslint-plugin": "^6.9.1",
|
||||||
"@typescript-eslint/parser": "^6.9.0",
|
"@typescript-eslint/parser": "^6.9.1",
|
||||||
"dotenv-cli": "^7.3.0",
|
"dotenv-cli": "^7.3.0",
|
||||||
"eslint": "^8.52.0",
|
"eslint": "^8.52.0",
|
||||||
"eslint-config-prettier": "^9.0.0",
|
"eslint-config-prettier": "^9.0.0",
|
||||||
|
@ -1031,9 +1031,9 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"node_modules/@grpc/grpc-js": {
|
"node_modules/@grpc/grpc-js": {
|
||||||
"version": "1.9.8",
|
"version": "1.9.9",
|
||||||
"resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.9.8.tgz",
|
"resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.9.9.tgz",
|
||||||
"integrity": "sha512-FFPzDS333Vw8hvf+1FaEsaCYVPBdNdUCw7zArTiF7+6gOzln967b4GBCBekKGqoKEgna8d3Ayxv8t+IvazXG3g==",
|
"integrity": "sha512-vQ1qwi/Kiyprt+uhb1+rHMpyk4CVRMTGNUGGPRGS7pLNfWkdCHrGEnT6T3/JyC2VZgoOX/X1KwdoU0WYQAeYcQ==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@grpc/proto-loader": "^0.7.8",
|
"@grpc/proto-loader": "^0.7.8",
|
||||||
"@types/node": ">=12.12.47"
|
"@types/node": ">=12.12.47"
|
||||||
|
@ -1668,9 +1668,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@mobicoop/configuration-module": {
|
"node_modules/@mobicoop/configuration-module": {
|
||||||
"version": "6.1.0",
|
"version": "7.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/@mobicoop/configuration-module/-/configuration-module-6.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/@mobicoop/configuration-module/-/configuration-module-7.2.1.tgz",
|
||||||
"integrity": "sha512-ar4hx+oB+RtgAj0SLg0/xgxHA7r/LnUz9BzXUlEX4va0AQwSPdFgTJhku6flMW4U0sJdtGEay3740BnqGfMtCw==",
|
"integrity": "sha512-PGY80+uN33yKSxvqcR2CPlAbhEY67xYfVDqkphIoqGb5qAwioVZH5a8InJw4Zg0Q5bx0ZQG5pcK0jha7kSxqzQ==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@songkeys/nestjs-redis": "^10.0.0",
|
"@songkeys/nestjs-redis": "^10.0.0",
|
||||||
"ioredis": "^5.3.2"
|
"ioredis": "^5.3.2"
|
||||||
|
@ -2585,9 +2585,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@types/jest": {
|
"node_modules/@types/jest": {
|
||||||
"version": "29.5.6",
|
"version": "29.5.7",
|
||||||
"resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.6.tgz",
|
"resolved": "https://registry.npmjs.org/@types/jest/-/jest-29.5.7.tgz",
|
||||||
"integrity": "sha512-/t9NnzkOpXb4Nfvg17ieHE6EeSjDS2SGSpNYfoLbUAeL/EOueU/RSdOWFpfQTXBEM7BguYW1XQ0EbM+6RlIh6w==",
|
"integrity": "sha512-HLyetab6KVPSiF+7pFcUyMeLsx25LDNDemw9mGsJBkai/oouwrjTycocSDYopMEwFhN2Y4s9oPyOCZNofgSt2g==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"expect": "^29.0.0",
|
"expect": "^29.0.0",
|
||||||
|
@ -2607,9 +2607,9 @@
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/@types/node": {
|
"node_modules/@types/node": {
|
||||||
"version": "20.8.9",
|
"version": "20.8.10",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.8.9.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.8.10.tgz",
|
||||||
"integrity": "sha512-UzykFsT3FhHb1h7yD4CA4YhBHq545JC0YnEz41xkipN88eKQtL6rSgocL5tbAP6Ola9Izm/Aw4Ora8He4x0BHg==",
|
"integrity": "sha512-TlgT8JntpcbmKUFzjhsyhGfP2fsiz1Mv56im6enJ905xG1DAYesxJaeSbGqQmAw8OWPdhyJGhGSQGKRNJ45u9w==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"undici-types": "~5.26.4"
|
"undici-types": "~5.26.4"
|
||||||
}
|
}
|
||||||
|
@ -2699,16 +2699,16 @@
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/eslint-plugin": {
|
"node_modules/@typescript-eslint/eslint-plugin": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.9.1.tgz",
|
||||||
"integrity": "sha512-lgX7F0azQwRPB7t7WAyeHWVfW1YJ9NIgd9mvGhfQpRY56X6AVf8mwM8Wol+0z4liE7XX3QOt8MN1rUKCfSjRIA==",
|
"integrity": "sha512-w0tiiRc9I4S5XSXXrMHOWgHgxbrBn1Ro+PmiYhSg2ZVdxrAJtQgzU5o2m1BfP6UOn7Vxcc6152vFjQfmZR4xEg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@eslint-community/regexpp": "^4.5.1",
|
"@eslint-community/regexpp": "^4.5.1",
|
||||||
"@typescript-eslint/scope-manager": "6.9.0",
|
"@typescript-eslint/scope-manager": "6.9.1",
|
||||||
"@typescript-eslint/type-utils": "6.9.0",
|
"@typescript-eslint/type-utils": "6.9.1",
|
||||||
"@typescript-eslint/utils": "6.9.0",
|
"@typescript-eslint/utils": "6.9.1",
|
||||||
"@typescript-eslint/visitor-keys": "6.9.0",
|
"@typescript-eslint/visitor-keys": "6.9.1",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"graphemer": "^1.4.0",
|
"graphemer": "^1.4.0",
|
||||||
"ignore": "^5.2.4",
|
"ignore": "^5.2.4",
|
||||||
|
@ -2734,15 +2734,15 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/parser": {
|
"node_modules/@typescript-eslint/parser": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-6.9.1.tgz",
|
||||||
"integrity": "sha512-GZmjMh4AJ/5gaH4XF2eXA8tMnHWP+Pm1mjQR2QN4Iz+j/zO04b9TOvJYOX2sCNIQHtRStKTxRY1FX7LhpJT4Gw==",
|
"integrity": "sha512-C7AK2wn43GSaCUZ9do6Ksgi2g3mwFkMO3Cis96kzmgudoVaKyt62yNzJOktP0HDLb/iO2O0n2lBOzJgr6Q/cyg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/scope-manager": "6.9.0",
|
"@typescript-eslint/scope-manager": "6.9.1",
|
||||||
"@typescript-eslint/types": "6.9.0",
|
"@typescript-eslint/types": "6.9.1",
|
||||||
"@typescript-eslint/typescript-estree": "6.9.0",
|
"@typescript-eslint/typescript-estree": "6.9.1",
|
||||||
"@typescript-eslint/visitor-keys": "6.9.0",
|
"@typescript-eslint/visitor-keys": "6.9.1",
|
||||||
"debug": "^4.3.4"
|
"debug": "^4.3.4"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
|
@ -2762,13 +2762,13 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/scope-manager": {
|
"node_modules/@typescript-eslint/scope-manager": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-6.9.1.tgz",
|
||||||
"integrity": "sha512-1R8A9Mc39n4pCCz9o79qRO31HGNDvC7UhPhv26TovDsWPBDx+Sg3rOZdCELIA3ZmNoWAuxaMOT7aWtGRSYkQxw==",
|
"integrity": "sha512-38IxvKB6NAne3g/+MyXMs2Cda/Sz+CEpmm+KLGEM8hx/CvnSRuw51i8ukfwB/B/sESdeTGet1NH1Wj7I0YXswg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "6.9.0",
|
"@typescript-eslint/types": "6.9.1",
|
||||||
"@typescript-eslint/visitor-keys": "6.9.0"
|
"@typescript-eslint/visitor-keys": "6.9.1"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^16.0.0 || >=18.0.0"
|
"node": "^16.0.0 || >=18.0.0"
|
||||||
|
@ -2779,13 +2779,13 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/type-utils": {
|
"node_modules/@typescript-eslint/type-utils": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-6.9.1.tgz",
|
||||||
"integrity": "sha512-XXeahmfbpuhVbhSOROIzJ+b13krFmgtc4GlEuu1WBT+RpyGPIA4Y/eGnXzjbDj5gZLzpAXO/sj+IF/x2GtTMjQ==",
|
"integrity": "sha512-eh2oHaUKCK58qIeYp19F5V5TbpM52680sB4zNSz29VBQPTWIlE/hCj5P5B1AChxECe/fmZlspAWFuRniep1Skg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/typescript-estree": "6.9.0",
|
"@typescript-eslint/typescript-estree": "6.9.1",
|
||||||
"@typescript-eslint/utils": "6.9.0",
|
"@typescript-eslint/utils": "6.9.1",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"ts-api-utils": "^1.0.1"
|
"ts-api-utils": "^1.0.1"
|
||||||
},
|
},
|
||||||
|
@ -2806,9 +2806,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/types": {
|
"node_modules/@typescript-eslint/types": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-6.9.1.tgz",
|
||||||
"integrity": "sha512-+KB0lbkpxBkBSiVCuQvduqMJy+I1FyDbdwSpM3IoBS7APl4Bu15lStPjgBIdykdRqQNYqYNMa8Kuidax6phaEw==",
|
"integrity": "sha512-BUGslGOb14zUHOUmDB2FfT6SI1CcZEJYfF3qFwBeUrU6srJfzANonwRYHDpLBuzbq3HaoF2XL2hcr01c8f8OaQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^16.0.0 || >=18.0.0"
|
"node": "^16.0.0 || >=18.0.0"
|
||||||
|
@ -2819,13 +2819,13 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/typescript-estree": {
|
"node_modules/@typescript-eslint/typescript-estree": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-6.9.1.tgz",
|
||||||
"integrity": "sha512-NJM2BnJFZBEAbCfBP00zONKXvMqihZCrmwCaik0UhLr0vAgb6oguXxLX1k00oQyD+vZZ+CJn3kocvv2yxm4awQ==",
|
"integrity": "sha512-U+mUylTHfcqeO7mLWVQ5W/tMLXqVpRv61wm9ZtfE5egz7gtnmqVIw9ryh0mgIlkKk9rZLY3UHygsBSdB9/ftyw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "6.9.0",
|
"@typescript-eslint/types": "6.9.1",
|
||||||
"@typescript-eslint/visitor-keys": "6.9.0",
|
"@typescript-eslint/visitor-keys": "6.9.1",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"globby": "^11.1.0",
|
"globby": "^11.1.0",
|
||||||
"is-glob": "^4.0.3",
|
"is-glob": "^4.0.3",
|
||||||
|
@ -2846,17 +2846,17 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/utils": {
|
"node_modules/@typescript-eslint/utils": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-6.9.1.tgz",
|
||||||
"integrity": "sha512-5Wf+Jsqya7WcCO8me504FBigeQKVLAMPmUzYgDbWchINNh1KJbxCgVya3EQ2MjvJMVeXl3pofRmprqX6mfQkjQ==",
|
"integrity": "sha512-L1T0A5nFdQrMVunpZgzqPL6y2wVreSyHhKGZryS6jrEN7bD9NplVAyMryUhXsQ4TWLnZmxc2ekar/lSGIlprCA==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@eslint-community/eslint-utils": "^4.4.0",
|
"@eslint-community/eslint-utils": "^4.4.0",
|
||||||
"@types/json-schema": "^7.0.12",
|
"@types/json-schema": "^7.0.12",
|
||||||
"@types/semver": "^7.5.0",
|
"@types/semver": "^7.5.0",
|
||||||
"@typescript-eslint/scope-manager": "6.9.0",
|
"@typescript-eslint/scope-manager": "6.9.1",
|
||||||
"@typescript-eslint/types": "6.9.0",
|
"@typescript-eslint/types": "6.9.1",
|
||||||
"@typescript-eslint/typescript-estree": "6.9.0",
|
"@typescript-eslint/typescript-estree": "6.9.1",
|
||||||
"semver": "^7.5.4"
|
"semver": "^7.5.4"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
|
@ -2871,12 +2871,12 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/visitor-keys": {
|
"node_modules/@typescript-eslint/visitor-keys": {
|
||||||
"version": "6.9.0",
|
"version": "6.9.1",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-6.9.0.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-6.9.1.tgz",
|
||||||
"integrity": "sha512-dGtAfqjV6RFOtIP8I0B4ZTBRrlTT8NHHlZZSchQx3qReaoDeXhYM++M4So2AgFK9ZB0emRPA6JI1HkafzA2Ibg==",
|
"integrity": "sha512-MUaPUe/QRLEffARsmNfmpghuQkW436DvESW+h+M52w0coICHRfD6Np9/K6PdACwnrq1HmuLl+cSPZaJmeVPkSw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "6.9.0",
|
"@typescript-eslint/types": "6.9.1",
|
||||||
"eslint-visitor-keys": "^3.4.1"
|
"eslint-visitor-keys": "^3.4.1"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
|
|
14
package.json
14
package.json
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@mobicoop/configuration",
|
"name": "@mobicoop/configuration",
|
||||||
"version": "2.3.0",
|
"version": "2.4.0",
|
||||||
"description": "Mobicoop V3 Configuration Service",
|
"description": "Mobicoop V3 Configuration Service",
|
||||||
"author": "sbriat",
|
"author": "sbriat",
|
||||||
"private": true,
|
"private": true,
|
||||||
|
@ -24,9 +24,9 @@
|
||||||
"test:e2e": "jest --config ./test/jest-e2e.json"
|
"test:e2e": "jest --config ./test/jest-e2e.json"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@grpc/grpc-js": "^1.9.8",
|
"@grpc/grpc-js": "^1.9.9",
|
||||||
"@grpc/proto-loader": "^0.7.10",
|
"@grpc/proto-loader": "^0.7.10",
|
||||||
"@mobicoop/configuration-module": "^6.1.0",
|
"@mobicoop/configuration-module": "^7.2.1",
|
||||||
"@mobicoop/ddd-library": "^2.1.1",
|
"@mobicoop/ddd-library": "^2.1.1",
|
||||||
"@mobicoop/health-module": "^2.3.1",
|
"@mobicoop/health-module": "^2.3.1",
|
||||||
"@mobicoop/message-broker-module": "^2.1.1",
|
"@mobicoop/message-broker-module": "^2.1.1",
|
||||||
|
@ -48,11 +48,11 @@
|
||||||
"@nestjs/schematics": "^10.0.3",
|
"@nestjs/schematics": "^10.0.3",
|
||||||
"@nestjs/testing": "^10.2.7",
|
"@nestjs/testing": "^10.2.7",
|
||||||
"@types/express": "^4.17.20",
|
"@types/express": "^4.17.20",
|
||||||
"@types/jest": "29.5.6",
|
"@types/jest": "29.5.7",
|
||||||
"@types/node": "^20.8.9",
|
"@types/node": "^20.8.10",
|
||||||
"@types/supertest": "^2.0.15",
|
"@types/supertest": "^2.0.15",
|
||||||
"@typescript-eslint/eslint-plugin": "^6.9.0",
|
"@typescript-eslint/eslint-plugin": "^6.9.1",
|
||||||
"@typescript-eslint/parser": "^6.9.0",
|
"@typescript-eslint/parser": "^6.9.1",
|
||||||
"dotenv-cli": "^7.3.0",
|
"dotenv-cli": "^7.3.0",
|
||||||
"eslint": "^8.52.0",
|
"eslint": "^8.52.0",
|
||||||
"eslint-config-prettier": "^9.0.0",
|
"eslint-config-prettier": "^9.0.0",
|
||||||
|
|
|
@ -18,6 +18,7 @@ import serviceConfig from './config/service.config';
|
||||||
import redisConfig from './config/redis.config';
|
import redisConfig from './config/redis.config';
|
||||||
import { Transport } from '@nestjs/microservices';
|
import { Transport } from '@nestjs/microservices';
|
||||||
import matchConfig from './config/match.config';
|
import matchConfig from './config/match.config';
|
||||||
|
import geographyConfig from './config/geography.config';
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
|
@ -26,6 +27,7 @@ import matchConfig from './config/match.config';
|
||||||
load: [
|
load: [
|
||||||
brokerConfig,
|
brokerConfig,
|
||||||
carpoolConfig,
|
carpoolConfig,
|
||||||
|
geographyConfig,
|
||||||
matchConfig,
|
matchConfig,
|
||||||
paginationConfig,
|
paginationConfig,
|
||||||
redisConfig,
|
redisConfig,
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
import { registerAs } from '@nestjs/config';
|
||||||
|
import { Config } from './config';
|
||||||
|
|
||||||
|
export interface GeographyConfig extends Config {
|
||||||
|
georouterType: string;
|
||||||
|
georouterUrl: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default registerAs('geography', () => ({
|
||||||
|
georouterType: process.env.GEOROUTER_TYPE ?? 'graphhopper',
|
||||||
|
georouterUrl: process.env.GEOROUTER_URL ?? 'http://localhost:8989',
|
||||||
|
}));
|
|
@ -9,6 +9,7 @@ import { Injectable } from '@nestjs/common';
|
||||||
import { ConfigService } from '@nestjs/config';
|
import { ConfigService } from '@nestjs/config';
|
||||||
import { CarpoolConfig } from '@src/config/carpool.config';
|
import { CarpoolConfig } from '@src/config/carpool.config';
|
||||||
import { Config } from '@src/config/config';
|
import { Config } from '@src/config/config';
|
||||||
|
import { GeographyConfig } from '@src/config/geography.config';
|
||||||
import { MatchConfig } from '@src/config/match.config';
|
import { MatchConfig } from '@src/config/match.config';
|
||||||
import { PaginationConfig } from '@src/config/pagination.config';
|
import { PaginationConfig } from '@src/config/pagination.config';
|
||||||
|
|
||||||
|
@ -22,6 +23,12 @@ export class ConfigurationsManagerService {
|
||||||
...(this.configService.get<CarpoolConfig>('carpool') as CarpoolConfig),
|
...(this.configService.get<CarpoolConfig>('carpool') as CarpoolConfig),
|
||||||
domain: ConfigurationDomain.CARPOOL,
|
domain: ConfigurationDomain.CARPOOL,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
...(this.configService.get<GeographyConfig>(
|
||||||
|
'geography',
|
||||||
|
) as GeographyConfig),
|
||||||
|
domain: ConfigurationDomain.GEOGRAPHY,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
...(this.configService.get<MatchConfig>('match') as MatchConfig),
|
...(this.configService.get<MatchConfig>('match') as MatchConfig),
|
||||||
domain: ConfigurationDomain.MATCH,
|
domain: ConfigurationDomain.MATCH,
|
||||||
|
|
|
@ -20,6 +20,11 @@ const mockConfigService = {
|
||||||
seatsRequested: 1,
|
seatsRequested: 1,
|
||||||
strictFrequency: false,
|
strictFrequency: false,
|
||||||
};
|
};
|
||||||
|
case 'geography':
|
||||||
|
return {
|
||||||
|
type: 'graphhopper',
|
||||||
|
url: 'http://localhost:8989',
|
||||||
|
};
|
||||||
case 'match':
|
case 'match':
|
||||||
return {
|
return {
|
||||||
algorithm: 'PASSENGER_ORIENTED',
|
algorithm: 'PASSENGER_ORIENTED',
|
||||||
|
@ -64,7 +69,7 @@ describe('Configurations Manager Service', () => {
|
||||||
|
|
||||||
it('should return the list of configuration elements', () => {
|
it('should return the list of configuration elements', () => {
|
||||||
const list: Config[] = configurationsManagerService.list();
|
const list: Config[] = configurationsManagerService.list();
|
||||||
expect(list).toHaveLength(3);
|
expect(list).toHaveLength(4);
|
||||||
});
|
});
|
||||||
|
|
||||||
describe('identifierType', () => {
|
describe('identifierType', () => {
|
||||||
|
|
Loading…
Reference in New Issue