SFTP Smart Services

Overview

Contains multiple Smart Services for interacting with a remote file server via SFTP, FTP, or SCP.  Using these services, an Appian application can be configured to send and receive files, folders, and metadata in a process.  Features support for zlib compression.

Key Features & Functionality

Smart Services included:

  • SFTP:
    • Remove Directory Over SFTP (Basic Credentials)
    • Send File Over SFTP
    • Send File Over SFTP (Basic Credentials)
    • Receive File Over SFTP
    • Receive File Over SFTP (Basic Credentials)
    • Rename File Over SFTP
    • Get Remote Directory Contents Over SFTP
    • Get Remote Directory Contents Over SFTP (Basic Credentials)
    • Create Directory Over SFTP
    • Create Directory Over SFTP (Basic Credentials)
  • SCP:
    • Send File Over SCP
    • Receive File Over SCP
  • FTP:
    • Send File Over FTP
    • Receive File Over FTP
    • Receive Folder Over FTP
  • FTPS
    • Receive Folder Over FTPS
    • Send File Over FTPS (Basic Credentials)

All smart services in the package use Secure Credentials Store.

Anonymous
Parents
  • I am trying to send document using 'Send File Over SFTP' but receiving below error:

    2021-12-07 13:26:29,772 [Appian Work Item - 54497 - execution00 : UnattendedJavaActivityRequest] ERROR com.appian.ps.plugins.sftpsmartservices.SendFileOverSFTP - Error connecting to remote SFTP server
    com.jcraft.jsch.JSchException: java.net.UnknownHostException: https://host.com
    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.appian.ps.plugins.sftpsmartservices.SFTPConfig.connect(SFTPConfig.java:178)
    at com.appian.ps.plugins.sftpsmartservices.SendFileOverSFTP.run(SendFileOverSFTP.java:140)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.lambda$call$0(DefaultActivityExecutor.java:131)
    at com.appiancorp.plugins.PluginUsageLogger.runWithPluginInformation(PluginUsageLogger.java:52)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:131)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:125)
    at com.appiancorp.common.ContextClassLoaderSwitcher.runInContext(ContextClassLoaderSwitcher.java:27)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor.execute(DefaultActivityExecutor.java:125)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute(UnattendedJavaActivityRequest.java:88)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequestResponseCreator.getJavaActivityResultResponse(UnattendedJavaActivityRequestResponseCreator.java:21)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.getJavaActivityResultResponse(UnattendedJavaActivityRequest.java:67)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute0(UnattendedJavaActivityRequest.java:55)
    at com.appiancorp.common.persistence.data.AppianDataUserContextProvider.executeWithConsistentDataReads(AppianDataUserContextProvider.java:116)
    at com.appiancorp.process.engine.ProcessContinuationRequest.executeOuter(ProcessContinuationRequest.java:68)
    at com.appiancorp.process.engine.ContinuationRequest.execute(ContinuationRequest.java:123)
    at com.appiancorp.process.workpoller.UnattendedRequestHandlerBean.onMessage(UnattendedRequestHandlerBean.java:36)
    at com.appiancorp.process.workpoller.WorkItem.run(WorkItem.java:94)
    at org.springframework.jca.work.SimpleTaskWorkManager$DelegatingWorkAdapter.run(SimpleTaskWorkManager.java:239)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
    Caused by: java.net.UnknownHostException: https://host.com
    at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
    at java.net.VPNSocketImpl.connect(VPNSocketImpl.java:50)
    at java.net.Socket.connect(Socket.java:607)
    at java.net.Socket.connect(Socket.java:556)
    at java.net.Socket.<init>(Socket.java:452)
    at java.net.Socket.<init>(Socket.java:229)
    at com.jcraft.jsch.Util.createSocket(Util.java:343)
    ... 23 more
    2021-12-07 13:26:29,773 [Appian Work Item - 54497 - execution00 : UnattendedJavaActivityRequest] ERROR com.appian.ps.plugins.sftpsmartservices.SendFileOverSFTP - Error transferring file to SFTP server
    java.lang.NullPointerException
    at com.appian.ps.plugins.sftpsmartservices.SendFileOverSFTP.run(SendFileOverSFTP.java:149)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.lambda$call$0(DefaultActivityExecutor.java:131)
    at com.appiancorp.plugins.PluginUsageLogger.runWithPluginInformation(PluginUsageLogger.java:52)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:131)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:125)
    at com.appiancorp.common.ContextClassLoaderSwitcher.runInContext(ContextClassLoaderSwitcher.java:27)
    at com.appiancorp.process.runtime.framework.DefaultActivityExecutor.execute(DefaultActivityExecutor.java:125)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute(UnattendedJavaActivityRequest.java:88)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequestResponseCreator.getJavaActivityResultResponse(UnattendedJavaActivityRequestResponseCreator.java:21)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.getJavaActivityResultResponse(UnattendedJavaActivityRequest.java:67)
    at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute0(UnattendedJavaActivityRequest.java:55)
    at com.appiancorp.common.persistence.data.AppianDataUserContextProvider.executeWithConsistentDataReads(AppianDataUserContextProvider.java:116)
    at com.appiancorp.process.engine.ProcessContinuationRequest.executeOuter(ProcessContinuationRequest.java:68)
    at com.appiancorp.process.engine.ContinuationRequest.execute(ContinuationRequest.java:123)
    at com.appiancorp.process.workpoller.UnattendedRequestHandlerBean.onMessage(UnattendedRequestHandlerBean.java:36)
    at com.appiancorp.process.workpoller.WorkItem.run(WorkItem.java:94)
    at org.springframework.jca.work.SimpleTaskWorkManager$DelegatingWorkAdapter.run(SimpleTaskWorkManager.java:239)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)

    Has anyone faced similar issues? Please let me know if you have any inputs on this.

  • Hi From the Error Log ,we can see that the server is trying to connect to https://host.com which is not resolvable from your machines network resulting in a unknown host exception .

    Please try checking the same from your side

Comment Children
  • Hi Tj,

    The Cause of the issue is only due to network restrictions .Please try to manually/use file transfer tool like winscp to transfer a file through sftp from the appian machine .Please share us if you are able to do the same

  • Above is just sample endpoint as I can't disclose actual endpoint over here. However I had asked support from Appian and they replied that they are able to connect to endpoint from Appian so its not Appian issue and something to do with plugin.