You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@storm.apache.org by "J.R. Pauley" <jr...@gmail.com> on 2017/07/05 05:57:48 UTC

TridentDRPC REST endpoint ?

Anyone have experience/example of how to add a REST /get API onto a
TridentTopology? I want to run REST queries over http vs from a DRPC
Client. I see some hints that elasticsearch may have some useful code but
can't locate anything tangible.

Any clues appreciated

Re: TridentDRPC REST endpoint ?

Posted by Bobby Evans <ev...@yahoo-inc.com>.
Glad to help.


- Bobby


On Wednesday, July 5, 2017, 6:57:58 PM CDT, J.R. Pauley <jr...@gmail.com> wrote:

Thanks so much Bobby. I have ti working.!Timing of this info could not be better as I urgently am working on dog-and-pony show for execs and desperate to find REST DRPC solution
Cheers,Jim
On Wed, Jul 5, 2017 at 11:37 AM, Bobby Evans <ev...@yahoo-inc.com> wrote:

DRPC supports REST.
But sadly it is not well documented (that is my fault).
If you set the config `drpc.http.port` to a non zero value an HTTPS server will come up.  You can hit it using any of
You can POST the argument to `/drpc/${func}` where ${func} is the function you want to hit.
You can also do a GET on `/drpc/${func}/${args}` if args is small enough to fit in the URL.
Doing a GET on `/drpc/${func}` will do a request with empty args.
There are also a lot of configs, like with the UI, to allow you to have https, and authentication/authorization for DRPC too.


- Bobby


On Wednesday, July 5, 2017, 12:58:01 AM CDT, J.R. Pauley <jr...@gmail.com> wrote:

Anyone have experience/example of how to add a REST /get API onto a TridentTopology? I want to run REST queries over http vs from a DRPC Client. I see some hints that elasticsearch may have some useful code but can't locate anything tangible. 
Any clues appreciated


Re: TridentDRPC REST endpoint ?

Posted by "J.R. Pauley" <jr...@gmail.com>.
Thanks so much Bobby. I have ti working.!
Timing of this info could not be better as I urgently am working on
dog-and-pony show for execs and desperate to find REST DRPC solution

Cheers,
Jim

On Wed, Jul 5, 2017 at 11:37 AM, Bobby Evans <ev...@yahoo-inc.com> wrote:

> DRPC supports REST.
>
> But sadly it is not well documented (that is my fault).
>
> If you set the config `drpc.http.port` to a non zero value an HTTPS
> server will come up.  You can hit it using any of
>
> You can POST the argument to `/drpc/${func}` where ${func} is the
> function you want to hit.
>
> You can also do a GET on `/drpc/${func}/${args}` if args is small enough
> to fit in the URL.
>
> Doing a GET on `/drpc/${func}` will do a request with empty args.
>
> There are also a lot of configs, like with the UI, to allow you to have
> https, and authentication/authorization for DRPC too.
>
>
> - Bobby
>
>
>
> On Wednesday, July 5, 2017, 12:58:01 AM CDT, J.R. Pauley <
> jrpauley@gmail.com> wrote:
>
>
> Anyone have experience/example of how to add a REST /get API onto a
> TridentTopology? I want to run REST queries over http vs from a DRPC
> Client. I see some hints that elasticsearch may have some useful code but
> can't locate anything tangible.
>
> Any clues appreciated
>

Re: TridentDRPC REST endpoint ?

Posted by Bobby Evans <ev...@yahoo-inc.com>.
Sorry 0.9.6 is not going to work.  You need at least 0.10 to make this work.  But all is not lost, because you can just run a 0.10.2 drpc server instead of the 0.9.6 one, and keep the rest of your cluster the same.  The spouts and bolts should have no problem talking to the newer server through thrift.


- Bobby


On Wednesday, July 5, 2017, 11:29:50 AM CDT, J.R. Pauley <jr...@gmail.com> wrote:

Bobby:
Thanks. This is super timely to me as I have an urgent demo to get out. I have set the following in storm.yaml and working in 0.9.6. I restarted nimbus/supervisor/drpc but I don't see anyone listening on 8087. Have I misunderstood?-Jim:drpc.servers:    - "127.0.0.1"    - "10.78.17.67"
 drpc.http.port: 8087

On Wed, Jul 5, 2017 at 11:37 AM, Bobby Evans <ev...@yahoo-inc.com> wrote:

DRPC supports REST.
But sadly it is not well documented (that is my fault).
If you set the config `drpc.http.port` to a non zero value an HTTPS server will come up.  You can hit it using any of
You can POST the argument to `/drpc/${func}` where ${func} is the function you want to hit.
You can also do a GET on `/drpc/${func}/${args}` if args is small enough to fit in the URL.
Doing a GET on `/drpc/${func}` will do a request with empty args.
There are also a lot of configs, like with the UI, to allow you to have https, and authentication/authorization for DRPC too.


- Bobby


On Wednesday, July 5, 2017, 12:58:01 AM CDT, J.R. Pauley <jr...@gmail.com> wrote:

Anyone have experience/example of how to add a REST /get API onto a TridentTopology? I want to run REST queries over http vs from a DRPC Client. I see some hints that elasticsearch may have some useful code but can't locate anything tangible. 
Any clues appreciated


Re: TridentDRPC REST endpoint ?

Posted by "J.R. Pauley" <jr...@gmail.com>.
Bobby:

Thanks. This is super timely to me as I have an urgent demo to get out. I
have set the following in storm.yaml and working in 0.9.6. I restarted
nimbus/supervisor/drpc but I don't see anyone listening on 8087. Have I
misunderstood?
-Jim
:
drpc.servers:
    - "127.0.0.1"
    - "10.78.17.67"

 drpc.http.port: 8087


On Wed, Jul 5, 2017 at 11:37 AM, Bobby Evans <ev...@yahoo-inc.com> wrote:

> DRPC supports REST.
>
> But sadly it is not well documented (that is my fault).
>
> If you set the config `drpc.http.port` to a non zero value an HTTPS
> server will come up.  You can hit it using any of
>
> You can POST the argument to `/drpc/${func}` where ${func} is the
> function you want to hit.
>
> You can also do a GET on `/drpc/${func}/${args}` if args is small enough
> to fit in the URL.
>
> Doing a GET on `/drpc/${func}` will do a request with empty args.
>
> There are also a lot of configs, like with the UI, to allow you to have
> https, and authentication/authorization for DRPC too.
>
>
> - Bobby
>
>
>
> On Wednesday, July 5, 2017, 12:58:01 AM CDT, J.R. Pauley <
> jrpauley@gmail.com> wrote:
>
>
> Anyone have experience/example of how to add a REST /get API onto a
> TridentTopology? I want to run REST queries over http vs from a DRPC
> Client. I see some hints that elasticsearch may have some useful code but
> can't locate anything tangible.
>
> Any clues appreciated
>

Re: TridentDRPC REST endpoint ?

Posted by Bobby Evans <ev...@yahoo-inc.com>.
DRPC supports REST.
But sadly it is not well documented (that is my fault).
If you set the config `drpc.http.port` to a non zero value an HTTPS server will come up.  You can hit it using any of
You can POST the argument to `/drpc/${func}` where ${func} is the function you want to hit.
You can also do a GET on `/drpc/${func}/${args}` if args is small enough to fit in the URL.
Doing a GET on `/drpc/${func}` will do a request with empty args.
There are also a lot of configs, like with the UI, to allow you to have https, and authentication/authorization for DRPC too.


- Bobby


On Wednesday, July 5, 2017, 12:58:01 AM CDT, J.R. Pauley <jr...@gmail.com> wrote:

Anyone have experience/example of how to add a REST /get API onto a TridentTopology? I want to run REST queries over http vs from a DRPC Client. I see some hints that elasticsearch may have some useful code but can't locate anything tangible. 
Any clues appreciated