Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mongodb as datasource - how to do that? #26

Open
mrudulp opened this issue Jul 18, 2017 · 1 comment
Open

Mongodb as datasource - how to do that? #26

mrudulp opened this issue Jul 18, 2017 · 1 comment
Assignees

Comments

@mrudulp
Copy link

mrudulp commented Jul 18, 2017

Hi,

I am trying to use cyclotron([http://www.cyclotron.io][1]) to work with my database in mongodb.
The configuration settings doc seems to ask for custom mongodb.

But while creating data source there is no option to select mongodb.

I would like to
a) Select my database
b) Select collection
c) Set parameters for widgets to know what to plot.

Previously I had a custom stack running nodejs + mongodb + jquery to do the plotting. Wherein nodejs has the business logic as to exchange data based on query send from frontend.
I am looking to replace the whole stack so that with minimum programming plots can be created.

Regards

@baumandm
Copy link
Collaborator

Hi @mrudulp. Unfortunately, MongoDB isn't one of the built-in Data Sources in Cyclotron, despite using MongoDB as the backend.

This is mainly due to the fact that MongoDB doesn't have a good way to execute string queries. By this I mean, a user would need to put a MongoDB query string into the Cyclotron UI, and then some generic code would need to translate that string into the required MongoDB driver calls to provide that data. The last I looked, even things like JDBC for MongoDB was not in a very robust state.

We could implement a limited Data Source, which only supports picking a database, collection, and (optional) filters. Would this satisfy your needs, without the ability to run arbitrary queries or aggregations?

Alternately, with a little bit of programming you could add some new REST endpoints to the Cyclotron service to expose your MongoDB data as JSON. This would require some programming to setup each query, but would let you use any MongoDB driver features.

@baumandm baumandm self-assigned this Jul 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants