String.format(ERROR_MESSAGE_PATTERN, endpointUrl, statusCode));
}
int version = getVersion(get);
SignatureFileInfo signatureFileInfo = new SignatureFileInfo(version, false, SignatureType.CONTAINER);
String fileName = String.format(FILENAME_PATTERN, version);
final File targetFile = new File(targetDir, fileName);
writer = new FileWriter(targetFile);
IOUtils.copy(get.getResponseBodyAsStream(), writer);
signatureFileInfo.setFile(targetFile);
return signatureFileInfo;
} catch (UnknownHostException e) {
throw new SignatureServiceException(
String.format(COULD_NOT_FIND_SERVER, endpointUrl));