Protecting Water Quality by Optimizing the Operations and Maintenance of Distribution Systems