[#14] Start using global entity manager

Close #14
Merge pull request #16 from mamatoad/entitymanager

[#14] Start using global entity manager