web stats
File Reader Source Connector -sftp - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 11-10-2014, 02:09 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Question File Reader Source Connector -sftp

Using Mirth Connect Server 3.1.0.7420

I have a File Reader Source Connector -sftp set to Polling at a certain time of day. I have Include all Subdirectories checked and am testing with a specific filename etc... The Test Read button works fine. The file is in one of the Subdirectories.

The Problem: The dashboard says Polling... but nothing ever happens. It just keeps saying Polling. I have to stop and halt and then undeploy.

Any ideas?

Last edited by StickyBandit; 11-10-2014 at 02:16 PM.
Reply With Quote
  #2  
Old 11-10-2014, 02:15 PM
narupley's Avatar
narupley narupley is online now
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,111
narupley is on a distinguished road
Default

You could be including a LOT of subdirectories / files, which may explain why it's taking so long. That's one of the implications of enabling that feature.
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #3  
Old 11-10-2014, 02:29 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Default more info

I waited longer this time. The polling finally stopped and there was an error in the logger...

ERROR (com.mirth.connect.connectors.file.FileReceiver:18 1): Error polling in channel: ???????????????????
at com.jcraft.jsch.ChannelSftp.cd(ChannelSftp.java:35 9)
at com.mirth.connect.connectors.file.filesystems.Sftp Connection.cwd(SftpConnection.java:187)
at com.mirth.connect.connectors.file.filesystems.Sftp Connection.listDirectories(SftpConnection.java:160 )
at com.mirth.connect.connectors.file.FileReceiver.lis tDirectories(FileReceiver.java:536)
at com.mirth.connect.connectors.file.FileReceiver.lis tFilesRecursively(FileReceiver.java:196)
at com.mirth.connect.connectors.file.FileReceiver.pol l(FileReceiver.java:173)
at com.mirth.connect.donkey.server.channel.PollConnec tor$PollConnectorTask.run(PollConnector.java:131)
at java.util.TimerThread.mainLoop(Timer.java:512)
at java.util.TimerThread.run(Timer.java:462)Caused by: java.lang.ArrayIndexOutOfBoundsException
at java.net.SocketOutputStream.socketWrite(SocketOutp utStream.java:87)
at java.net.SocketOutputStream.write(SocketOutputStre am.java:136)
at com.jcraft.jsch.IO.put(IO.java:60)
at com.jcraft.jsch.Session._write(Session.java:1354)
at com.jcraft.jsch.Session.write(Session.java:1321)
at com.jcraft.jsch.ChannelSftp.sendPacketPath(Channel Sftp.java:2562)
at com.jcraft.jsch.ChannelSftp.sendPacketPath(Channel Sftp.java:2546)
at com.jcraft.jsch.ChannelSftp.sendREALPATH(ChannelSf tp.java:2463)
at com.jcraft.jsch.ChannelSftp._realpath(ChannelSftp. java:2312)
at com.jcraft.jsch.ChannelSftp.cd(ChannelSftp.java:34 2)
Reply With Quote
  #4  
Old 11-10-2014, 02:31 PM
narupley's Avatar
narupley narupley is online now
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,111
narupley is on a distinguished road
Default

Recursively, exactly how many files and folders are in the base directory you're reading from?
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #5  
Old 11-10-2014, 02:33 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Default

47 folders
no more subfolders.

Files,... there maybe about 35-50. But I have an exact filename that I am polling for.
Reply With Quote
  #6  
Old 11-10-2014, 02:34 PM
narupley's Avatar
narupley narupley is online now
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,111
narupley is on a distinguished road
Default

So 47 folders recursively (descendants), or direct children of the base directory you've set in the File Reader settings? And how many file descendants approximately?

Have you tried paring it down to a smaller subset (like only one of the child folders for example) and seeing if you still get the error?
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #7  
Old 11-10-2014, 02:35 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Default

Yes folders are all direct descendants.
Reply With Quote
  #8  
Old 11-10-2014, 02:38 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Default

If I add the folder name then it finds the file right away.
This is okay for some testing, but long term we will need it to poll all the folders.
Reply With Quote
  #9  
Old 11-10-2014, 02:39 PM
narupley's Avatar
narupley narupley is online now
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,111
narupley is on a distinguished road
Default

Quote:
Originally Posted by StickyBandit View Post
Yes folders are all direct descendants.
If by "direct descendants" you meant "direct children", then okay, and what about any folders within those folders?

In any case, it's likely that you're trying to list way too much, and the SFTP server is throwing a timeout before JSch is able to finish. See if there are any timeout settings on the SFTP server side.
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #10  
Old 11-13-2014, 12:53 PM
StickyBandit's Avatar
StickyBandit StickyBandit is offline
Mirth Guru
 
Join Date: Aug 2013
Location: Home Alone
Posts: 918
StickyBandit is on a distinguished road
Default

ERROR 2014-11-13 14:50:18,889 [pool-28-thread-2] com.mirth.connect.server.channel.LoggingTaskHandle r: com.mirth.connect.donkey.server.ResumeException: Failed to resume channel SFTP Server Polling test (b21f65f4-0fdd-4aa5-a66d-200b67e16a97).
at com.mirth.connect.donkey.server.channel.Channel.re sume(Channel.java:815)
at com.mirth.connect.server.controllers.DonkeyEngineC ontroller$ChannelStatusTask.execute(DonkeyEngineCo ntroller.java:1363)
at com.mirth.connect.server.channel.ChannelTask.call( ChannelTask.java:59)
at com.mirth.connect.server.channel.ChannelTask.call( ChannelTask.java:16)
at java.util.concurrent.FutureTask$Sync.innerRun(Futu reTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.jav a:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.run Task(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: com.mirth.connect.donkey.server.ConnectorTaskExcep tion: connection is closed by foreign host
at com.mirth.connect.connectors.file.FileReceiver.onS tart(FileReceiver.java:141)
at com.mirth.connect.donkey.server.channel.SourceConn ector.start(SourceConnector.java:108)
at com.mirth.connect.donkey.server.channel.PollConnec tor.start(PollConnector.java:29)
at com.mirth.connect.donkey.server.channel.Channel.re sume(Channel.java:801)
... 8 more
Caused by: com.jcraft.jsch.JSchException: connection is closed by foreign host
at com.jcraft.jsch.Session.connect(Session.java:269)
at com.mirth.connect.connectors.file.filesystems.Sftp Connection.<init>(SftpConnection.java:115)
at com.mirth.connect.connectors.file.filesystems.File SystemConnectionFactory.makeObject(FileSystemConne ctionFactory.java:95)
at org.apache.commons.pool.impl.GenericObjectPool.bor rowObject(GenericObjectPool.java:1188)
at com.mirth.connect.connectors.file.FileConnector.ge tConnection(FileConnector.java:197)
at com.mirth.connect.connectors.file.FileReceiver.onS tart(FileReceiver.java:138)
... 11 more
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 04:37 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Mirth Corporation