-
-
Notifications
You must be signed in to change notification settings - Fork 968
Closed
Description
I am from the Azure Logic apps team and we use the library in the SFTP connector there.
For one of the users (SFTP server used is in-house system developed using Golang) we are seeing the ListDirectory method intermittently fails with the below exception
System.NotSupportedException: Request 'ping' is not supported.
at Renci.SshNet.Common.AsyncResult.EndInvoke()
at Renci.SshNet.SftpClient.EndListDirectory(IAsyncResult asyncResult)
at Microsoft.Azure.Workflows.ServiceProviders.Sftp.Clients.SftpClientWrapper.EndListDirectory(IAsyncResult asyncResult)
at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)
Our code looks like this
var authenticationMethods = new List<AuthenticationMethod>();
authenticationMethods.Add(new PasswordAuthenticationMethod(
username: key.Username,
password: key.Password));
var sftpConnectionInfo = new ConnectionInfo(
host: key.Host,
username: key.Username,
port: key.Port,
authenticationMethods: authMethods.ToArray());
client.Connect();
var directoryContents = await Task.Factory
.FromAsync(
beginMethod: (asyncCallback, state) => client.BeginListDirectory(
path: targetDirectory,
asyncCallback: asyncCallback,
state: state),
endMethod: client.EndListDirectory,
state: null)
.ConfigureAwait(continueOnCapturedContext: false);We saw a similar issue #638 and noticed the fix is merged. However we tried with the latest bits from develop branch and noticed the issue persists.
Please provide your inisights on the issue and let us know if there's a workaround or fix possible.
Metadata
Metadata
Assignees
Labels
No labels