refactored configProvider to be injected into the Rules objects.