Enforcing User-Defined Management Logic In Large Scale Systems