Initial refactoring for bulk_email monitoring.