Hi,

I am using spring httpclient and CommonsHttpMessageSender,

I want to display request time out, if the response take too much of time.

Code snippet:
<bean id="httpClient" class="org.apache.commons.httpclient.HttpClient">
<property name="connectionTimeout" value="120000" />
<property name="timeout" value="10000" />
</bean>

<bean id="wsMarshaller" class="org.springframework.oxm.jaxb.Jaxb2Marshalle r">
<property name="contextPath" value="com.air2web.projects.csm.schema" />
</bean>

<bean id="wsMessageSender" class="org.springframework.ws.transport.http.Commo nsHttpMessageSender" >
<constructor-arg ref="httpClient" />
</bean>

<bean id="wsClient" class="com.projects.csm.WSClient">
<description> WebService client</description>
<property name="endPoint" value="${webService.uri}" />
<property name="marshaller" ref="wsMarshaller" />
<property name="unmarshaller" ref="wsMarshaller" />
<property name="webServiceMessageSender" ref="wsMessageSender" />
</bean>
In java
private int connectionTimeout;
public int getConnectionTimeout() {
return connectionTimeout;
}

public void setConnectionTimeout(int connectionTimeout) {
this.connectionTimeout = connectionTimeout;
}
HttpClient client = new HttpClient();
client.getHttpConnectionManager().getParams().setS oTimeout(new Integer(getConnectionTimeout()));

logger.debug("connections timeout :"+ getConnectionTimeout());
System.out.print("connections timeout :"+ getConnectionTimeout());
How to configure and check whether the request has been timeout or not?

Thanks in Advance
Sridhar