telefonicaid / fiware-cygnus

A connector in charge of persisting context data sources into other third-party databases and storage systems, creating a historical view of the context
https://fiware-cygnus.rtfd.io/
GNU Affero General Public License v3.0
65 stars 104 forks source link

update mongo sink adding ssl options #2386

Closed AlvaroVega closed 2 weeks ago

AlvaroVega commented 2 weeks ago

https://mongodb.github.io/mongo-java-driver/3.6/driver/tutorials/ssl/

overcomes https://github.com/telefonicaid/fiware-cygnus/pull/2385

fgalan commented 1 week ago

Instead of adding individual fields to configure MongoDB, a more scalable soluction would be to removing them all and replace for a mongo_uri parameter.

Similar to what has been done recently in Orion Context Broker

This version removes -dbhost, -rplSet, -dbTimeout, -dbuser, -dbAuthMech, -dbAuthDb, -dbSSL and -dbDisableRetryWrites CLI parameters along with associated env vars (deprecated in 3.12.0 version), so you have to use -dbURI (env var ORION_MONGO_URI) instead. Have a look to this documentation section if you need help to migrate the configuration.

AlvaroVega commented 1 week ago

Instead of adding individual fields to configure MongoDB, a more scalable soluction would be to removing them all and replace for a mongo_uri parameter.

Similar to what has been done recently in Orion Context Broker

This version removes -dbhost, -rplSet, -dbTimeout, -dbuser, -dbAuthMech, -dbAuthDb, -dbSSL and -dbDisableRetryWrites CLI parameters along with associated env vars (deprecated in 3.12.0 version), so you have to use -dbURI (env var ORION_MONGO_URI) instead. Have a look to this documentation section if you need help to migrate the configuration.

Yeah! It would be nice a great feature, replace MongoClientOptions to MongoClientUri