Dear Wiki user, You have subscribed to a wiki page or wiki category on "Jakarta-httpclient Wiki" for change notification.
The following page has been changed by RolandWeber: http://wiki.apache.org/jakarta-httpclient/HttpAsyncThreadingDesign The comment on the change is: application code vs. components code ------------------------------------------------------------------------------ attachment:responsibilities.png [[BR]] - ''add 'close' or 'consume' as a step?'' + ''add 'consume' as a step?'' Steps that necessarily have to be executed by an application thread are shown to the left. Only the application can decide which request should be executed and what to do with the - response. + response. To the right are steps that have to be executed by a background thread. Sending of the request and waiting for the response is there since it is the purpose of HttpAsync to offload such tasks from applications. Notification for incoming responses @@ -55, +55 @@ it is a precondition for notification, as explained below. The steps in the middle column can reasonably be assigned to either side. - - ''To be done:'' - * application code vs. library code - + Assigning the steps to application threads or background threads is one thing. + Another question is the responsibility for the code that gets executed. + Some of the steps in no man's land are implemented by application code, + indicated by the red backdrop. + While the code for the pre- and postprocessing is not necessarily written + by the application developer, it is the application that decides which + interceptors will be executed in these steps. Interceptors are also a + plugin point for application code, therefore the responsibility for what + is done in these two steps is with the application. + It is arguable whether "send request" should be considered application code, + since it can involve a request entity provided by the application developer. + In HttpClient, the request entities included with the package were usually + sufficient, so this step is not marked as executing application code here. The order of the steps from top to bottom is roughly chronological, but some are independent and can be executed in a different order. @@ -80, +89 @@ ''describe the interfaces defined for the HttpAsync API'' + attachment:interfaces.png + + == Blocking IO Implementation == === Initial Design === @@ -91, +103 @@ ''describe a design not chosen for the initial implementation'' + + == Non-blocking IO Implementation == + + ''This is the place for discussing {{{java.nio}}} based dispatchers.'' + --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]