{"size": 567, "ext": "js", "max_stars_repo_path": "node_modules/mongo-connect/test/server.js", "max_stars_repo_name": "abdulfettahsancakli/NodeJs-Web-Project", "max_stars_repo_stars_event_min_datetime": "2021-07-04T08:54:06.000Z", "max_stars_repo_stars_event_max_datetime": "2021-07-14T10:26:21.000Z", "max_issues_repo_path": "node_modules/mongo-connect/test/server.js", "max_issues_repo_name": "abdulfettahsancakli/NodeJs-Web-Project", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "node_modules/mongo-connect/test/server.js", "max_forks_repo_name": "abdulfettahsancakli/NodeJs-Web-Project", "max_forks_repo_forks_event_min_datetime": "2020-02-15T22:10:20.000Z", "max_forks_repo_forks_event_max_datetime": "2020-02-16T02:54:44.000Z"}
{"max_stars_count": 2, "max_issues_count": null, "max_forks_count": 2, "avg_line_length": 22.68, "max_line_length": 52, "alphanum_fraction": 0.6790123457}
var express = require('express');
var mongo_con = require('../lib/mongo-connect.js');

var mongo = mongo_con.Mongo({
  host:'10.10.20.75',
  db:'test'
});

var app = express();


app.configure(function() {
  app.use(express.favicon());
  app.use(express.bodyParser());
});

app.get('/query/:collection', mongo.query);
app.post('/query/:collection', mongo.insert);
app.post('/mapreduce/:collection', mongo.mapreduce);
app.put('/query/:collection/:id', mongo.update);
app.del('/query/:collection/:id', mongo.delete);

app.listen(9011);
console.log('Server is opened');
