KRACOEUS-8556: Refreshing document pessimistic locks to make sure the document is in sync with the db.

This isn't the most ideal fix, as it doesn't fix the underlying issue.  But will resolve the blocker.
I guess i don't know how the document will be in sync with the db if we don't refresh the document, after we delete the lock.  the way this code looks is that we delete the lock from the db but it is never removed from the document, so the next time we save the document the lock gets saved again.