Training database tools

Add training service and related test.

![c5d2a420-ce19-41d5-ab13-0091d32271d1](https://cloud.githubusercontent.com/assets/2420472/3371239/a43ffcdc-fb9d-11e3-80e6-1ae31b8b68a5.png)