politie / breeze

Spring integration for Apache Storm
Apache License 2.0
21 stars 7 forks source link

Add support for Distributed RPC #3

Closed seajas closed 10 years ago

seajas commented 10 years ago

Topology support for Storm's DRPC mechanism means the possibility of blocking processing calls without the need for an in-between solution like reading from a queue.

pascaldekloe commented 10 years ago

We could support Storm's DRPC with a little syntactic sugar.

<breeze:topology id="remoteExample">
   <breeze:rpc signature="function(args)"/>
[...]

I'm not sure why DRPCClient#execute want's the arguments as one string.

pascaldekloe commented 10 years ago

Apparently the marshalling is undefined for parameters. Storm's DRPCSpout offers the request as a fixed tuple field "args" and ReturnResults wants the response from the first tuple value.

For now we'll support only string in / string out and therefore leave the conversion up to the user (bolts). Later we can add conversion strategies.

Thus Breeze's RPC with signature="f(x)" and outputFields="y" means the flow starts with a bolt that has one input field x and it ends with the last bolt to operate on y.