{"id":19707586,"url":"https://github.com/cailloumajor/mongodb-influxdb","last_synced_at":"2026-05-04T23:40:07.067Z","repository":{"id":104134725,"uuid":"570601511","full_name":"cailloumajor/mongodb-influxdb","owner":"cailloumajor","description":"Manages data flow between MongoDB and InfluxDB","archived":false,"fork":false,"pushed_at":"2025-02-20T06:44:18.000Z","size":588,"stargazers_count":1,"open_issues_count":12,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-02-20T07:33:18.641Z","etag":null,"topics":["database","influxdb","mongodb","rust-lang","tsdb"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cailloumajor.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-25T15:31:34.000Z","updated_at":"2025-01-13T09:02:09.000Z","dependencies_parsed_at":"2023-10-16T04:09:18.116Z","dependency_job_id":"33704a2f-3b4f-4d78-bf31-9a8c4cea7e66","html_url":"https://github.com/cailloumajor/mongodb-influxdb","commit_stats":null,"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cailloumajor%2Fmongodb-influxdb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cailloumajor%2Fmongodb-influxdb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cailloumajor%2Fmongodb-influxdb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cailloumajor%2Fmongodb-influxdb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cailloumajor","download_url":"https://codeload.github.com/cailloumajor/mongodb-influxdb/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241024164,"owners_count":19896182,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["database","influxdb","mongodb","rust-lang","tsdb"],"created_at":"2024-11-11T21:39:19.844Z","updated_at":"2026-05-04T23:40:07.061Z","avatar_url":"https://github.com/cailloumajor.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mongodb-influxdb\n\n[![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg)](https://conventionalcommits.org)\n\n## Specifications\n\nThis service is responsible for data flow between MongoDB and InfluxDB. It has following roles.\n\n### Recording data from MongoDB to InfluxDB\n\nThis service will query the configured database and collection at regular interval (configured by a CLI argument), and send data points to InfluxDB (line protocol), one for each document in the collection. The measurement will be set to the namespace of the collection.\n\nData points will have following characteristics:\n\n- document primary key (`_id`) as a tag value, with `id` as the tag key;\n- each key and value pair in the `val` sub-document, respectively as field key and value;\n\n## Data flow\n\n```mermaid\nsequenceDiagram\n    participant MongoDB\n    participant Me as This service\n    participant TSDB as InfluxDB\n    loop Each collect interval\n        Me-\u003e\u003e+MongoDB: Query documents\n        MongoDB--\u003e\u003e-Me: Replies with documents\n        activate Me\n        Me--\u003eMe: Converts documents to line protocol\n        deactivate Me\n        Me-\u003e\u003e+TSDB: Writes data points\n        TSDB--\u003e\u003e-Me: Sends write result\n    end\n```\n\n## Usage\n\n```console\n$ mongodb-influxdb --help\nUsage: mongodb-influxdb [OPTIONS] --mongodb-database \u003cMONGODB_DATABASE\u003e --mongodb-collection \u003cMONGODB_COLLECTION\u003e --influxdb-api-token \u003cINFLUXDB_API_TOKEN\u003e --influxdb-org \u003cINFLUXDB_ORG\u003e --influxdb-bucket \u003cINFLUXDB_BUCKET\u003e\n\nOptions:\n      --interval \u003cINTERVAL\u003e\n          Scraping interval [env: INTERVAL=] [default: 1m]\n      --mongodb-uri \u003cMONGODB_URI\u003e\n          URI of MongoDB server [env: MONGODB_URI=] [default: mongodb://mongodb]\n      --mongodb-database \u003cMONGODB_DATABASE\u003e\n          MongoDB database [env: MONGODB_DATABASE=]\n      --mongodb-collection \u003cMONGODB_COLLECTION\u003e\n          MongoDB collection [env: MONGODB_COLLECTION=]\n      --influxdb-url \u003cINFLUXDB_URL\u003e\n          InfluxDB root URL [env: INFLUXDB_URL=] [default: http://influxdb:8086]\n      --influxdb-api-token \u003cINFLUXDB_API_TOKEN\u003e\n          InfluxDB API token with write-buckets permission [env: INFLUXDB_API_TOKEN=]\n      --influxdb-org \u003cINFLUXDB_ORG\u003e\n          InfluxDB organization name or ID [env: INFLUXDB_ORG=]\n      --influxdb-bucket \u003cINFLUXDB_BUCKET\u003e\n          InfluxDB bucket to write to [env: INFLUXDB_BUCKET=]\n  -v, --verbose...\n          Increase logging verbosity\n  -q, --quiet...\n          Decrease logging verbosity\n  -h, --help\n          Print help\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcailloumajor%2Fmongodb-influxdb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcailloumajor%2Fmongodb-influxdb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcailloumajor%2Fmongodb-influxdb/lists"}