Implemented logging and soft delete