Protobuf handling Jmeter

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Protobuf handling Jmeter

prateekgommt
Hi guys,

Any idea on handling of Protobuf requests via Jmeter ?


Thanks,
Prateek

--


::DISCLAIMER::


----------------------------------------------------------------------------------------------------------------------------------------------------





This message is intended only for the use of the addressee and may
contain information that is privileged, confidential and exempt from
disclosure under applicable law. If the reader of this message is not the
intended recipient, or the employee or agent responsible for delivering the
message to the intended recipient, you are hereby notified that any
dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this e-mail in error, please notify us
immediately by return e-mail and delete this e-mail and all attachments
from your system.
Reply | Threaded
Open this post in threaded view
|

Re: Protobuf handling Jmeter

shettyd
Hi
not sure what your requirement is - However protobuf has a java api and you
can use that to generate the payload like any other java code that you need
to invoke. if you need to pass that payload in some request then that
should be possible too

On Tue, Jan 15, 2019 at 12:43 AM Prateek Dua <[hidden email]> wrote:

> Hi guys,
>
> Any idea on handling of Protobuf requests via Jmeter ?
>
>
> Thanks,
> Prateek
>
> --
>
>
> ::DISCLAIMER::
>
>
>
> ----------------------------------------------------------------------------------------------------------------------------------------------------
>
>
>
>
>
> This message is intended only for the use of the addressee and may
> contain information that is privileged, confidential and exempt from
> disclosure under applicable law. If the reader of this message is not the
> intended recipient, or the employee or agent responsible for delivering
> the
> message to the intended recipient, you are hereby notified that any
> dissemination, distribution or copying of this communication is strictly
> prohibited. If you have received this e-mail in error, please notify us
> immediately by return e-mail and delete this e-mail and all attachments
> from your system.
>
Reply | Threaded
Open this post in threaded view
|

Re: Protobuf handling Jmeter

prateekgommt
Hi Deepak,

Requirement is to test Performance of apis created via Protobuf through
Jmeter. But since I don't have Json or Curl request , So I'm stuck how to
record these Protobuf supported apis via Jmeter's Http Proxy Server.

Thanks,
Prateek


On Wed, Jan 16, 2019 at 5:18 AM Deepak Shetty <[hidden email]> wrote:

> Hi
> not sure what your requirement is - However protobuf has a java api and you
> can use that to generate the payload like any other java code that you need
> to invoke. if you need to pass that payload in some request then that
> should be possible too
>
> On Tue, Jan 15, 2019 at 12:43 AM Prateek Dua <[hidden email]>
> wrote:
>
> > Hi guys,
> >
> > Any idea on handling of Protobuf requests via Jmeter ?
> >
> >
> > Thanks,
> > Prateek
> >
> > --
> >
> >
> > ::DISCLAIMER::
> >
> >
> >
> >
> ----------------------------------------------------------------------------------------------------------------------------------------------------
> >
> >
> >
> >
> >
> > This message is intended only for the use of the addressee and may
> > contain information that is privileged, confidential and exempt from
> > disclosure under applicable law. If the reader of this message is not the
> > intended recipient, or the employee or agent responsible for delivering
> > the
> > message to the intended recipient, you are hereby notified that any
> > dissemination, distribution or copying of this communication is strictly
> > prohibited. If you have received this e-mail in error, please notify us
> > immediately by return e-mail and delete this e-mail and all attachments
> > from your system.
> >
>

--


::DISCLAIMER::


----------------------------------------------------------------------------------------------------------------------------------------------------





This message is intended only for the use of the addressee and may
contain information that is privileged, confidential and exempt from
disclosure under applicable law. If the reader of this message is not the
intended recipient, or the employee or agent responsible for delivering the
message to the intended recipient, you are hereby notified that any
dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this e-mail in error, please notify us
immediately by return e-mail and delete this e-mail and all attachments
from your system.
Reply | Threaded
Open this post in threaded view
|

Re: Protobuf handling Jmeter

shettyd
Hi
Protocol buffers is a way to efficiently serialize some data into a binary
representation.
You havent yet articulated what you want to performance test .

Example 1 - Perhaps your application has some objects that it used to save
to XML files. Someone has now come up with the idea of saving it using
protobuf. You are trying to verify that this is faster than what you have -
In this case there is no HTTP  / No proxy - you are just testing out a java
api and you could just use a Java Sampler .

Example 2 - Perhaps your application is posting JSON data into a queue and
now someone has decided to change it to use protobuf. In this case you
still need to write some java code to get the binary payload and post that
to the queue - No HTTP/Proxy recording here either.

Example 3 : Perhaps your application is wanting to post protobuf to some
HTTP API and its really the performance number of the API that you want to
find out . You could record this , but in order to vary the data you would
need to write some java code (there is no record/replay for that java code).

and so on.
Read up on protobuf perhaps that will make some things more clearer.

On Wed, Jan 16, 2019 at 2:28 AM Prateek Dua <[hidden email]> wrote:

> Hi Deepak,
>
> Requirement is to test Performance of apis created via Protobuf through
> Jmeter. But since I don't have Json or Curl request , So I'm stuck how to
> record these Protobuf supported apis via Jmeter's Http Proxy Server.
>
> Thanks,
> Prateek
>
>
> On Wed, Jan 16, 2019 at 5:18 AM Deepak Shetty <[hidden email]> wrote:
>
> > Hi
> > not sure what your requirement is - However protobuf has a java api and
> you
> > can use that to generate the payload like any other java code that you
> need
> > to invoke. if you need to pass that payload in some request then that
> > should be possible too
> >
> > On Tue, Jan 15, 2019 at 12:43 AM Prateek Dua <[hidden email]>
> > wrote:
> >
> > > Hi guys,
> > >
> > > Any idea on handling of Protobuf requests via Jmeter ?
> > >
> > >
> > > Thanks,
> > > Prateek
> > >
> > > --
> > >
> > >
> > > ::DISCLAIMER::
> > >
> > >
> > >
> > >
> >
> ----------------------------------------------------------------------------------------------------------------------------------------------------
> > >
> > >
> > >
> > >
> > >
> > > This message is intended only for the use of the addressee and may
> > > contain information that is privileged, confidential and exempt from
> > > disclosure under applicable law. If the reader of this message is not
> the
> > > intended recipient, or the employee or agent responsible for delivering
> > > the
> > > message to the intended recipient, you are hereby notified that any
> > > dissemination, distribution or copying of this communication is
> strictly
> > > prohibited. If you have received this e-mail in error, please notify us
> > > immediately by return e-mail and delete this e-mail and all attachments
> > > from your system.
> > >
> >
>
> --
>
>
> ::DISCLAIMER::
>
>
>
> ----------------------------------------------------------------------------------------------------------------------------------------------------
>
>
>
>
>
> This message is intended only for the use of the addressee and may
> contain information that is privileged, confidential and exempt from
> disclosure under applicable law. If the reader of this message is not the
> intended recipient, or the employee or agent responsible for delivering
> the
> message to the intended recipient, you are hereby notified that any
> dissemination, distribution or copying of this communication is strictly
> prohibited. If you have received this e-mail in error, please notify us
> immediately by return e-mail and delete this e-mail and all attachments
> from your system.
>
Reply | Threaded
Open this post in threaded view
|

Re: Protobuf handling Jmeter

prateekgommt
Thanks Deepak. Example 2 is the concern in my case. Yeah we are going via
writing Java Code approach but thought of any other alternative to do this.


Thanks,
Prateek

On Thu, Jan 17, 2019 at 12:45 AM Deepak Shetty <[hidden email]> wrote:

> Hi
> Protocol buffers is a way to efficiently serialize some data into a binary
> representation.
> You havent yet articulated what you want to performance test .
>
> Example 1 - Perhaps your application has some objects that it used to save
> to XML files. Someone has now come up with the idea of saving it using
> protobuf. You are trying to verify that this is faster than what you have -
> In this case there is no HTTP  / No proxy - you are just testing out a java
> api and you could just use a Java Sampler .
>
> Example 2 - Perhaps your application is posting JSON data into a queue and
> now someone has decided to change it to use protobuf. In this case you
> still need to write some java code to get the binary payload and post that
> to the queue - No HTTP/Proxy recording here either.
>
> Example 3 : Perhaps your application is wanting to post protobuf to some
> HTTP API and its really the performance number of the API that you want to
> find out . You could record this , but in order to vary the data you would
> need to write some java code (there is no record/replay for that java
> code).
>
> and so on.
> Read up on protobuf perhaps that will make some things more clearer.
>
> On Wed, Jan 16, 2019 at 2:28 AM Prateek Dua <[hidden email]>
> wrote:
>
> > Hi Deepak,
> >
> > Requirement is to test Performance of apis created via Protobuf through
> > Jmeter. But since I don't have Json or Curl request , So I'm stuck how to
> > record these Protobuf supported apis via Jmeter's Http Proxy Server.
> >
> > Thanks,
> > Prateek
> >
> >
> > On Wed, Jan 16, 2019 at 5:18 AM Deepak Shetty <[hidden email]> wrote:
> >
> > > Hi
> > > not sure what your requirement is - However protobuf has a java api and
> > you
> > > can use that to generate the payload like any other java code that you
> > need
> > > to invoke. if you need to pass that payload in some request then that
> > > should be possible too
> > >
> > > On Tue, Jan 15, 2019 at 12:43 AM Prateek Dua <[hidden email]>
> > > wrote:
> > >
> > > > Hi guys,
> > > >
> > > > Any idea on handling of Protobuf requests via Jmeter ?
> > > >
> > > >
> > > > Thanks,
> > > > Prateek
> > > >
> > > > --
> > > >
> > > >
> > > > ::DISCLAIMER::
> > > >
> > > >
> > > >
> > > >
> > >
> >
> ----------------------------------------------------------------------------------------------------------------------------------------------------
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > This message is intended only for the use of the addressee and may
> > > > contain information that is privileged, confidential and exempt from
> > > > disclosure under applicable law. If the reader of this message is not
> > the
> > > > intended recipient, or the employee or agent responsible for
> delivering
> > > > the
> > > > message to the intended recipient, you are hereby notified that any
> > > > dissemination, distribution or copying of this communication is
> > strictly
> > > > prohibited. If you have received this e-mail in error, please notify
> us
> > > > immediately by return e-mail and delete this e-mail and all
> attachments
> > > > from your system.
> > > >
> > >
> >
> > --
> >
> >
> > ::DISCLAIMER::
> >
> >
> >
> >
> ----------------------------------------------------------------------------------------------------------------------------------------------------
> >
> >
> >
> >
> >
> > This message is intended only for the use of the addressee and may
> > contain information that is privileged, confidential and exempt from
> > disclosure under applicable law. If the reader of this message is not the
> > intended recipient, or the employee or agent responsible for delivering
> > the
> > message to the intended recipient, you are hereby notified that any
> > dissemination, distribution or copying of this communication is strictly
> > prohibited. If you have received this e-mail in error, please notify us
> > immediately by return e-mail and delete this e-mail and all attachments
> > from your system.
> >
>

--


::DISCLAIMER::


----------------------------------------------------------------------------------------------------------------------------------------------------





This message is intended only for the use of the addressee and may
contain information that is privileged, confidential and exempt from
disclosure under applicable law. If the reader of this message is not the
intended recipient, or the employee or agent responsible for delivering the
message to the intended recipient, you are hereby notified that any
dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this e-mail in error, please notify us
immediately by return e-mail and delete this e-mail and all attachments
from your system.
Reply | Threaded
Open this post in threaded view
|

Proto requests via Jmeter

Prateek Dua
In reply to this post by prateekgommt
Hi guys,

Any idea on handling Protobuf requests via Jmeter ? Our Organization got
shifted from Json to Proto for most of the apis request now .

So is there any convenient way to record Proto requests  ?


Thanks,
Prateek

--


::DISCLAIMER::


----------------------------------------------------------------------------------------------------------------------------------------------------





This message is intended only for the use of the addressee and may
contain information that is privileged, confidential and exempt from
disclosure under applicable law. If the reader of this message is not the
intended recipient, or the employee or agent responsible for delivering the
message to the intended recipient, you are hereby notified that any
dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this e-mail in error, please notify us
immediately by return e-mail and delete this e-mail and all attachments
from your system.
Reply | Threaded
Open this post in threaded view
|

Re: Proto requests via Jmeter

shettyd
Hi
I think you are asking 2 different questions here
a. How to generate a protobuf request in JMeter - That would need you to
use the Java API to generate the request -
https://developers.google.com/protocol-buffers/docs/javatutorial
b. How to actually send it to the API - Assuming this is still HTTP based
then I think either you need to save a file and send that or use the HTTP
Raw request from jmeter plugins.
There isnt a way to convert JSON to protobuf in jmeter as far as I know(Im
assuming your dev team has already provided you the .proto files which
could be generated from JSON) and record and replay is not much use when
you are dealing with binary formats unless you want to replicate exactly
the same thing , no parameterisation or variations (almost never the case
in any testing automation).

regards
deepak

On Thu, Nov 28, 2019 at 4:50 AM Prateek Dua <[hidden email]>
wrote:

> Hi guys,
>
> Any idea on handling Protobuf requests via Jmeter ? Our Organization got
> shifted from Json to Proto for most of the apis request now .
>
> So is there any convenient way to record Proto requests  ?
>
>
> Thanks,
> Prateek
>
> --
>
>
> ::DISCLAIMER::
>
>
>
> ----------------------------------------------------------------------------------------------------------------------------------------------------
>
>
>
>
>
> This message is intended only for the use of the addressee and may
> contain information that is privileged, confidential and exempt from
> disclosure under applicable law. If the reader of this message is not the
> intended recipient, or the employee or agent responsible for delivering
> the
> message to the intended recipient, you are hereby notified that any
> dissemination, distribution or copying of this communication is strictly
> prohibited. If you have received this e-mail in error, please notify us
> immediately by return e-mail and delete this e-mail and all attachments
> from your system.
>