Add setDatabase function to Patomic
Finish commitTransaction function for Patomic
Refactor curl code a bit