Hi there, I have the following problem:
code:
spark.read. format("com.springml.spark.sftp"). option("host", ftp_host). option("username", ftp_user). option("password", ftp_password). option("fileType", "csv"). option("delimiter", ","). option("header","false"). option("inferSchema","true"). option("multiLine", "true"). load(makeFTPPath("Address_template.csv",false))
error:
Exception in thread "main" com.jcraft.jsch.JSchException: java.net.ConnectException: Connection refused: connect at com.jcraft.jsch.Util.createSocket(Util.java:349) at com.jcraft.jsch.Session.connect(Session.java:215) at com.jcraft.jsch.Session.connect(Session.java:183) at com.springml.sftp.client.SFTPClient.createSFTPChannel(SFTPClient.java:275) at com.springml.sftp.client.SFTPClient.copy(SFTPClient.java:73) at com.springml.spark.sftp.DefaultSource.copy(DefaultSource.scala:212) at com.springml.spark.sftp.DefaultSource.createRelation(DefaultSource.scala:80) at com.springml.spark.sftp.DefaultSource.createRelation(DefaultSource.scala:41) at org.apache.spark.sql.execution.datasources.DataSource.resolveRelation(DataSource.scala:318) at org.apache.spark.sql.DataFrameReader.loadV1Source(DataFrameReader.scala:223) at org.apache.spark.sql.DataFrameReader.load(DataFrameReader.scala:211) at org.apache.spark.sql.DataFrameReader.load(DataFrameReader.scala:178) at hkt.jobs.Demo$.transform(Demo.scala:26) at hkt.trait.TraitJob.run(TraitJob.scala:17) at hkt.trait.TraitJob.run$(TraitJob.scala:15) at hkt.jobs.Demo$.run(Demo.scala:9) at hkt.jobs.Demo$.delayedEndpoint$hkt$jobs$Demo$1(Demo.scala:34) at hkt.jobs.Demo$delayedInit$body.apply(Demo.scala:9) at scala.Function0.apply$mcV$sp(Function0.scala:39) at scala.Function0.apply$mcV$sp$(Function0.scala:39) at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17) at scala.App.$anonfun$main$1$adapted(App.scala:80) at scala.App$$Lambda$5/226710952.apply(Unknown Source) at scala.collection.immutable.List.foreach(List.scala:392) at scala.App.main(App.scala:80) at scala.App.main$(App.scala:78) at hkt.jobs.Demo$.main(Demo.scala:9) at hkt.jobs.Demo.main(Demo.scala) Caused by: java.net.ConnectException: Connection refused: connect at java.net.DualStackPlainSocketImpl.connect0(Native Method) at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at java.net.Socket.<init>(Socket.java:434) at java.net.Socket.<init>(Socket.java:211) at com.jcraft.jsch.Util.createSocket(Util.java:343) ... 27 more
Hi there, I have the following problem: code:
spark.read. format("com.springml.spark.sftp"). option("host", ftp_host). option("username", ftp_user). option("password", ftp_password). option("fileType", "csv"). option("delimiter", ","). option("header","false"). option("inferSchema","true"). option("multiLine", "true"). load(makeFTPPath("Address_template.csv",false))
error:Exception in thread "main" com.jcraft.jsch.JSchException: java.net.ConnectException: Connection refused: connect at com.jcraft.jsch.Util.createSocket(Util.java:349) at com.jcraft.jsch.Session.connect(Session.java:215) at com.jcraft.jsch.Session.connect(Session.java:183) at com.springml.sftp.client.SFTPClient.createSFTPChannel(SFTPClient.java:275) at com.springml.sftp.client.SFTPClient.copy(SFTPClient.java:73) at com.springml.spark.sftp.DefaultSource.copy(DefaultSource.scala:212) at com.springml.spark.sftp.DefaultSource.createRelation(DefaultSource.scala:80) at com.springml.spark.sftp.DefaultSource.createRelation(DefaultSource.scala:41) at org.apache.spark.sql.execution.datasources.DataSource.resolveRelation(DataSource.scala:318) at org.apache.spark.sql.DataFrameReader.loadV1Source(DataFrameReader.scala:223) at org.apache.spark.sql.DataFrameReader.load(DataFrameReader.scala:211) at org.apache.spark.sql.DataFrameReader.load(DataFrameReader.scala:178) at hkt.jobs.Demo$.transform(Demo.scala:26) at hkt.trait.TraitJob.run(TraitJob.scala:17) at hkt.trait.TraitJob.run$(TraitJob.scala:15) at hkt.jobs.Demo$.run(Demo.scala:9) at hkt.jobs.Demo$.delayedEndpoint$hkt$jobs$Demo$1(Demo.scala:34) at hkt.jobs.Demo$delayedInit$body.apply(Demo.scala:9) at scala.Function0.apply$mcV$sp(Function0.scala:39) at scala.Function0.apply$mcV$sp$(Function0.scala:39) at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17) at scala.App.$anonfun$main$1$adapted(App.scala:80) at scala.App$$Lambda$5/226710952.apply(Unknown Source) at scala.collection.immutable.List.foreach(List.scala:392) at scala.App.main(App.scala:80) at scala.App.main$(App.scala:78) at hkt.jobs.Demo$.main(Demo.scala:9) at hkt.jobs.Demo.main(Demo.scala) Caused by: java.net.ConnectException: Connection refused: connect at java.net.DualStackPlainSocketImpl.connect0(Native Method) at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at java.net.Socket.<init>(Socket.java:434) at java.net.Socket.<init>(Socket.java:211) at com.jcraft.jsch.Util.createSocket(Util.java:343) ... 27 more