From d764b741d4747ee1fe05bbfed9c95e8f76865bd9 Mon Sep 17 00:00:00 2001 From: Redkale <22250530@qq.com> Date: Mon, 8 Aug 2016 11:54:22 +0800 Subject: [PATCH] --- src/org/redkale/util/Utility.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/org/redkale/util/Utility.java b/src/org/redkale/util/Utility.java index 8f3a3c1ce..c7fa45341 100644 --- a/src/org/redkale/util/Utility.java +++ b/src/org/redkale/util/Utility.java @@ -590,7 +590,11 @@ public final class Utility { return remoteHttpContent(ctx, "GET", url, headers, body).toByteArray(); } - protected static ByteArrayOutputStream remoteHttpContent(SSLContext ctx, String method, String url, Map headers, String body) throws IOException { + public static ByteArrayOutputStream remoteHttpContent(String method, String url, Map headers, String body) throws IOException { + return remoteHttpContent(null, method, url, headers, body); + } + + public static ByteArrayOutputStream remoteHttpContent(SSLContext ctx, String method, String url, Map headers, String body) throws IOException { HttpURLConnection conn = (HttpURLConnection) new URL(url).openConnection(); conn.setConnectTimeout(3000); conn.setReadTimeout(3000);