浏览代码

文件上传测试

Zhaops 6 年之前
父节点
当前提交
9f752673cf
共有 1 个文件被更改,包括 1 次插入4 次删除
  1. 1 4
      icssman-service/src/main/java/com/diagbot/client/fastdfs/FastDFSClient.java

+ 1 - 4
icssman-service/src/main/java/com/diagbot/client/fastdfs/FastDFSClient.java

@@ -1,7 +1,5 @@
 package com.diagbot.client.fastdfs;
 package com.diagbot.client.fastdfs;
 
 
-import com.diagbot.util.StringUtil;
-import org.apache.commons.lang3.StringUtils;
 import org.csource.common.NameValuePair;
 import org.csource.common.NameValuePair;
 import org.csource.fastdfs.ClientGlobal;
 import org.csource.fastdfs.ClientGlobal;
 import org.csource.fastdfs.FileInfo;
 import org.csource.fastdfs.FileInfo;
@@ -46,8 +44,6 @@ public class FastDFSClient {
         try {
         try {
             storageClient = getTrackerClient();
             storageClient = getTrackerClient();
             uploadResults = storageClient.upload_file(file.getContent(), file.getExt(), meta_list);
             uploadResults = storageClient.upload_file(file.getContent(), file.getExt(), meta_list);
-            logger.info("storageClient:"+storageClient.toString());
-            logger.info("uploadResults:"+ StringUtils.join(uploadResults,','));
         } catch (IOException e) {
         } catch (IOException e) {
             logger.error("IO Exception when uploadind the file:" + file.getName(), e);
             logger.error("IO Exception when uploadind the file:" + file.getName(), e);
         } catch (Exception e) {
         } catch (Exception e) {
@@ -118,6 +114,7 @@ public class FastDFSClient {
 
 
     private static StorageClient getTrackerClient() throws IOException {
     private static StorageClient getTrackerClient() throws IOException {
         TrackerServer trackerServer = getTrackerServer();
         TrackerServer trackerServer = getTrackerServer();
+        logger.info("http://" + getTrackerServer().getInetSocketAddress().getHostString() + ":" + ClientGlobal.getG_tracker_http_port() + "/");
         StorageClient storageClient = new StorageClient(trackerServer, null);
         StorageClient storageClient = new StorageClient(trackerServer, null);
         return storageClient;
         return storageClient;
     }
     }