Ticket 47602 - txn commit being performed too early
Bug Description: The transaction is committed too early, and this leads to
a deadlock when accessing the retro changelog.
Fix Description: Move the commit after we are done using the txn(id2entry, etc).
https://fedorahosted.org/389/ticket/47602
Reviewed by: nhosoi(Thanks!)