I came across this error when working with file to iDoc interface.
Check the below settings if the error occurs.
1. Maintian Communication Channel Configuration.
In your receiver iDoc communication channel maintain the correct RFC destination and port.
Check if the connection is working without errors.
If the port and RFC destination is working assign communication channel with the correct detail.