we have a Ruby server application running on MongoDB.
We need to run function on a server which calculates sizes of objects per customer. We used db.command(:$eval...) for this however that's not deployable to production because such app would require rights to the whole db.
We were investigating to use db.system.js.save() . It is possible to run such a saved function withou using db.command(:$eval...) ?
Or would be other options for this? I'm currently also looking at the possibility to use mapReduce for this.
Thanks in advance,
Michal
Related
One of ours statistician is stuck trying to read data from mongoDB using SAS.
In my experience connecting mongo to other languages always require a native driver, but in this case I've found that is only possible using ODBC.
I've tried to find a better way to connect this two software but the only idea that came to my mind is to expose mongo via webservice.
Any of you have a better solution to connect SAS to mongodb?
After some tries we found that using webservice is the most convenient way to solve mongodb access in ours case.
Some statistician required to load data on laptop from outside the corporate network so we decided to extend our web service to expose some more informations and access it in SAS like this https://blogs.sas.com/content/sasdummy/2016/12/02/json-libname-engine-sas/
Thanks all for the clarification regarding ODBC, to me was a real surprise that is still the preferred way to load data in enterprise environments.
In my project I need to simulate social network community members and their activities. I think to represent the members as nodes and need to store the count of their postings, feedback etc. Can we store the data collected by executing tcl script into a database (PostgreSQL)? If yes can anyone explain how it is?
You could also use SQlite3, a much lighter alternative to a full Postgres installation.
see https://www.sqlite.org/tclsqlite.html
Try OpenACS - it's a social networking community software and is written using TCL and Postgresql (or Oracle if you prefer)
Currently we are using apache flume framework to collect the logs from all our web applications and it will store the logs in MongoDB database table called “Raw_Data”.
Now we got a task to differentiate the logs and store the logging information in different tables based on the application. So we decided to maintain a separate table for each application. Is there any way to create and run stored JavaScript on a frequency like scheduler to load the data application wise in MongoDB?
I’m very much familiar with oracle DB but I’m new to MongoDb. Can someone help me to find out the required things for this asap.
Thanks
Kishore
MongoDB has stored Javascript procedures, but no scheduler.
http://docs.mongodb.org/manual/tutorial/store-javascript-function-on-server/
You could trigger this from a client machine using a cron job and the mongo shell. However, I strongly recommend simply running a script in Python or similar client-side scripting language. It'll be far easier to version-control and to debug than server-side Javascript.
Im in the start up phase of creating an internal system based on PHP and MongoDB. The users of this system are Javascript programmers and would like to be able to make custom queries to the Mongo database from a frontend gui with arbitrary Mongo shell queries. Of course this would not be a problem at all if I forced them to to write the queries with proper PHP arrays etc, but i would definitely like to avoid this.
I am not quite sure how to approach a feature like this without writing some advanced methods being able to restructure the queries to proper formated arrays that can be used in MongoClient PHP. One approach would be making use of the i.e. MongoDB::execute() method and run the javascript on the database server - a method i don't fancy at all.
Im kindly asking if you have any ideas on how to achieve the requested functionalities to some extend.
Thank you in advance.
Are you looking for something like this : http://rockmongo.com/ ?
I would like to run a benchmark using mongodb benchrun that will create a lot of load on the backend storage. and at the same time will be representative of real application workloads.
If somebody has some js code ready, would be appreciated.
You can take a look in MongoDB repository on github - there are multiple performance tests that use benchRun. https://github.com/mongodb/mongo/tree/master/jstests has some in bench_xxx.js files.
You can also look at some sample scripts I have here:
https://github.com/asya999/bits-n-pieces/tree/master/benchRun