Issue #1131: Attachment migration sometimes fails due to Hibernate Session errors
Attempted fix