I'm using Java driver for MongoDB (mongo-java-driver-2.13.0).
I need to store a function, called my_function, on server.
From MongoDB shell I used the following code:
> db.system.js.save( { _id : "function1", value : my_function } );
I need this function to use it in a map-reduce.
How can I store the function using Java driver?