|
@@ -141,7 +141,10 @@ public class UpYunClient {
|
|
HttpPut httpPut = new HttpPut(url);
|
|
HttpPut httpPut = new HttpPut(url);
|
|
httpPut.setConfig(this.requestConfig);
|
|
httpPut.setConfig(this.requestConfig);
|
|
CloseableHttpResponse response = null;
|
|
CloseableHttpResponse response = null;
|
|
|
|
+
|
|
|
|
+ long s = System.currentTimeMillis();
|
|
try {
|
|
try {
|
|
|
|
+
|
|
String date = getGMTDate();
|
|
String date = getGMTDate();
|
|
httpPut.addHeader(DATE, date);
|
|
httpPut.addHeader(DATE, date);
|
|
|
|
|
|
@@ -170,6 +173,11 @@ public class UpYunClient {
|
|
httpPut.releaseConnection();
|
|
httpPut.releaseConnection();
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ if (log.isDebugEnabled()) {
|
|
|
|
+ log.debug("[upyun]. path=" + path + "; cost " + (System.currentTimeMillis() - s)
|
|
|
|
+ + " ms.");
|
|
|
|
+ }
|
|
|
|
+
|
|
String fileUrl = "http://" + bucketName + ".b0.upaiyun.com" + filePath;
|
|
String fileUrl = "http://" + bucketName + ".b0.upaiyun.com" + filePath;
|
|
return fileUrl;
|
|
return fileUrl;
|
|
}
|
|
}
|