Bulk mode fixes

Implemented a generic flush function for the bulk mode handling.
Fixed up the bulk mode implementation to handle del operations.