Downgrades to Java 1.6 to run demo on Debian Wheezy
[mkjsf-moved-to-github.git] / src / main / java / com / indexdata / pz2utils4jsf / pazpar2 / sp / ServiceProxyClient.java
index 16eea35..e881506 100644 (file)
@@ -2,10 +2,8 @@ package com.indexdata.pz2utils4jsf.pazpar2.sp;
 \r
 import static com.indexdata.pz2utils4jsf.utils.Utils.nl;\r
 \r
-import java.io.BufferedWriter;\r
 import java.io.ByteArrayOutputStream;\r
 import java.io.File;\r
-import java.io.FileWriter;\r
 import java.io.IOException;\r
 import java.nio.file.Path;\r
 import java.nio.file.Paths;\r
@@ -13,7 +11,6 @@ import java.util.ArrayList;
 import java.util.HashMap;\r
 import java.util.List;\r
 import java.util.Map;\r
-import java.util.Scanner;\r
 \r
 import javax.enterprise.context.SessionScoped;\r
 import javax.inject.Named;\r
@@ -241,6 +238,7 @@ public class ServiceProxyClient implements SearchClient {
     File initDoc = new File(filePath);\r
     logger.info("Posting to SP: ");\r
     Path path = Paths.get(filePath);\r
+    /*\r
     if (logger.isDebugEnabled()) {\r
       try (Scanner scanner =  new Scanner(path, "UTF-8")){\r
         while (scanner.hasNextLine()){\r
@@ -248,6 +246,7 @@ public class ServiceProxyClient implements SearchClient {
         }      \r
       }     \r
     }\r
+    */\r
     post.setEntity(new FileEntity(initDoc));\r
     byte[] response = client.execute(post, handler);\r
     logger.info("Response on POST was: " + new String(response,"UTF-8"));    \r