resource.addFilter(new RetryClientFilter(ServiceUtils.REST_RETRY_COUNT));
final WebResource.Builder builder = resource.accept(MediaType.APPLICATION_JSON_TYPE);
try {
final String response = builder.get(String.class);
LOGGER.trace("Retrieved response=" + response);
final IGuildDetailsDTO result = GuildService.this.guildDTOFactory.newGuildDetailsOf(response);
LOGGER.debug("Built result=" + result);
return Optional.of(result);
} catch (ClientHandlerException | UniformInterfaceException e) {
LOGGER.fatal("Exception thrown while quering " + resource.getURI(), e);
return Optional.absent();