Open stephanbruijnis opened 7 years ago
I've encountered the error in Mx 7.5.1 and 7.6.0 as well.
The problem is in HandleFileSftp.java. In the element createSFTPChannel the following code retrieves previous sessions:
if(userSession.containsKey(session.getUserName())){ session = userSession.get(session.getUserName()); } else{ session = ConnectSession(session); }
The variable userSession is only set in the element setKnownHosts and in the element createSession when StrictHostkeyChecking is false. On the first try userSession variable is empty and will be filled with the current session. On the next tries it will find the old session (which is somehow not closed yet, even with the .disconnect() ) and use that session. This will eventually expire and when this happens, the message "sessioen is down" will appear.
Removing the line of code makes sure it will not happen again. I didn't check what happens when using StrictHostkeyChecking is true.
Hi
I get this issue a few minutes after using the SFTP configuration for the first time, also see this topic: https://forum.mendixcloud.com/link/questions/87263
Tested in mx6.8.1.