Package org.apache.sling.cta.impl
Class HttpClient3TimeoutTransformer
- java.lang.Object
-
- org.apache.sling.cta.impl.MBeanAwareTimeoutTransformer
-
- org.apache.sling.cta.impl.HttpClient3TimeoutTransformer
-
- All Implemented Interfaces:
java.lang.instrument.ClassFileTransformer
public class HttpClient3TimeoutTransformer extends MBeanAwareTimeoutTransformer
Sets timeouts for HTTP calls done using Apache Commons HttpClient 3.xIt inserts two calls in org.apache.commons.httpclient.params.DefaultHttpParamsFactory.createParams that set default values for http.connection.timeout and http.socket.timeout.
-
-
Constructor Summary
Constructors Constructor Description HttpClient3TimeoutTransformer(long connectTimeoutMillis, long readTimeoutMillis, AgentInfo agentInfoMBean)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected byte[]
doTransformClass(javassist.CtClass cc)
Transform a class that is guaranteed to exist and in scope of this agent instance-
Methods inherited from class org.apache.sling.cta.impl.MBeanAwareTimeoutTransformer
transform
-
-
-
-
Constructor Detail
-
HttpClient3TimeoutTransformer
public HttpClient3TimeoutTransformer(long connectTimeoutMillis, long readTimeoutMillis, AgentInfo agentInfoMBean)
-
-
Method Detail
-
doTransformClass
protected byte[] doTransformClass(javassist.CtClass cc) throws java.lang.Exception
Description copied from class:MBeanAwareTimeoutTransformer
Transform a class that is guaranteed to exist and in scope of this agent instance- Specified by:
doTransformClass
in classMBeanAwareTimeoutTransformer
- Parameters:
cc
- the class- Returns:
- the new class definition
- Throws:
java.lang.Exception
- in case of any problems while transforming
-
-