Forum Discussion

Vinoth_96603's avatar
Vinoth_96603
Icon for Nimbostratus rankNimbostratus
Aug 12, 2010

Setting timeout through iControl API for device interaction

Hi All,

 

 

Through a Java application, I'm accessing the BIG IP device and retrieving the statistical details corresponding to each WideIp, Pool, PoolMember, etc. Below is the code I'm using to get the statistical data. iControl version I'm using is 9.x.

 

 

try {

 

iControl.Interfaces device = null;

 

LocalLBVirtualServerVirtualServerStatistics statistics = null;

 

 

device = new iControl.Interfaces("1.2.3.4", "admin", "admin");

 

statistics = device.getLocalLBVirtualServer().get_all_statistics();

 

} catch (Exception e) {

 

System.out.println("Error while retrieving statistics");

 

e.printStackTrace();

 

}

 

 

Above code is executing fine, if the BIG IP credentials and IP address are correct. If the IP address mentioned is incorrect while retrieving the Interface instance, I'm getting SSLHandshakeException as mentioned below. Problem is, I'm getting this error after 3 mintues (approx.). Is there a way to set timeout, so that I could get the error (this or some timeout error) within 30 seconds instead of waiting for 3 minutes. Could someone help me out to set timeout while getting the statistics from a device?

 

 

Exception:

 

AxisFault

 

faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException

 

faultSubcode:

 

faultString: javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake

 

faultActor:

 

faultNode:

 

faultDetail:

 

{http://xml.apache.org/axis/}stackTrace:javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake

 

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:808)

 

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1112)

 

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1139)

 

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1123)

 

at org.apache.axis.components.net.JSSESocketFactory.create(JSSESocketFactory.java:186)

 

at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)

 

at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)

 

at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:138)

 

at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)

 

at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)

 

at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)

 

at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)

 

at org.apache.axis.client.Call.invokeEngine(Call.java:2784)

 

at org.apache.axis.client.Call.invoke(Call.java:2767)

 

at org.apache.axis.client.Call.invoke(Call.java:2443)

 

at org.apache.axis.client.Call.invoke(Call.java:2366)

 

at org.apache.axis.client.Call.invoke(Call.java:1812)

 

at iControl.LocalLBVirtualServerBindingStub.set_enabled_state(LocalLBVirtualServerBindingStub.java:3586)

 

...

 

Caused by: java.io.EOFException: SSL peer shut down incorrectly

 

at com.sun.net.ssl.internal.ssl.InputRecord.read(InputRecord.java:333)

 

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:789)

 

... 41 more

 

 

Thanks,

 

Vinoth.

 

 

No RepliesBe the first to reply