com.atlassian.httpclient.base
Class RequestKiller
java.lang.Object
com.atlassian.httpclient.base.RequestKiller
- All Implemented Interfaces:
- java.lang.Runnable, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean
public final class RequestKiller
- extends java.lang.Object
- implements java.lang.Runnable, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean
A request killer for ensuring a request doesn't take too long. While connection and socket
timeouts deal with waiting for an TCP connection and a long delay in new content, respectively,
this thread kills requests that may be trickling content down in such a way that doesn't trip
the socket timeout.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RequestKiller
public RequestKiller()
registerRequest
public void registerRequest(org.apache.http.client.methods.AbortableHttpRequest request,
int secondsToLive)
afterPropertiesSet
public void afterPropertiesSet()
throws java.lang.Exception
- Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
- Throws:
java.lang.Exception
destroy
public void destroy()
throws java.lang.Exception
- Specified by:
destroy in interface org.springframework.beans.factory.DisposableBean
- Throws:
java.lang.Exception
run
public void run()
- Specified by:
run in interface java.lang.Runnable
completedRequest
public void completedRequest(org.apache.http.client.methods.AbortableHttpRequest request)
Copyright © 2012 Atlassian. All Rights Reserved.