Examples of FullResponseHolder


Examples of com.metamx.http.client.response.FullResponseHolder

      String url = getRuleURL();
      if (url == null) {
        return;
      }

      FullResponseHolder response = httpClient.get(new URL(url))
                                              .go(responseHandler)
                                              .get();

      if (response.getStatus().equals(HttpResponseStatus.FOUND)) {
        url = response.getResponse().getHeader("Location");
        log.info("Redirecting rule request to [%s]", url);
        response = httpClient.get(new URL(url))
                             .go(responseHandler)
                             .get();
      }

      ConcurrentHashMap<String, List<Rule>> newRules = new ConcurrentHashMap<>(
          (Map<String, List<Rule>>) jsonMapper.readValue(
              response.getContent(), new TypeReference<Map<String, List<Rule>>>()
          {
          }
          )
      );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.