users@jersey.java.net

Re: [Jersey] A Jersey Client doing HTTP Cache

From: Paul Sandoz <Paul.Sandoz_at_oracle.com>
Date: Mon, 11 Oct 2010 12:32:54 +0200

Hi Imran,

I have done an initial set of refactoring based on your patch.

I decided to remove the thread local logic from
DefaultApacheHttpMethodProcessor (renamed to
DefaultApacheHttpMethodExecutor) as that seems to be something
specific to your requirements. So ApacheHttpMethodProcessor (renamed
to ApacheHttpMethodExecutor) only has one method.

 From what i can tell you want to override
DefaultApacheHttpMethodExecutor and override, or reuse,
ApacheHttpClientHandler perhaps delegated.

Note that i moved the configuration in the constructor of
DefaultApacheHttpMethodExecutor to the constructor of
ApacheHttpClientHandler, this is associated with the setting of pre-
emptive authentication and timeouts for configiuration on the Apache
HttpClient and not really specific to the method execution itself.

Please let me know if this is sufficient for you,
Paul.


On Oct 5, 2010, at 11:51 AM, Imran M Yousuf wrote:

> No probs at all :), just wanted to give a reminder :).
>
> Thanks,
>
> Imran
>
> On Tue, Oct 5, 2010 at 3:41 PM, Paul Sandoz <Paul.Sandoz_at_oracle.com>
> wrote:
>>
>> On Oct 5, 2010, at 10:59 AM, Imran M Yousuf wrote:
>>
>>> Hi Paul,
>>>
>>> Any update on the patch :).
>>>
>>
>> No, sorry, at the last minute i took last week off. Still processing
>> email...
>>
>> Paul.
>>
>>> Regards,
>>>
>>> Imran
>>>
>>> On Fri, Sep 10, 2010 at 3:13 PM, Paul Sandoz
>>> <Paul.Sandoz_at_oracle.com>
>>> wrote:
>>>>
>>>> Hi Imran,
>>>>
>>>> Thanks for dong this. It is unlikely i will get around to
>>>> reviewing this
>>>> until after J1 is has finished. Is that OK with you?
>>>>
>>>> Paul.
>>>>
>>>> On Sep 10, 2010, at 10:50 AM, Imran M Yousuf wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I have uploaded a patch for refactoring the client modules so
>>>>> that I
>>>>> can re-use the apache client code in the cacheable client. The
>>>>> patch
>>>>> is attached to the following issue.
>>>>> https://jersey.dev.java.net/issues/show_bug.cgi?id=583
>>>>>
>>>>> After making the change I have already made changes to the
>>>>> cacheable
>>>>> client and now its workable with the new changes. This seems to
>>>>> work
>>>>> fine. The changes are as follows -
>>>>>
>>>>>
>>>>> http://github.com/imyousuf/smart-util/commits/jersey-cache-client-with-apache-client
>>>>> Now the jersey cacheable client will support custom
>>>>> ResponseResolver
>>>>> for HTTPCache4J. Thus the client handler is written such that it
>>>>> works
>>>>> no matter what resolver is set.
>>>>>
>>>>> Waiting eagerly for your feedback.
>>>>>
>>>>> Thank you,
>>>>>
>>>>> --
>>>>> Imran M Yousuf
>>>>> Twitter: @imyousuf - http://twitter.com/imyousuf
>>>>> Blog: http://imyousuf-tech.blogs.smartitengineering.com/
>>>>> Mobile: +880-1711402557
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
>>>>> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
>>>> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Imran M Yousuf
>>> Entrepreneur & CEO
>>> Smart IT Engineering Ltd.
>>> 25/5B, Block F, Haji Chinu Miah Road Bylane
>>> Joint Quarter, Mohammadpur
>>> Dhaka - 1207, Bangladesh
>>> Email: imran_at_smartitengineering.com
>>> Twitter: @imyousuf - http://twitter.com/imyousuf
>>> Blog: http://imyousuf-tech.blogs.smartitengineering.com/
>>> Mobile: +880-1711402557
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
>>> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
>> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>>
>>
>
>
>
> --
> Imran M Yousuf
> Entrepreneur & CEO
> Smart IT Engineering Ltd.
> 25/5B, Block F, Haji Chinu Miah Road Bylane
> Joint Quarter, Mohammadpur
> Dhaka - 1207, Bangladesh
> Email: imran_at_smartitengineering.com
> Twitter: @imyousuf - http://twitter.com/imyousuf
> Blog: http://imyousuf-tech.blogs.smartitengineering.com/
> Mobile: +880-1711402557
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>