in src/main/java/com/example/redis/utilities/FargateMetaData.java [65:86]
private String connectionResponseToString(HttpURLConnection connection) {
BufferedReader br = null;
try {
if (connection.getResponseCode() >= 200 && connection.getResponseCode() < 400) {
br = new BufferedReader(new InputStreamReader(connection.getInputStream()));
} else {
br = new BufferedReader(new InputStreamReader(connection.getErrorStream()));
}
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = br.readLine()) != null) {
response.append(inputLine);
}
br.close();
return response.toString();
} catch (IOException e) {
return e.toString();
}
}