|
|
|
@ -53,7 +53,7 @@ public class StorageUtils {
|
|
|
|
|
out.close();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static String uploadFilesOnStorage(String scope, String user, String localFolder, String remoteFolder, String file, boolean httplink) throws Exception {
|
|
|
|
|
public static String uploadFilesOnStorage(String scope, String user, String localFolder, String remoteFolder, String file, boolean httpslink) throws Exception {
|
|
|
|
|
try {
|
|
|
|
|
// ScopeProvider.instance.set(scope);
|
|
|
|
|
AnalysisLogger.getLogger().info("Loading file on scope: " + scope);
|
|
|
|
@ -61,8 +61,8 @@ public class StorageUtils {
|
|
|
|
|
String remotef = remoteFolder+file.replace(" ","%20");
|
|
|
|
|
client.put(true).LFile(new File(localFolder,file).getAbsolutePath()).RFile(remotef);
|
|
|
|
|
String url = "";
|
|
|
|
|
if (httplink)
|
|
|
|
|
url = client.getHttpUrl().RFile(remotef);
|
|
|
|
|
if (httpslink)
|
|
|
|
|
url = client.getHttpsUrl().RFile(remotef);
|
|
|
|
|
else
|
|
|
|
|
url = client.getUrl().RFile(remotef);
|
|
|
|
|
try{client.close();}catch(Exception e){}
|
|
|
|
|