Hi,
I have a application built with JCo that supports the Idoc Processing by external system.
This makes use of :
DestinationDataProvider and ServerDataProvider by registering them
as
com.sap.conn.jco.ext.Environment.registerDestinationDataProvider
com.sap.conn.jco.ext.Environment.registerServerDataProvider
respectively.
First created a JCoDestination object with DestinationDataProvider as following properties set
and a IDocRepository object created on this destination, but if network is down it give exception (which is obvious),
How we can internally force to try and reconnect (user defined no of attempts / time interval) till the network is available ?
// properties used for DestinationDataProvider
DestinationDataProvider.JCO_ASHOST,"<hostname>"
DestinationDataProvider.JCO_SYSNR,"<Sysno>"
DestinationDataProvider.JCO_CLIENT,"<client>"
DestinationDataProvider.JCO_USER,"<User>"
DestinationDataProvider.JCO_PASSWD,"<pwd>"
DestinationDataProvider.JCO_LANG,"EN"
DestinationDataProvider.JCO_POOL_CAPACITY,"5"
DestinationDataProvider.JCO_PEAK_LIMIT,"10"
DestinationDataProvider.JCO_DEST,"<destname>"
JCoDestination destination = JCoDestinationManager.getDestination(destinationName);
// below line of code give me exception mentioned below:
IDocRepository repository =destination.getRepository();
// ERROR Thrown is
ERROR: Connect to SAP gateway failed
//connection parameters.....................
LOCATION CPIC (TCP/IP) on local host with Unicode
ERROR
partner '<Host Address>' not reached
TIME Fri Sep 26 12:44:23 2014
RELEASE 720
COMPONENT NI (network interface)
VERSION 40
RC -10
MODULE nixxi.cpp
LINE 3286
DETAIL NiPConnect2: <Host Address>
SYSTEM CALL connect
ERRNO 10060
ERRNO TEXT WSAETIMEDOUT: Connection timed out
COUNTER 4
Regards,
Yogi