class RuleProvider {

    public Future<List<Rule>> getRules(){
        Future<List<Rule>> future = Future.future();
        storage.get(rulesPath, buffer -> {
            if (buffer != null) {
                try {
                    List<Rule> rules = new RuleFactory(properties, routingRulesSchema).parseRules(buffer);
                    future.complete(rules);
                } catch (ValidationException e) {
                    log.error("Could parse routing rules", e);
                    future.fail(e);
                }
            } else {
                future.fail("Could not get URL '" + (rulesPath == null ? "<null>" : rulesPath) + "' (getting rules).");
            }
        });
        return future;
    }

    public  RuleProvider(Vertx vertx, String rulesPath, ResourceStorage storage, Map<String, Object> properties);

}