Repository navigation
Conversation
Adds an optional, disabled-by-default output that stores the in-scope set requests the feeder receives from the server in a MongoDB collection (--mongosink, with the connection string in MONGODB_URI and --mongodb / --mongocoll for the names). The data points of one multi-set request are grouped by arrival time and upserted into one document with nested paths and typed values. Writes are asynchronous and never block the feeder.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
An optional output for feederv4 that stores the in-scope Set requests the feeder receives from the server in a MongoDB collection.
The database and collection default to
vissr/feederSets. Each Set request becomes one document: dot-separated paths become nested documents, and numeric/boolean values keep their native type so they can be queried and aggregated, e.g.Why
This lets a cloud-side VISSR deployment persist incoming vehicle data for history, analytics or backend applications without having to write a custom feeder.
Design notes
--mongosinkis not used.feeder/feeder-template/feederv4/README.md.Dependencies
Adds
go.mongodb.org/mongo-driver/v2(v2.4.0). As a resultgo mod tidybumps the indirectgolang.org/x/{net,sync,sys,text}modules and addsgolang.org/x/cryptoplus a few indirect driver dependencies. Thegodirective stays at 1.22.1. If you'd rather keep the module free of the driver, we're happy to put the sink behind a build tag.Testing
go test -race ./feeder/feeder-template/feederv4/).go build ./...,go vetandgo test -raceover the module (same as thetestworkflow) pass locally.Branches
Per the README, features merged to master are also carried to v3.1.5, v3.2 and v4.0. Let us know if you'd like us to open those PRs.