[#39] pgsql backend and store

Fixes #39