Commit 78dba58e authored by mjadhav's avatar mjadhav

add port in ibase.xml


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@97035 ce508802-f39f-4f6c-b175-0d175dae99d5
parent bdfb794a
......@@ -77,6 +77,7 @@ public class GenInvoiceSchedule implements Schedule {
private String invRmFilePath="";
private String invLocFilePath="";
private String invBackupFilePath="";
private String invPort="";
......@@ -231,7 +232,7 @@ public class GenInvoiceSchedule implements Schedule {
invRmFilePath=invRmFilePath+"/invoice_"+invoiceId.trim()+".xml";
invBackupFilePath=invBackupFilePath+"/invoice_"+invoiceId.trim()+".xml";
System.out.println("invRmFilePath by appending invoice xml @@@@"+invRmFilePath);
updResult=putFile(invUser, invHost,invPwd,invRmFilePath,filePath);
updResult=putFile(invUser, invHost,invPwd,invPort,invRmFilePath,filePath);
if(updResult.equalsIgnoreCase("success"))
{
File fromFile = new File(filePath);
......@@ -1286,7 +1287,7 @@ public class GenInvoiceSchedule implements Schedule {
/*------------added by mahendra dated 24-DEC-2014 for file upload-------------------------*/
private String putFile(String username, String host, String password, String remotefile, String localfile)
private String putFile(String username, String host, String password,String port, String remotefile, String localfile)
{
JSch jsch = new JSch();
Session session = null;
......@@ -1295,10 +1296,11 @@ public class GenInvoiceSchedule implements Schedule {
System.out.println("username :"+username);
System.out.println("host :"+host);
System.out.println("password :"+password);
System.out.println("port :"+port);
System.out.println("remotefile :"+remotefile);
System.out.println("localfile :"+localfile);
//getSession(String username, String host, int port)
session = jsch.getSession(username, host, 22);
session = jsch.getSession(username, host, Integer.parseInt(port));
session.setConfig("StrictHostKeyChecking", "no");
session.setPassword(password);
session.connect();
......@@ -1354,7 +1356,8 @@ public class GenInvoiceSchedule implements Schedule {
System.out.println("invUser :::: "+invUser);
this.invPwd = dom.getElementsByTagName("INV_SFTP_PWD").item(0).getFirstChild().getNodeValue();
System.out.println("invPwd :::: "+invPwd);
this.invPort = dom.getElementsByTagName("INV_SFTP_PORT").item(0).getFirstChild().getNodeValue();
System.out.println("invPort :::: "+invPort);
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment