I was able to reduce the memory overhead by applying an empty context to the SqlQuery (see this link for details. Otherwise the BulkOperationCleanupAction instances contain a huge list of all tables which is used to refresh all related Entities.
Nevertheless the BulkOperationCleanupAction instances are created for every update statement, which sums up to huge amount of heap space for large operations.
|