Fixed some deadlock issues from the last push

The write mutex wasn't getting unlocked before we were
trying to push to the database, and we need the read lock
in order to commit the object.

Solved by using a buffered channel for the time being.