def list_rules(self, service=None):
        """
            List fault fault injection rules installed on instances of a given service (or all services)
            returns a JSON dictionary
        """
        rules = {}
        for service in self.app.get_services():
            rules[service] = {}
            for instance in self.app.get_service_instances(service):
                rules[service][instance] = {}
                resp = requests.get("http://{}/gremlin/v1/rules/list".format(instance))
                if resp.status_code != 200:
                    print 'Failed to fetch rules from %s - instance %s' % (service, instance)
                    continue
                rules[service][instance] = resp.json()
                return rules