Troubleshooting
Problem
AS2 outbound HTTP Post "Could not complete connection to specified host"
Symptom
Intermittently getting "could not complete connection to host" when HTTP posting to trading partner using AS2.
Error Message
Httpclient.log file:
[2009-04-27 08:37:39.38]
ERROR <HTTPClientAdapter_HTTPClientAdapter_node1-Thread-367> 000000000000
GLOBAL_SCOPE CustomConnectAgent.connectFailed() - Received signal from
Perimeter due to fail to make connection with message [Could not complete
connection to specified host]
[2009-04-27 08:37:39.381] ERROR
<HTTPClientAdapter_HTTPClientAdapter_node1-Thread-367> 000000000000
GLOBAL_SCOPE CustomConnectAgent.connectFailed() - encountered error due to
[Could not complete connection to specified host]
Perimeter.log file:
[2009-04-27 08:37:39.374] ERROR <Dispatcher> 000000000000
GLOBAL_SCOPE ClientIPAgent[InetSocketAddress-host:/217.33.234.155-port:80]:
Connection failed:
java.net.SocketException: Address already in use
(errno:226)
at sun.nio.ch.Net.connect(Native Method)
at
sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:460)
at
com.sterlingcommerce.perimeter.net.nio.SocketChannelWrapper.connect(SocketChanne
lWrapper.java:196)
at
com.sterlingcommerce.perimeter.dispatcher.ClientIPAgent.connect(ClientIPAgent.ja
va:96)
at
com.sterlingcommerce.perimeter.physical.NormalBase.startConnect(NormalBase.java:
133)
at
com.sterlingcommerce.perimeter.physical.PortCollectionElement.startConnect(PortC
ollectionElement.java:66)
at
com.sterlingcommerce.perimeter.physical.RetryElement$1.run(RetryElement.java:130
)
at
com.sterlingcommerce.perimeter.api.scheduler.TaskNode.run(TaskNode.java:62)
at
com.sterlingcommerce.perimeter.dispatcher.AbstractDispatcher.runTasks(AbstractDi
spatcher.java:440)
at
com.sterlingcommerce.perimeter.dispatcher.AbstractDispatcher.doRun(AbstractDispa
tcher.java:405)
at
com.sterlingcommerce.perimeter.dispatcher.AbstractDispatcher$2.run(AbstractDispa
tcher.java:182)
at java.lang.Thread.run(Thread.java:534)
Resolving The Problem
Upgrade from GIS 4.0 to GIS 4.2 build 4219. In GIS 4.0
AS2 processes use the B2B HTTP Client Adapter and in GIS 4.2 AS2 processes use
the HTTP Client Adapter. In the HTTP Client Adapter, the Local Port Range is
used to restrict the outbound connection to specific ports and in this case,
the customer had defined one port and therefore limited outbound AS2
connections to one transaction at a time. When there are multiple files to
send out, the first outbound connection binds to the port defined causing all
other outbound connections to report the port is already in use and "Could not
complete connection to specified host." To resolve this issue,
remove the Local Port Range restriction or broaden the port range so that
multiple files can be sent at the same time.
Historical Number
NFX5857
Product Synonym
[<p><b>]Escalation ID[</b><p>];36973;[<p><b>]Severity[</b><p>];Critical;[<p><b>]Type[</b><p>];NormalFix
Was this topic helpful?
Document Information
Modified date:
11 October 2019
UID
swg21555124