|
|||||||||
| Home >> All >> [ HTTPClient overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
HTTPClient
Class RetryModule

java.lang.ObjectHTTPClient.RetryModule
- All Implemented Interfaces:
- GlobalConstants, HTTPClientModule, HTTPClientModuleConstants
- class RetryModule
- extends java.lang.Object
- implements HTTPClientModule, GlobalConstants
- extends java.lang.Object
This module handles request retries when a connection closes prematurely. It is triggered by the RetryException thrown by the StreamDemultiplexor.
This module is somewhat unique in that it doesn't strictly limit itself to the HTTPClientModule interface and its return values. That is, it sends request directly using the HTTPConnection.sendRequest() method. This is necessary because this module will not only resend its request but it also resend all other requests in the chain. Also, it rethrows the RetryException in Phase1 to restart the processing of the modules.
- Since:
- V0.3
- Version:
- 0.3-2 18/06/1999
| Field Summary | |
static int |
CD_0
|
static int |
CD_CHUNKED
|
static int |
CD_CLOSE
|
static int |
CD_CONTLEN
|
static int |
CD_HDRS
|
static int |
CD_MP_BR
|
static int |
CD_NONE
Content delimiters |
static boolean |
DebugAll
Debug variables |
static boolean |
DebugAuth
|
static boolean |
DebugConn
|
static boolean |
DebugDemux
|
static boolean |
DebugMods
|
static boolean |
DebugResp
|
static boolean |
DebugSocks
|
static boolean |
DebugURLC
|
static int |
HTTP
possible http protocols we (might) handle |
static int |
HTTP_1_0
some known http versions |
static int |
HTTP_1_1
|
static int |
HTTP_NG
|
static int |
HTTPS
|
static int |
SHTTP
|
| Fields inherited from interface HTTPClient.HTTPClientModuleConstants |
REQ_CONTINUE, REQ_NEWCON_RST, REQ_NEWCON_SND, REQ_RESPONSE, REQ_RESTART, REQ_RETURN, REQ_SHORTCIRC, RSP_CONTINUE, RSP_NEWCON_REQ, RSP_NEWCON_SND, RSP_REQUEST, RSP_RESTART, RSP_SEND, RSP_SHORTCIRC |
| Constructor Summary | |
(package private) |
RetryModule()
|
| Method Summary | |
private void |
addToken(Request req,
java.lang.String hdr,
java.lang.String tok)
Add a token to the given header. |
int |
requestHandler(Request req,
Response[] resp)
Invoked by the HTTPClient. |
void |
responsePhase1Handler(Response resp,
RoRequest roreq)
Invoked by the HTTPClient. |
int |
responsePhase2Handler(Response resp,
Request req)
Invoked by the HTTPClient. |
void |
responsePhase3Handler(Response resp,
RoRequest req)
Invoked by the HTTPClient. |
void |
trailerHandler(Response resp,
RoRequest req)
Invoked by the HTTPClient. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
DebugAll
public static final boolean DebugAll
- Debug variables
- See Also:
- Constant Field Values
DebugConn
public static final boolean DebugConn
- See Also:
- Constant Field Values
DebugResp
public static final boolean DebugResp
- See Also:
- Constant Field Values
DebugDemux
public static final boolean DebugDemux
- See Also:
- Constant Field Values
DebugAuth
public static final boolean DebugAuth
- See Also:
- Constant Field Values
DebugSocks
public static final boolean DebugSocks
- See Also:
- Constant Field Values
DebugMods
public static final boolean DebugMods
- See Also:
- Constant Field Values
DebugURLC
public static final boolean DebugURLC
- See Also:
- Constant Field Values
HTTP
public static final int HTTP
- possible http protocols we (might) handle
- See Also:
- Constant Field Values
HTTPS
public static final int HTTPS
- See Also:
- Constant Field Values
SHTTP
public static final int SHTTP
- See Also:
- Constant Field Values
HTTP_NG
public static final int HTTP_NG
- See Also:
- Constant Field Values
HTTP_1_0
public static final int HTTP_1_0
- some known http versions
- See Also:
- Constant Field Values
HTTP_1_1
public static final int HTTP_1_1
- See Also:
- Constant Field Values
CD_NONE
public static final int CD_NONE
- Content delimiters
- See Also:
- Constant Field Values
CD_HDRS
public static final int CD_HDRS
- See Also:
- Constant Field Values
CD_0
public static final int CD_0
- See Also:
- Constant Field Values
CD_CLOSE
public static final int CD_CLOSE
- See Also:
- Constant Field Values
CD_CONTLEN
public static final int CD_CONTLEN
- See Also:
- Constant Field Values
CD_CHUNKED
public static final int CD_CHUNKED
- See Also:
- Constant Field Values
CD_MP_BR
public static final int CD_MP_BR
- See Also:
- Constant Field Values
| Constructor Detail |
RetryModule
RetryModule()
| Method Detail |
requestHandler
public int requestHandler(Request req, Response[] resp)
- Invoked by the HTTPClient.
- Specified by:
requestHandlerin interfaceHTTPClientModule
responsePhase1Handler
public void responsePhase1Handler(Response resp, RoRequest roreq) throws java.io.IOException, ModuleException
- Invoked by the HTTPClient.
- Specified by:
responsePhase1Handlerin interfaceHTTPClientModule
responsePhase2Handler
public int responsePhase2Handler(Response resp, Request req)
- Invoked by the HTTPClient.
- Specified by:
responsePhase2Handlerin interfaceHTTPClientModule
responsePhase3Handler
public void responsePhase3Handler(Response resp, RoRequest req)
- Invoked by the HTTPClient.
- Specified by:
responsePhase3Handlerin interfaceHTTPClientModule
trailerHandler
public void trailerHandler(Response resp, RoRequest req)
- Invoked by the HTTPClient.
- Specified by:
trailerHandlerin interfaceHTTPClientModule
addToken
private void addToken(Request req, java.lang.String hdr, java.lang.String tok) throws ParseException
- Add a token to the given header. If the header does not exist then
create it with the given token.
|
|||||||||
| Home >> All >> [ HTTPClient overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
HTTPClient.RetryModule