My first play plugin: Mongo Rest Layer
I’ve been working on an internal project where we needed a quick and easy way to interact with a mongo db over rest. Mongolab.com has an existing rest layer that does this, but we wanted to route it through our Play! 2 app.
So I created a Play! plugin called Mongo Rest Layer. Its a simple library that adds REST capabilities to your play app with little setup. You just need to pass in a mongo uri and override the onRouteRequest method of GlobalSettings. The REST behaviour is modelled on the mongolab.com api, but you can add your own flavour by implementing: brokers.RequestBroker.
May be of use to others.

Could you explain your use case? Why would you emulate an existing endpoint? Is it a scaling thing to move the load somewhere else or … ?
Hi James,
The use case would be mainly for prototyping. You have a mongo db and you’re building a new app with play, adding the plugin gives you a rest api ready to roll.
So it’s nothing to do with scaling.
The api is based on mongo labs but you’re db maybe elsewhere – on your dev machine for example.
Ed