You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by Philippe Mouawad <ph...@gmail.com> on 2012/02/15 23:30:03 UTC

Issues 52618 and 52674

Hello Sebb, Milamber, Rainer,
Did you have time to look at:

   - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>

Do you think patch should be applied ?


Also I would like to have your opinion regarding :

   - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>

I started an implementation, should I provide a patch or commit it directly
?

My idea is the following:

   - Either introduce 2 interfaces:


   1. SamplerFactory with following method:
         1. createSampler(String contentType) => Called in
         HttpRequestHdr#getSampler()
      2. SamplerCustomizer with following method:
         1. customizeSampler(HttpSamplerBase sampler) => Called in
         HttpRequestHdr#getSampler()
         2. fillBody(byte[] rawPostBody) => Called in
         HttpRequestHdr#getSampler()


   - Or introduce only one SamplerProvider:
      - createSampler(String contentType) => Called in
      HttpRequestHdr#getSampler()
      - customizeSampler(HttpSamplerBase sampler) => Called in
      HttpRequestHdr#getSampler()
      - fillBody(byte[] rawPostBody) => Called in
      HttpRequestHdr#getSampler():
         - Default implementation would do what is done today inside if
         ((!HTTPConstants.CONNECT.equals(getMethod())) && (!HTTPConstants.
         GET.equals(method))) {
         - Other protocols would handle it another way

-- 
Regards.
Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by sebb <se...@gmail.com>.
On 3 March 2012 00:33, Philippe Mouawad <ph...@gmail.com> wrote:
> On Sat, Mar 3, 2012 at 1:20 AM, sebb <se...@gmail.com> wrote:
>
>> On 3 March 2012 00:14, Philippe Mouawad <ph...@gmail.com>
>> wrote:
>> > Hello Sebb,
>> > Thanks very much for taking some time to review.
>> >
>> > Regarding docs usage update, as there is no impact at all on usage is
>> there
>> > something to update ?
>>
>>
>> http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Proxy_Server
>>
>> I added some text to just say it's possible to implement non native
> protocols. Not sure it's useful.
>
>
>> > A place to update would be the document jmeter_tutorial.pdf  linked under
>> > "Extending JMeter".
>> > What's the official way to update it ? Using Open Office and editing
>> > jmeter_tutorial_mike.sxw or is there a better way ?
>>
>> Yes, edit the sxw file.
>>
> I will do it within the next coming days, now I go to bed :-)

Not urgent, so long as it's done before the next release.

>
>>
>> > Thanks
>> > Regards
>> > Philippe
>> >
>> > On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:
>> >
>> >> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
>> >> wrote:
>> >> > Hello,
>> >> > In french there is a quotation that says "Qui ne dit mot consent" :-)
>> >>
>> >> [That's called "lazy consensus" here, at least when applied to votes.]
>> >>
>> >> > Does it mean you're OK for me committing the issue
>> >> > 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
>> >> > want to take some more time to review ?
>> >>
>> >> Just had another look.
>> >>
>> >> As far as I can tell, the changes only affect the Proxy code.
>> >> In which case, it cannot affect existing test plans; the worst that
>> >> can happen is that the Proxy behaves differently from before.
>> >> I don't think that would matter much.
>> >>
>> >> I don't object to the code being committed.
>> >>
>> >> Please ensure that the Proxy usage docs are updated as necessary.
>> >>
>> >> > Thank you all.
>> >> > Regards
>> >> > Philippe
>> >> >
>> >> > On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
>> >> > philippe.mouawad@gmail.com> wrote:
>> >> >
>> >> >> Hello,
>> >> >> To clarify a little bit what this enhancement brings:
>> >> >>
>> >> >> Today the Proxy can record standard HTTP sessions that are textual,
>> see
>> >> >> the Mail of 6 feb 2012
>> >> >> "It was designed for recording standard HTTP sessions; these are not
>> >> >> binary"
>> >> >> And particularly Issue 49039
>> >> >>
>> >> >>
>> >> >> Although it is limited to Textual HTTP Sessions, lot of work in it
>> can
>> >> be
>> >> >> reused to record AMF Sessions , Silverlight sessions or other binary
>> >> >> protocols.
>> >> >>
>> >> >> The idea behind the enhancement is to propose the following:
>> >> >>
>> >> >>    - Plugin implementor will be able by implementing a SampleCreator
>> >> >>    subclass to reuse 90% of proxy feature without duplicating lot of
>> >> code:
>> >> >>       - All Header work
>> >> >>       - Sampler transmission to a Target once it's created ,
>> >> >>       - ie, all the work done in patched HttpRequestHdr which is big
>> +
>> >> >>       the ability to customize each of the methods in
>> >> DefaultSamplerCreator (as
>> >> >>       Struts Base class was build for example)
>> >> >>
>> >> >> Another idea is to be able to customize the created Sampler, a direct
>> >> use
>> >> >> I see is for example is during a recording of a JSON, GWT or REST
>> >> >> protocols, I as a user had to go on each sampler after recording and
>> >> switch
>> >> >> to RAW POST BODY (which means 40 clicks for 20 samplers), with
>> current
>> >> >> enhancement  I can just subclass DefaultSamplerCreator and register
>> it
>> >> for
>> >> >> GWT Content type and just set the property to switch it to RAW POST
>> >> BODY.
>> >> >>
>> >> >> Hope it's clearer.
>> >> >> Regards
>> >> >> Philippe
>> >> >>
>> >> >> Today the Proxy feature can only be used to record HTTP Textual
>> >> >>
>> >> >> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
>> >> >> philippe.mouawad@gmail.com> wrote:
>> >> >>
>> >> >>> Hello,
>> >> >>> I submitted a patch for 52674<
>> >> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>> >> >>> Hope you can have a look at it soon.
>> >> >>>
>> >> >>> I didn't update Tests yet, if you think it's OK then I will update
>> >> them.
>> >> >>>
>> >> >>> Regards
>> >> >>> Philippe
>> >> >>>
>> >> >>>
>> >> >>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>> >> >>> philippe.mouawad@gmail.com> wrote:
>> >> >>>
>> >> >>>> Hello Sebb, Milamber, Rainer,
>> >> >>>> Did you have time to look at:
>> >> >>>>
>> >> >>>>    - 52618 <
>> https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>> >> >>>>
>> >> >>>> Do you think patch should be applied ?
>> >> >>>>
>> >> >>>>
>> >> >>>> Also I would like to have your opinion regarding :
>> >> >>>>
>> >> >>>>    - 52674 <
>> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>> >> >>>>
>> >> >>>> I started an implementation, should I provide a patch or commit it
>> >> >>>> directly ?
>> >> >>>>
>> >> >>>> My idea is the following:
>> >> >>>>
>> >> >>>>    - Either introduce 2 interfaces:
>> >> >>>>
>> >> >>>>
>> >> >>>>    1. SamplerFactory with following method:
>> >> >>>>          1. createSampler(String contentType) => Called in
>> >> >>>>          HttpRequestHdr#getSampler()
>> >> >>>>       2. SamplerCustomizer with following method:
>> >> >>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>> >> >>>>          HttpRequestHdr#getSampler()
>> >> >>>>          2. fillBody(byte[] rawPostBody) => Called in
>> >> >>>>          HttpRequestHdr#getSampler()
>> >> >>>>
>> >> >>>>
>> >> >>>>    - Or introduce only one SamplerProvider:
>> >> >>>>       - createSampler(String contentType) => Called in
>> >> >>>>       HttpRequestHdr#getSampler()
>> >> >>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>> >> >>>>       HttpRequestHdr#getSampler()
>> >> >>>>       - fillBody(byte[] rawPostBody) => Called in
>> >> >>>>       HttpRequestHdr#getSampler():
>> >> >>>>          - Default implementation would do what is done today
>> inside
>> >> if
>> >> >>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>> >> >>>>          (!HTTPConstants.GET.equals(method))) {
>> >> >>>>          - Other protocols would handle it another way
>> >> >>>>
>> >> >>>> --
>> >> >>>> Regards.
>> >> >>>> Philippe Mouawad.
>> >> >>>>
>> >> >>>>
>> >> >>>>
>> >> >>>>
>> >> >>>
>> >> >>>
>> >> >>> --
>> >> >>> Cordialement.
>> >> >>> Philippe Mouawad.
>> >> >>>
>> >> >>>
>> >> >>>
>> >> >>>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Cordialement.
>> >> >> Philippe Mouawad.
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >
>> >> >
>> >> > --
>> >> > Cordialement.
>> >> > Philippe Mouawad.
>> >>
>> >
>> >
>> >
>> > --
>> > Cordialement.
>> > Philippe Mouawad.
>>
>
>
>
> --
> Cordialement.
> Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by Philippe Mouawad <ph...@gmail.com>.
On Sat, Mar 3, 2012 at 1:20 AM, sebb <se...@gmail.com> wrote:

> On 3 March 2012 00:14, Philippe Mouawad <ph...@gmail.com>
> wrote:
> > Hello Sebb,
> > Thanks very much for taking some time to review.
> >
> > Regarding docs usage update, as there is no impact at all on usage is
> there
> > something to update ?
>
>
> http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Proxy_Server
>
> I added some text to just say it's possible to implement non native
protocols. Not sure it's useful.


> > A place to update would be the document jmeter_tutorial.pdf  linked under
> > "Extending JMeter".
> > What's the official way to update it ? Using Open Office and editing
> > jmeter_tutorial_mike.sxw or is there a better way ?
>
> Yes, edit the sxw file.
>
I will do it within the next coming days, now I go to bed :-)


>
> > Thanks
> > Regards
> > Philippe
> >
> > On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:
> >
> >> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
> >> wrote:
> >> > Hello,
> >> > In french there is a quotation that says "Qui ne dit mot consent" :-)
> >>
> >> [That's called "lazy consensus" here, at least when applied to votes.]
> >>
> >> > Does it mean you're OK for me committing the issue
> >> > 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
> >> > want to take some more time to review ?
> >>
> >> Just had another look.
> >>
> >> As far as I can tell, the changes only affect the Proxy code.
> >> In which case, it cannot affect existing test plans; the worst that
> >> can happen is that the Proxy behaves differently from before.
> >> I don't think that would matter much.
> >>
> >> I don't object to the code being committed.
> >>
> >> Please ensure that the Proxy usage docs are updated as necessary.
> >>
> >> > Thank you all.
> >> > Regards
> >> > Philippe
> >> >
> >> > On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
> >> > philippe.mouawad@gmail.com> wrote:
> >> >
> >> >> Hello,
> >> >> To clarify a little bit what this enhancement brings:
> >> >>
> >> >> Today the Proxy can record standard HTTP sessions that are textual,
> see
> >> >> the Mail of 6 feb 2012
> >> >> "It was designed for recording standard HTTP sessions; these are not
> >> >> binary"
> >> >> And particularly Issue 49039
> >> >>
> >> >>
> >> >> Although it is limited to Textual HTTP Sessions, lot of work in it
> can
> >> be
> >> >> reused to record AMF Sessions , Silverlight sessions or other binary
> >> >> protocols.
> >> >>
> >> >> The idea behind the enhancement is to propose the following:
> >> >>
> >> >>    - Plugin implementor will be able by implementing a SampleCreator
> >> >>    subclass to reuse 90% of proxy feature without duplicating lot of
> >> code:
> >> >>       - All Header work
> >> >>       - Sampler transmission to a Target once it's created ,
> >> >>       - ie, all the work done in patched HttpRequestHdr which is big
> +
> >> >>       the ability to customize each of the methods in
> >> DefaultSamplerCreator (as
> >> >>       Struts Base class was build for example)
> >> >>
> >> >> Another idea is to be able to customize the created Sampler, a direct
> >> use
> >> >> I see is for example is during a recording of a JSON, GWT or REST
> >> >> protocols, I as a user had to go on each sampler after recording and
> >> switch
> >> >> to RAW POST BODY (which means 40 clicks for 20 samplers), with
> current
> >> >> enhancement  I can just subclass DefaultSamplerCreator and register
> it
> >> for
> >> >> GWT Content type and just set the property to switch it to RAW POST
> >> BODY.
> >> >>
> >> >> Hope it's clearer.
> >> >> Regards
> >> >> Philippe
> >> >>
> >> >> Today the Proxy feature can only be used to record HTTP Textual
> >> >>
> >> >> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
> >> >> philippe.mouawad@gmail.com> wrote:
> >> >>
> >> >>> Hello,
> >> >>> I submitted a patch for 52674<
> >> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >> >>> Hope you can have a look at it soon.
> >> >>>
> >> >>> I didn't update Tests yet, if you think it's OK then I will update
> >> them.
> >> >>>
> >> >>> Regards
> >> >>> Philippe
> >> >>>
> >> >>>
> >> >>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
> >> >>> philippe.mouawad@gmail.com> wrote:
> >> >>>
> >> >>>> Hello Sebb, Milamber, Rainer,
> >> >>>> Did you have time to look at:
> >> >>>>
> >> >>>>    - 52618 <
> https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
> >> >>>>
> >> >>>> Do you think patch should be applied ?
> >> >>>>
> >> >>>>
> >> >>>> Also I would like to have your opinion regarding :
> >> >>>>
> >> >>>>    - 52674 <
> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >> >>>>
> >> >>>> I started an implementation, should I provide a patch or commit it
> >> >>>> directly ?
> >> >>>>
> >> >>>> My idea is the following:
> >> >>>>
> >> >>>>    - Either introduce 2 interfaces:
> >> >>>>
> >> >>>>
> >> >>>>    1. SamplerFactory with following method:
> >> >>>>          1. createSampler(String contentType) => Called in
> >> >>>>          HttpRequestHdr#getSampler()
> >> >>>>       2. SamplerCustomizer with following method:
> >> >>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
> >> >>>>          HttpRequestHdr#getSampler()
> >> >>>>          2. fillBody(byte[] rawPostBody) => Called in
> >> >>>>          HttpRequestHdr#getSampler()
> >> >>>>
> >> >>>>
> >> >>>>    - Or introduce only one SamplerProvider:
> >> >>>>       - createSampler(String contentType) => Called in
> >> >>>>       HttpRequestHdr#getSampler()
> >> >>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
> >> >>>>       HttpRequestHdr#getSampler()
> >> >>>>       - fillBody(byte[] rawPostBody) => Called in
> >> >>>>       HttpRequestHdr#getSampler():
> >> >>>>          - Default implementation would do what is done today
> inside
> >> if
> >> >>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
> >> >>>>          (!HTTPConstants.GET.equals(method))) {
> >> >>>>          - Other protocols would handle it another way
> >> >>>>
> >> >>>> --
> >> >>>> Regards.
> >> >>>> Philippe Mouawad.
> >> >>>>
> >> >>>>
> >> >>>>
> >> >>>>
> >> >>>
> >> >>>
> >> >>> --
> >> >>> Cordialement.
> >> >>> Philippe Mouawad.
> >> >>>
> >> >>>
> >> >>>
> >> >>>
> >> >>
> >> >>
> >> >> --
> >> >> Cordialement.
> >> >> Philippe Mouawad.
> >> >>
> >> >>
> >> >>
> >> >>
> >> >
> >> >
> >> > --
> >> > Cordialement.
> >> > Philippe Mouawad.
> >>
> >
> >
> >
> > --
> > Cordialement.
> > Philippe Mouawad.
>



-- 
Cordialement.
Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by sebb <se...@gmail.com>.
On 3 March 2012 10:27, Milamber <mi...@apache.org> wrote:
>
>
> Le 03/03/2012 00:20, sebb a ecrit :
>> On 3 March 2012 00:14, Philippe Mouawad <ph...@gmail.com> wrote:
>>
>>> Hello Sebb,
>>> Thanks very much for taking some time to review.
>>>
>>> Regarding docs usage update, as there is no impact at all on usage is there
>>> something to update ?
>>>
>> http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Proxy_Server
>>
>>
>>> A place to update would be the document jmeter_tutorial.pdf  linked under
>>> "Extending JMeter".
>>> What's the official way to update it ? Using Open Office and editing
>>> jmeter_tutorial_mike.sxw or is there a better way ?
>>>
>> Yes, edit the sxw file.
>>
>
> Perhaps, convert it to OpenDocument (.odt) standardized file format (new
> default format for OpenOffice and readable directly by MS Word 2007SP2+)

Yes, that would be better.

> Milamber
>
>>
>>> Thanks
>>> Regards
>>> Philippe
>>>
>>> On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:
>>>
>>>
>>>> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
>>>> wrote:
>>>>
>>>>> Hello,
>>>>> In french there is a quotation that says "Qui ne dit mot consent" :-)
>>>>>
>>>> [That's called "lazy consensus" here, at least when applied to votes.]
>>>>
>>>>
>>>>> Does it mean you're OK for me committing the issue
>>>>> 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
>>>>> want to take some more time to review ?
>>>>>
>>>> Just had another look.
>>>>
>>>> As far as I can tell, the changes only affect the Proxy code.
>>>> In which case, it cannot affect existing test plans; the worst that
>>>> can happen is that the Proxy behaves differently from before.
>>>> I don't think that would matter much.
>>>>
>>>> I don't object to the code being committed.
>>>>
>>>> Please ensure that the Proxy usage docs are updated as necessary.
>>>>
>>>>
>>>>> Thank you all.
>>>>> Regards
>>>>> Philippe
>>>>>
>>>>> On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
>>>>> philippe.mouawad@gmail.com> wrote:
>>>>>
>>>>>
>>>>>> Hello,
>>>>>> To clarify a little bit what this enhancement brings:
>>>>>>
>>>>>> Today the Proxy can record standard HTTP sessions that are textual, see
>>>>>> the Mail of 6 feb 2012
>>>>>> "It was designed for recording standard HTTP sessions; these are not
>>>>>> binary"
>>>>>> And particularly Issue 49039
>>>>>>
>>>>>>
>>>>>> Although it is limited to Textual HTTP Sessions, lot of work in it can
>>>>>>
>>>> be
>>>>
>>>>>> reused to record AMF Sessions , Silverlight sessions or other binary
>>>>>> protocols.
>>>>>>
>>>>>> The idea behind the enhancement is to propose the following:
>>>>>>
>>>>>>    - Plugin implementor will be able by implementing a SampleCreator
>>>>>>    subclass to reuse 90% of proxy feature without duplicating lot of
>>>>>>
>>>> code:
>>>>
>>>>>>       - All Header work
>>>>>>       - Sampler transmission to a Target once it's created ,
>>>>>>       - ie, all the work done in patched HttpRequestHdr which is big +
>>>>>>       the ability to customize each of the methods in
>>>>>>
>>>> DefaultSamplerCreator (as
>>>>
>>>>>>       Struts Base class was build for example)
>>>>>>
>>>>>> Another idea is to be able to customize the created Sampler, a direct
>>>>>>
>>>> use
>>>>
>>>>>> I see is for example is during a recording of a JSON, GWT or REST
>>>>>> protocols, I as a user had to go on each sampler after recording and
>>>>>>
>>>> switch
>>>>
>>>>>> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
>>>>>> enhancement  I can just subclass DefaultSamplerCreator and register it
>>>>>>
>>>> for
>>>>
>>>>>> GWT Content type and just set the property to switch it to RAW POST
>>>>>>
>>>> BODY.
>>>>
>>>>>> Hope it's clearer.
>>>>>> Regards
>>>>>> Philippe
>>>>>>
>>>>>> Today the Proxy feature can only be used to record HTTP Textual
>>>>>>
>>>>>> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
>>>>>> philippe.mouawad@gmail.com> wrote:
>>>>>>
>>>>>>
>>>>>>> Hello,
>>>>>>> I submitted a patch for 52674<
>>>>>>>
>>>> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>>
>>>>>>> Hope you can have a look at it soon.
>>>>>>>
>>>>>>> I didn't update Tests yet, if you think it's OK then I will update
>>>>>>>
>>>> them.
>>>>
>>>>>>> Regards
>>>>>>> Philippe
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>>>>>>> philippe.mouawad@gmail.com> wrote:
>>>>>>>
>>>>>>>
>>>>>>>> Hello Sebb, Milamber, Rainer,
>>>>>>>> Did you have time to look at:
>>>>>>>>
>>>>>>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>>>>>>>>
>>>>>>>> Do you think patch should be applied ?
>>>>>>>>
>>>>>>>>
>>>>>>>> Also I would like to have your opinion regarding :
>>>>>>>>
>>>>>>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>>>>>>
>>>>>>>> I started an implementation, should I provide a patch or commit it
>>>>>>>> directly ?
>>>>>>>>
>>>>>>>> My idea is the following:
>>>>>>>>
>>>>>>>>    - Either introduce 2 interfaces:
>>>>>>>>
>>>>>>>>
>>>>>>>>    1. SamplerFactory with following method:
>>>>>>>>          1. createSampler(String contentType) => Called in
>>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>>       2. SamplerCustomizer with following method:
>>>>>>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>>          2. fillBody(byte[] rawPostBody) => Called in
>>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>>
>>>>>>>>
>>>>>>>>    - Or introduce only one SamplerProvider:
>>>>>>>>       - createSampler(String contentType) => Called in
>>>>>>>>       HttpRequestHdr#getSampler()
>>>>>>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>>>>>>>>       HttpRequestHdr#getSampler()
>>>>>>>>       - fillBody(byte[] rawPostBody) => Called in
>>>>>>>>       HttpRequestHdr#getSampler():
>>>>>>>>          - Default implementation would do what is done today inside
>>>>>>>>
>>>> if
>>>>
>>>>>>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>>>>>>>>          (!HTTPConstants.GET.equals(method))) {
>>>>>>>>          - Other protocols would handle it another way
>>>>>>>>
>>>>>>>> --
>>>>>>>> Regards.
>>>>>>>> Philippe Mouawad.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Cordialement.
>>>>>>> Philippe Mouawad.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> Cordialement.
>>>>>> Philippe Mouawad.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>> --
>>>>> Cordialement.
>>>>> Philippe Mouawad.
>>>>>
>>>>
>>>
>>>
>>> --
>>> Cordialement.
>>> Philippe Mouawad.
>>>
>>
>

Re: Issues 52618 and 52674

Posted by Milamber <mi...@apache.org>.

Le 03/03/2012 00:20, sebb a ecrit :
> On 3 March 2012 00:14, Philippe Mouawad <ph...@gmail.com> wrote:
>   
>> Hello Sebb,
>> Thanks very much for taking some time to review.
>>
>> Regarding docs usage update, as there is no impact at all on usage is there
>> something to update ?
>>     
> http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Proxy_Server
>
>   
>> A place to update would be the document jmeter_tutorial.pdf  linked under
>> "Extending JMeter".
>> What's the official way to update it ? Using Open Office and editing
>> jmeter_tutorial_mike.sxw or is there a better way ?
>>     
> Yes, edit the sxw file.
>   

Perhaps, convert it to OpenDocument (.odt) standardized file format (new
default format for OpenOffice and readable directly by MS Word 2007SP2+)

Milamber

>   
>> Thanks
>> Regards
>> Philippe
>>
>> On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:
>>
>>     
>>> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
>>> wrote:
>>>       
>>>> Hello,
>>>> In french there is a quotation that says "Qui ne dit mot consent" :-)
>>>>         
>>> [That's called "lazy consensus" here, at least when applied to votes.]
>>>
>>>       
>>>> Does it mean you're OK for me committing the issue
>>>> 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
>>>> want to take some more time to review ?
>>>>         
>>> Just had another look.
>>>
>>> As far as I can tell, the changes only affect the Proxy code.
>>> In which case, it cannot affect existing test plans; the worst that
>>> can happen is that the Proxy behaves differently from before.
>>> I don't think that would matter much.
>>>
>>> I don't object to the code being committed.
>>>
>>> Please ensure that the Proxy usage docs are updated as necessary.
>>>
>>>       
>>>> Thank you all.
>>>> Regards
>>>> Philippe
>>>>
>>>> On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
>>>> philippe.mouawad@gmail.com> wrote:
>>>>
>>>>         
>>>>> Hello,
>>>>> To clarify a little bit what this enhancement brings:
>>>>>
>>>>> Today the Proxy can record standard HTTP sessions that are textual, see
>>>>> the Mail of 6 feb 2012
>>>>> "It was designed for recording standard HTTP sessions; these are not
>>>>> binary"
>>>>> And particularly Issue 49039
>>>>>
>>>>>
>>>>> Although it is limited to Textual HTTP Sessions, lot of work in it can
>>>>>           
>>> be
>>>       
>>>>> reused to record AMF Sessions , Silverlight sessions or other binary
>>>>> protocols.
>>>>>
>>>>> The idea behind the enhancement is to propose the following:
>>>>>
>>>>>    - Plugin implementor will be able by implementing a SampleCreator
>>>>>    subclass to reuse 90% of proxy feature without duplicating lot of
>>>>>           
>>> code:
>>>       
>>>>>       - All Header work
>>>>>       - Sampler transmission to a Target once it's created ,
>>>>>       - ie, all the work done in patched HttpRequestHdr which is big +
>>>>>       the ability to customize each of the methods in
>>>>>           
>>> DefaultSamplerCreator (as
>>>       
>>>>>       Struts Base class was build for example)
>>>>>
>>>>> Another idea is to be able to customize the created Sampler, a direct
>>>>>           
>>> use
>>>       
>>>>> I see is for example is during a recording of a JSON, GWT or REST
>>>>> protocols, I as a user had to go on each sampler after recording and
>>>>>           
>>> switch
>>>       
>>>>> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
>>>>> enhancement  I can just subclass DefaultSamplerCreator and register it
>>>>>           
>>> for
>>>       
>>>>> GWT Content type and just set the property to switch it to RAW POST
>>>>>           
>>> BODY.
>>>       
>>>>> Hope it's clearer.
>>>>> Regards
>>>>> Philippe
>>>>>
>>>>> Today the Proxy feature can only be used to record HTTP Textual
>>>>>
>>>>> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
>>>>> philippe.mouawad@gmail.com> wrote:
>>>>>
>>>>>           
>>>>>> Hello,
>>>>>> I submitted a patch for 52674<
>>>>>>             
>>> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>       
>>>>>> Hope you can have a look at it soon.
>>>>>>
>>>>>> I didn't update Tests yet, if you think it's OK then I will update
>>>>>>             
>>> them.
>>>       
>>>>>> Regards
>>>>>> Philippe
>>>>>>
>>>>>>
>>>>>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>>>>>> philippe.mouawad@gmail.com> wrote:
>>>>>>
>>>>>>             
>>>>>>> Hello Sebb, Milamber, Rainer,
>>>>>>> Did you have time to look at:
>>>>>>>
>>>>>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>>>>>>>
>>>>>>> Do you think patch should be applied ?
>>>>>>>
>>>>>>>
>>>>>>> Also I would like to have your opinion regarding :
>>>>>>>
>>>>>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>>>>>
>>>>>>> I started an implementation, should I provide a patch or commit it
>>>>>>> directly ?
>>>>>>>
>>>>>>> My idea is the following:
>>>>>>>
>>>>>>>    - Either introduce 2 interfaces:
>>>>>>>
>>>>>>>
>>>>>>>    1. SamplerFactory with following method:
>>>>>>>          1. createSampler(String contentType) => Called in
>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>       2. SamplerCustomizer with following method:
>>>>>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>          2. fillBody(byte[] rawPostBody) => Called in
>>>>>>>          HttpRequestHdr#getSampler()
>>>>>>>
>>>>>>>
>>>>>>>    - Or introduce only one SamplerProvider:
>>>>>>>       - createSampler(String contentType) => Called in
>>>>>>>       HttpRequestHdr#getSampler()
>>>>>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>>>>>>>       HttpRequestHdr#getSampler()
>>>>>>>       - fillBody(byte[] rawPostBody) => Called in
>>>>>>>       HttpRequestHdr#getSampler():
>>>>>>>          - Default implementation would do what is done today inside
>>>>>>>               
>>> if
>>>       
>>>>>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>>>>>>>          (!HTTPConstants.GET.equals(method))) {
>>>>>>>          - Other protocols would handle it another way
>>>>>>>
>>>>>>> --
>>>>>>> Regards.
>>>>>>> Philippe Mouawad.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>               
>>>>>>
>>>>>> --
>>>>>> Cordialement.
>>>>>> Philippe Mouawad.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>             
>>>>>
>>>>> --
>>>>> Cordialement.
>>>>> Philippe Mouawad.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>
>>>> --
>>>> Cordialement.
>>>> Philippe Mouawad.
>>>>         
>>>       
>>
>>
>> --
>> Cordialement.
>> Philippe Mouawad.
>>     
>   


Re: Issues 52618 and 52674

Posted by sebb <se...@gmail.com>.
On 3 March 2012 00:14, Philippe Mouawad <ph...@gmail.com> wrote:
> Hello Sebb,
> Thanks very much for taking some time to review.
>
> Regarding docs usage update, as there is no impact at all on usage is there
> something to update ?

http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Proxy_Server

> A place to update would be the document jmeter_tutorial.pdf  linked under
> "Extending JMeter".
> What's the official way to update it ? Using Open Office and editing
> jmeter_tutorial_mike.sxw or is there a better way ?

Yes, edit the sxw file.

> Thanks
> Regards
> Philippe
>
> On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:
>
>> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
>> wrote:
>> > Hello,
>> > In french there is a quotation that says "Qui ne dit mot consent" :-)
>>
>> [That's called "lazy consensus" here, at least when applied to votes.]
>>
>> > Does it mean you're OK for me committing the issue
>> > 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
>> > want to take some more time to review ?
>>
>> Just had another look.
>>
>> As far as I can tell, the changes only affect the Proxy code.
>> In which case, it cannot affect existing test plans; the worst that
>> can happen is that the Proxy behaves differently from before.
>> I don't think that would matter much.
>>
>> I don't object to the code being committed.
>>
>> Please ensure that the Proxy usage docs are updated as necessary.
>>
>> > Thank you all.
>> > Regards
>> > Philippe
>> >
>> > On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
>> > philippe.mouawad@gmail.com> wrote:
>> >
>> >> Hello,
>> >> To clarify a little bit what this enhancement brings:
>> >>
>> >> Today the Proxy can record standard HTTP sessions that are textual, see
>> >> the Mail of 6 feb 2012
>> >> "It was designed for recording standard HTTP sessions; these are not
>> >> binary"
>> >> And particularly Issue 49039
>> >>
>> >>
>> >> Although it is limited to Textual HTTP Sessions, lot of work in it can
>> be
>> >> reused to record AMF Sessions , Silverlight sessions or other binary
>> >> protocols.
>> >>
>> >> The idea behind the enhancement is to propose the following:
>> >>
>> >>    - Plugin implementor will be able by implementing a SampleCreator
>> >>    subclass to reuse 90% of proxy feature without duplicating lot of
>> code:
>> >>       - All Header work
>> >>       - Sampler transmission to a Target once it's created ,
>> >>       - ie, all the work done in patched HttpRequestHdr which is big +
>> >>       the ability to customize each of the methods in
>> DefaultSamplerCreator (as
>> >>       Struts Base class was build for example)
>> >>
>> >> Another idea is to be able to customize the created Sampler, a direct
>> use
>> >> I see is for example is during a recording of a JSON, GWT or REST
>> >> protocols, I as a user had to go on each sampler after recording and
>> switch
>> >> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
>> >> enhancement  I can just subclass DefaultSamplerCreator and register it
>> for
>> >> GWT Content type and just set the property to switch it to RAW POST
>> BODY.
>> >>
>> >> Hope it's clearer.
>> >> Regards
>> >> Philippe
>> >>
>> >> Today the Proxy feature can only be used to record HTTP Textual
>> >>
>> >> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
>> >> philippe.mouawad@gmail.com> wrote:
>> >>
>> >>> Hello,
>> >>> I submitted a patch for 52674<
>> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>> >>> Hope you can have a look at it soon.
>> >>>
>> >>> I didn't update Tests yet, if you think it's OK then I will update
>> them.
>> >>>
>> >>> Regards
>> >>> Philippe
>> >>>
>> >>>
>> >>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>> >>> philippe.mouawad@gmail.com> wrote:
>> >>>
>> >>>> Hello Sebb, Milamber, Rainer,
>> >>>> Did you have time to look at:
>> >>>>
>> >>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>> >>>>
>> >>>> Do you think patch should be applied ?
>> >>>>
>> >>>>
>> >>>> Also I would like to have your opinion regarding :
>> >>>>
>> >>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>> >>>>
>> >>>> I started an implementation, should I provide a patch or commit it
>> >>>> directly ?
>> >>>>
>> >>>> My idea is the following:
>> >>>>
>> >>>>    - Either introduce 2 interfaces:
>> >>>>
>> >>>>
>> >>>>    1. SamplerFactory with following method:
>> >>>>          1. createSampler(String contentType) => Called in
>> >>>>          HttpRequestHdr#getSampler()
>> >>>>       2. SamplerCustomizer with following method:
>> >>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>> >>>>          HttpRequestHdr#getSampler()
>> >>>>          2. fillBody(byte[] rawPostBody) => Called in
>> >>>>          HttpRequestHdr#getSampler()
>> >>>>
>> >>>>
>> >>>>    - Or introduce only one SamplerProvider:
>> >>>>       - createSampler(String contentType) => Called in
>> >>>>       HttpRequestHdr#getSampler()
>> >>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>> >>>>       HttpRequestHdr#getSampler()
>> >>>>       - fillBody(byte[] rawPostBody) => Called in
>> >>>>       HttpRequestHdr#getSampler():
>> >>>>          - Default implementation would do what is done today inside
>> if
>> >>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>> >>>>          (!HTTPConstants.GET.equals(method))) {
>> >>>>          - Other protocols would handle it another way
>> >>>>
>> >>>> --
>> >>>> Regards.
>> >>>> Philippe Mouawad.
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>> --
>> >>> Cordialement.
>> >>> Philippe Mouawad.
>> >>>
>> >>>
>> >>>
>> >>>
>> >>
>> >>
>> >> --
>> >> Cordialement.
>> >> Philippe Mouawad.
>> >>
>> >>
>> >>
>> >>
>> >
>> >
>> > --
>> > Cordialement.
>> > Philippe Mouawad.
>>
>
>
>
> --
> Cordialement.
> Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello Sebb,
Thanks very much for taking some time to review.

Regarding docs usage update, as there is no impact at all on usage is there
something to update ?

A place to update would be the document jmeter_tutorial.pdf  linked under
"Extending JMeter".
What's the official way to update it ? Using Open Office and editing
jmeter_tutorial_mike.sxw or is there a better way ?

Thanks
Regards
Philippe

On Fri, Mar 2, 2012 at 11:28 PM, sebb <se...@gmail.com> wrote:

> On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com>
> wrote:
> > Hello,
> > In french there is a quotation that says "Qui ne dit mot consent" :-)
>
> [That's called "lazy consensus" here, at least when applied to votes.]
>
> > Does it mean you're OK for me committing the issue
> > 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
> > want to take some more time to review ?
>
> Just had another look.
>
> As far as I can tell, the changes only affect the Proxy code.
> In which case, it cannot affect existing test plans; the worst that
> can happen is that the Proxy behaves differently from before.
> I don't think that would matter much.
>
> I don't object to the code being committed.
>
> Please ensure that the Proxy usage docs are updated as necessary.
>
> > Thank you all.
> > Regards
> > Philippe
> >
> > On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
> > philippe.mouawad@gmail.com> wrote:
> >
> >> Hello,
> >> To clarify a little bit what this enhancement brings:
> >>
> >> Today the Proxy can record standard HTTP sessions that are textual, see
> >> the Mail of 6 feb 2012
> >> "It was designed for recording standard HTTP sessions; these are not
> >> binary"
> >> And particularly Issue 49039
> >>
> >>
> >> Although it is limited to Textual HTTP Sessions, lot of work in it can
> be
> >> reused to record AMF Sessions , Silverlight sessions or other binary
> >> protocols.
> >>
> >> The idea behind the enhancement is to propose the following:
> >>
> >>    - Plugin implementor will be able by implementing a SampleCreator
> >>    subclass to reuse 90% of proxy feature without duplicating lot of
> code:
> >>       - All Header work
> >>       - Sampler transmission to a Target once it's created ,
> >>       - ie, all the work done in patched HttpRequestHdr which is big +
> >>       the ability to customize each of the methods in
> DefaultSamplerCreator (as
> >>       Struts Base class was build for example)
> >>
> >> Another idea is to be able to customize the created Sampler, a direct
> use
> >> I see is for example is during a recording of a JSON, GWT or REST
> >> protocols, I as a user had to go on each sampler after recording and
> switch
> >> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
> >> enhancement  I can just subclass DefaultSamplerCreator and register it
> for
> >> GWT Content type and just set the property to switch it to RAW POST
> BODY.
> >>
> >> Hope it's clearer.
> >> Regards
> >> Philippe
> >>
> >> Today the Proxy feature can only be used to record HTTP Textual
> >>
> >> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
> >> philippe.mouawad@gmail.com> wrote:
> >>
> >>> Hello,
> >>> I submitted a patch for 52674<
> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >>> Hope you can have a look at it soon.
> >>>
> >>> I didn't update Tests yet, if you think it's OK then I will update
> them.
> >>>
> >>> Regards
> >>> Philippe
> >>>
> >>>
> >>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
> >>> philippe.mouawad@gmail.com> wrote:
> >>>
> >>>> Hello Sebb, Milamber, Rainer,
> >>>> Did you have time to look at:
> >>>>
> >>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
> >>>>
> >>>> Do you think patch should be applied ?
> >>>>
> >>>>
> >>>> Also I would like to have your opinion regarding :
> >>>>
> >>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >>>>
> >>>> I started an implementation, should I provide a patch or commit it
> >>>> directly ?
> >>>>
> >>>> My idea is the following:
> >>>>
> >>>>    - Either introduce 2 interfaces:
> >>>>
> >>>>
> >>>>    1. SamplerFactory with following method:
> >>>>          1. createSampler(String contentType) => Called in
> >>>>          HttpRequestHdr#getSampler()
> >>>>       2. SamplerCustomizer with following method:
> >>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
> >>>>          HttpRequestHdr#getSampler()
> >>>>          2. fillBody(byte[] rawPostBody) => Called in
> >>>>          HttpRequestHdr#getSampler()
> >>>>
> >>>>
> >>>>    - Or introduce only one SamplerProvider:
> >>>>       - createSampler(String contentType) => Called in
> >>>>       HttpRequestHdr#getSampler()
> >>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
> >>>>       HttpRequestHdr#getSampler()
> >>>>       - fillBody(byte[] rawPostBody) => Called in
> >>>>       HttpRequestHdr#getSampler():
> >>>>          - Default implementation would do what is done today inside
> if
> >>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
> >>>>          (!HTTPConstants.GET.equals(method))) {
> >>>>          - Other protocols would handle it another way
> >>>>
> >>>> --
> >>>> Regards.
> >>>> Philippe Mouawad.
> >>>>
> >>>>
> >>>>
> >>>>
> >>>
> >>>
> >>> --
> >>> Cordialement.
> >>> Philippe Mouawad.
> >>>
> >>>
> >>>
> >>>
> >>
> >>
> >> --
> >> Cordialement.
> >> Philippe Mouawad.
> >>
> >>
> >>
> >>
> >
> >
> > --
> > Cordialement.
> > Philippe Mouawad.
>



-- 
Cordialement.
Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by sebb <se...@gmail.com>.
On 2 March 2012 12:24, Philippe Mouawad <ph...@gmail.com> wrote:
> Hello,
> In french there is a quotation that says "Qui ne dit mot consent" :-)

[That's called "lazy consensus" here, at least when applied to votes.]

> Does it mean you're OK for me committing the issue
> 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
> want to take some more time to review ?

Just had another look.

As far as I can tell, the changes only affect the Proxy code.
In which case, it cannot affect existing test plans; the worst that
can happen is that the Proxy behaves differently from before.
I don't think that would matter much.

I don't object to the code being committed.

Please ensure that the Proxy usage docs are updated as necessary.

> Thank you all.
> Regards
> Philippe
>
> On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
> philippe.mouawad@gmail.com> wrote:
>
>> Hello,
>> To clarify a little bit what this enhancement brings:
>>
>> Today the Proxy can record standard HTTP sessions that are textual, see
>> the Mail of 6 feb 2012
>> "It was designed for recording standard HTTP sessions; these are not
>> binary"
>> And particularly Issue 49039
>>
>>
>> Although it is limited to Textual HTTP Sessions, lot of work in it can be
>> reused to record AMF Sessions , Silverlight sessions or other binary
>> protocols.
>>
>> The idea behind the enhancement is to propose the following:
>>
>>    - Plugin implementor will be able by implementing a SampleCreator
>>    subclass to reuse 90% of proxy feature without duplicating lot of code:
>>       - All Header work
>>       - Sampler transmission to a Target once it's created ,
>>       - ie, all the work done in patched HttpRequestHdr which is big +
>>       the ability to customize each of the methods in DefaultSamplerCreator (as
>>       Struts Base class was build for example)
>>
>> Another idea is to be able to customize the created Sampler, a direct use
>> I see is for example is during a recording of a JSON, GWT or REST
>> protocols, I as a user had to go on each sampler after recording and switch
>> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
>> enhancement  I can just subclass DefaultSamplerCreator and register it for
>> GWT Content type and just set the property to switch it to RAW POST BODY.
>>
>> Hope it's clearer.
>> Regards
>> Philippe
>>
>> Today the Proxy feature can only be used to record HTTP Textual
>>
>> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
>> philippe.mouawad@gmail.com> wrote:
>>
>>> Hello,
>>> I submitted a patch for 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>> Hope you can have a look at it soon.
>>>
>>> I didn't update Tests yet, if you think it's OK then I will update them.
>>>
>>> Regards
>>> Philippe
>>>
>>>
>>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>>> philippe.mouawad@gmail.com> wrote:
>>>
>>>> Hello Sebb, Milamber, Rainer,
>>>> Did you have time to look at:
>>>>
>>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>>>>
>>>> Do you think patch should be applied ?
>>>>
>>>>
>>>> Also I would like to have your opinion regarding :
>>>>
>>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>>
>>>> I started an implementation, should I provide a patch or commit it
>>>> directly ?
>>>>
>>>> My idea is the following:
>>>>
>>>>    - Either introduce 2 interfaces:
>>>>
>>>>
>>>>    1. SamplerFactory with following method:
>>>>          1. createSampler(String contentType) => Called in
>>>>          HttpRequestHdr#getSampler()
>>>>       2. SamplerCustomizer with following method:
>>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>>>>          HttpRequestHdr#getSampler()
>>>>          2. fillBody(byte[] rawPostBody) => Called in
>>>>          HttpRequestHdr#getSampler()
>>>>
>>>>
>>>>    - Or introduce only one SamplerProvider:
>>>>       - createSampler(String contentType) => Called in
>>>>       HttpRequestHdr#getSampler()
>>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>>>>       HttpRequestHdr#getSampler()
>>>>       - fillBody(byte[] rawPostBody) => Called in
>>>>       HttpRequestHdr#getSampler():
>>>>          - Default implementation would do what is done today inside if
>>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>>>>          (!HTTPConstants.GET.equals(method))) {
>>>>          - Other protocols would handle it another way
>>>>
>>>> --
>>>> Regards.
>>>> Philippe Mouawad.
>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Cordialement.
>>> Philippe Mouawad.
>>>
>>>
>>>
>>>
>>
>>
>> --
>> Cordialement.
>> Philippe Mouawad.
>>
>>
>>
>>
>
>
> --
> Cordialement.
> Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by Shmuel Krakower <sh...@gmail.com>.
Hi Philippe,
I am just following this but in the issue you wrote that you succeed to
create a custom sampler based on this change.
What kind of sampler is it and would you think it's worth sharing?

Regards,
Shmuel.
בתאריך 2012 3 2 14:25, מאת "Philippe Mouawad" <ph...@gmail.com>:

> Hello,
> In french there is a quotation that says "Qui ne dit mot consent" :-)
>
> Does it mean you're OK for me committing the issue
> 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
> want to take some more time to review ?
>
> Thank you all.
> Regards
> Philippe
>
> On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
> philippe.mouawad@gmail.com> wrote:
>
> > Hello,
> > To clarify a little bit what this enhancement brings:
> >
> > Today the Proxy can record standard HTTP sessions that are textual, see
> > the Mail of 6 feb 2012
> > "It was designed for recording standard HTTP sessions; these are not
> > binary"
> > And particularly Issue 49039
> >
> >
> > Although it is limited to Textual HTTP Sessions, lot of work in it can be
> > reused to record AMF Sessions , Silverlight sessions or other binary
> > protocols.
> >
> > The idea behind the enhancement is to propose the following:
> >
> >    - Plugin implementor will be able by implementing a SampleCreator
> >    subclass to reuse 90% of proxy feature without duplicating lot of
> code:
> >       - All Header work
> >       - Sampler transmission to a Target once it's created ,
> >       - ie, all the work done in patched HttpRequestHdr which is big +
> >       the ability to customize each of the methods in
> DefaultSamplerCreator (as
> >       Struts Base class was build for example)
> >
> > Another idea is to be able to customize the created Sampler, a direct use
> > I see is for example is during a recording of a JSON, GWT or REST
> > protocols, I as a user had to go on each sampler after recording and
> switch
> > to RAW POST BODY (which means 40 clicks for 20 samplers), with current
> > enhancement  I can just subclass DefaultSamplerCreator and register it
> for
> > GWT Content type and just set the property to switch it to RAW POST BODY.
> >
> > Hope it's clearer.
> > Regards
> > Philippe
> >
> > Today the Proxy feature can only be used to record HTTP Textual
> >
> > On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
> > philippe.mouawad@gmail.com> wrote:
> >
> >> Hello,
> >> I submitted a patch for 52674<
> https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >> Hope you can have a look at it soon.
> >>
> >> I didn't update Tests yet, if you think it's OK then I will update them.
> >>
> >> Regards
> >> Philippe
> >>
> >>
> >> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
> >> philippe.mouawad@gmail.com> wrote:
> >>
> >>> Hello Sebb, Milamber, Rainer,
> >>> Did you have time to look at:
> >>>
> >>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
> >>>
> >>> Do you think patch should be applied ?
> >>>
> >>>
> >>> Also I would like to have your opinion regarding :
> >>>
> >>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> >>>
> >>> I started an implementation, should I provide a patch or commit it
> >>> directly ?
> >>>
> >>> My idea is the following:
> >>>
> >>>    - Either introduce 2 interfaces:
> >>>
> >>>
> >>>    1. SamplerFactory with following method:
> >>>          1. createSampler(String contentType) => Called in
> >>>          HttpRequestHdr#getSampler()
> >>>       2. SamplerCustomizer with following method:
> >>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
> >>>          HttpRequestHdr#getSampler()
> >>>          2. fillBody(byte[] rawPostBody) => Called in
> >>>          HttpRequestHdr#getSampler()
> >>>
> >>>
> >>>    - Or introduce only one SamplerProvider:
> >>>       - createSampler(String contentType) => Called in
> >>>       HttpRequestHdr#getSampler()
> >>>       - customizeSampler(HttpSamplerBase sampler) => Called in
> >>>       HttpRequestHdr#getSampler()
> >>>       - fillBody(byte[] rawPostBody) => Called in
> >>>       HttpRequestHdr#getSampler():
> >>>          - Default implementation would do what is done today inside if
> >>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
> >>>          (!HTTPConstants.GET.equals(method))) {
> >>>          - Other protocols would handle it another way
> >>>
> >>> --
> >>> Regards.
> >>> Philippe Mouawad.
> >>>
> >>>
> >>>
> >>>
> >>
> >>
> >> --
> >> Cordialement.
> >> Philippe Mouawad.
> >>
> >>
> >>
> >>
> >
> >
> > --
> > Cordialement.
> > Philippe Mouawad.
> >
> >
> >
> >
>
>
> --
> Cordialement.
> Philippe Mouawad.
>

Re: Issues 52618 and 52674

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
In french there is a quotation that says "Qui ne dit mot consent" :-)

Does it mean you're OK for me committing the issue
52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>or you
want to take some more time to review ?

Thank you all.
Regards
Philippe

On Wed, Feb 29, 2012 at 4:26 PM, Philippe Mouawad <
philippe.mouawad@gmail.com> wrote:

> Hello,
> To clarify a little bit what this enhancement brings:
>
> Today the Proxy can record standard HTTP sessions that are textual, see
> the Mail of 6 feb 2012
> "It was designed for recording standard HTTP sessions; these are not
> binary"
> And particularly Issue 49039
>
>
> Although it is limited to Textual HTTP Sessions, lot of work in it can be
> reused to record AMF Sessions , Silverlight sessions or other binary
> protocols.
>
> The idea behind the enhancement is to propose the following:
>
>    - Plugin implementor will be able by implementing a SampleCreator
>    subclass to reuse 90% of proxy feature without duplicating lot of code:
>       - All Header work
>       - Sampler transmission to a Target once it's created ,
>       - ie, all the work done in patched HttpRequestHdr which is big +
>       the ability to customize each of the methods in DefaultSamplerCreator (as
>       Struts Base class was build for example)
>
> Another idea is to be able to customize the created Sampler, a direct use
> I see is for example is during a recording of a JSON, GWT or REST
> protocols, I as a user had to go on each sampler after recording and switch
> to RAW POST BODY (which means 40 clicks for 20 samplers), with current
> enhancement  I can just subclass DefaultSamplerCreator and register it for
> GWT Content type and just set the property to switch it to RAW POST BODY.
>
> Hope it's clearer.
> Regards
> Philippe
>
> Today the Proxy feature can only be used to record HTTP Textual
>
> On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
> philippe.mouawad@gmail.com> wrote:
>
>> Hello,
>> I submitted a patch for 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>> Hope you can have a look at it soon.
>>
>> I didn't update Tests yet, if you think it's OK then I will update them.
>>
>> Regards
>> Philippe
>>
>>
>> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
>> philippe.mouawad@gmail.com> wrote:
>>
>>> Hello Sebb, Milamber, Rainer,
>>> Did you have time to look at:
>>>
>>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>>>
>>> Do you think patch should be applied ?
>>>
>>>
>>> Also I would like to have your opinion regarding :
>>>
>>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>>
>>> I started an implementation, should I provide a patch or commit it
>>> directly ?
>>>
>>> My idea is the following:
>>>
>>>    - Either introduce 2 interfaces:
>>>
>>>
>>>    1. SamplerFactory with following method:
>>>          1. createSampler(String contentType) => Called in
>>>          HttpRequestHdr#getSampler()
>>>       2. SamplerCustomizer with following method:
>>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>>>          HttpRequestHdr#getSampler()
>>>          2. fillBody(byte[] rawPostBody) => Called in
>>>          HttpRequestHdr#getSampler()
>>>
>>>
>>>    - Or introduce only one SamplerProvider:
>>>       - createSampler(String contentType) => Called in
>>>       HttpRequestHdr#getSampler()
>>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>>>       HttpRequestHdr#getSampler()
>>>       - fillBody(byte[] rawPostBody) => Called in
>>>       HttpRequestHdr#getSampler():
>>>          - Default implementation would do what is done today inside if
>>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>>>          (!HTTPConstants.GET.equals(method))) {
>>>          - Other protocols would handle it another way
>>>
>>> --
>>> Regards.
>>> Philippe Mouawad.
>>>
>>>
>>>
>>>
>>
>>
>> --
>> Cordialement.
>> Philippe Mouawad.
>>
>>
>>
>>
>
>
> --
> Cordialement.
> Philippe Mouawad.
>
>
>
>


-- 
Cordialement.
Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
To clarify a little bit what this enhancement brings:

Today the Proxy can record standard HTTP sessions that are textual, see the
Mail of 6 feb 2012
"It was designed for recording standard HTTP sessions; these are not binary"
And particularly Issue 49039


Although it is limited to Textual HTTP Sessions, lot of work in it can be
reused to record AMF Sessions , Silverlight sessions or other binary
protocols.

The idea behind the enhancement is to propose the following:

   - Plugin implementor will be able by implementing a SampleCreator
   subclass to reuse 90% of proxy feature without duplicating lot of code:
      - All Header work
      - Sampler transmission to a Target once it's created ,
      - ie, all the work done in patched HttpRequestHdr which is big + the
      ability to customize each of the methods in DefaultSamplerCreator (as
      Struts Base class was build for example)

Another idea is to be able to customize the created Sampler, a direct use I
see is for example is during a recording of a JSON, GWT or REST protocols,
I as a user had to go on each sampler after recording and switch to RAW
POST BODY (which means 40 clicks for 20 samplers), with current
enhancement  I can just subclass DefaultSamplerCreator and register it for
GWT Content type and just set the property to switch it to RAW POST BODY.

Hope it's clearer.
Regards
Philippe

Today the Proxy feature can only be used to record HTTP Textual

On Sun, Feb 26, 2012 at 9:04 PM, Philippe Mouawad <
philippe.mouawad@gmail.com> wrote:

> Hello,
> I submitted a patch for 52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
> Hope you can have a look at it soon.
>
> I didn't update Tests yet, if you think it's OK then I will update them.
>
> Regards
> Philippe
>
>
> On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
> philippe.mouawad@gmail.com> wrote:
>
>> Hello Sebb, Milamber, Rainer,
>> Did you have time to look at:
>>
>>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>>
>> Do you think patch should be applied ?
>>
>>
>> Also I would like to have your opinion regarding :
>>
>>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>>
>> I started an implementation, should I provide a patch or commit it
>> directly ?
>>
>> My idea is the following:
>>
>>    - Either introduce 2 interfaces:
>>
>>
>>    1. SamplerFactory with following method:
>>          1. createSampler(String contentType) => Called in
>>          HttpRequestHdr#getSampler()
>>       2. SamplerCustomizer with following method:
>>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>>          HttpRequestHdr#getSampler()
>>          2. fillBody(byte[] rawPostBody) => Called in
>>          HttpRequestHdr#getSampler()
>>
>>
>>    - Or introduce only one SamplerProvider:
>>       - createSampler(String contentType) => Called in
>>       HttpRequestHdr#getSampler()
>>       - customizeSampler(HttpSamplerBase sampler) => Called in
>>       HttpRequestHdr#getSampler()
>>       - fillBody(byte[] rawPostBody) => Called in
>>       HttpRequestHdr#getSampler():
>>          - Default implementation would do what is done today inside if
>>          ((!HTTPConstants.CONNECT.equals(getMethod())) &&
>>          (!HTTPConstants.GET.equals(method))) {
>>          - Other protocols would handle it another way
>>
>> --
>> Regards.
>> Philippe Mouawad.
>>
>>
>>
>>
>
>
> --
> Cordialement.
> Philippe Mouawad.
>
>
>
>


-- 
Cordialement.
Philippe Mouawad.

Re: Issues 52618 and 52674

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
I submitted a patch for
52674<https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
Hope you can have a look at it soon.

I didn't update Tests yet, if you think it's OK then I will update them.

Regards
Philippe

On Wed, Feb 15, 2012 at 11:30 PM, Philippe Mouawad <
philippe.mouawad@gmail.com> wrote:

> Hello Sebb, Milamber, Rainer,
> Did you have time to look at:
>
>    - 52618 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52618>
>
> Do you think patch should be applied ?
>
>
> Also I would like to have your opinion regarding :
>
>    - 52674 <https://issues.apache.org/bugzilla/show_bug.cgi?id=52674>
>
> I started an implementation, should I provide a patch or commit it
> directly ?
>
> My idea is the following:
>
>    - Either introduce 2 interfaces:
>
>
>    1. SamplerFactory with following method:
>          1. createSampler(String contentType) => Called in
>          HttpRequestHdr#getSampler()
>       2. SamplerCustomizer with following method:
>          1. customizeSampler(HttpSamplerBase sampler) => Called in
>          HttpRequestHdr#getSampler()
>          2. fillBody(byte[] rawPostBody) => Called in
>          HttpRequestHdr#getSampler()
>
>
>    - Or introduce only one SamplerProvider:
>       - createSampler(String contentType) => Called in
>       HttpRequestHdr#getSampler()
>       - customizeSampler(HttpSamplerBase sampler) => Called in
>       HttpRequestHdr#getSampler()
>       - fillBody(byte[] rawPostBody) => Called in
>       HttpRequestHdr#getSampler():
>          - Default implementation would do what is done today inside if
>          ((!HTTPConstants.CONNECT.equals(getMethod())) && (!HTTPConstants.
>          GET.equals(method))) {
>          - Other protocols would handle it another way
>
> --
> Regards.
> Philippe Mouawad.
>
>
>
>


-- 
Cordialement.
Philippe Mouawad.