[storm] Talking about Storm

Brad Allen ballen at zeomega.com
Thu Nov 26 14:09:26 GMT 2009


On Mon, Nov 23, 2009 at 10:26 PM, Jamu Kakar <jkakar at kakar.ca> wrote:

>
> If you were attending a talk about Storm, what would you like to
> hear about?
>
>
A non-trivial example might get people's interest, if you have enough time
allotted. You could draw an ERD illustrating a complex set of relations
between tables, and describe a requirement which involves various kinds of
joins (including some self joins to give you a chance to show off
ClassAlias).

The requirement can then be shown as an extremely hairy multi-page SQL
statement, for which the audience can be given a moment or two to appreciate
the horror as the query scrolls slowly by. Low, ominous background music
could add to the effect.

"This is the kind of query you might see every day in a 'real world'
application," you could say flatly, "except that in the real world it's a
bit worse. You see, the joins in this query needs to vary dynamically, and
each variant needs to unioned with the other variants."

You could then proceed to show how to assemble the same query using Storm
classes such as Join and ClassAlias, set up the query structure using
store.using, and specify the desired classes which should populate in the
ResultSet using store.find. Then, after showing how to dynamically vary the
ResultSet as needed, you could also show how to use itertools.chain to
create the effect of a union between multiple ResultSet objects.

The result should be code which is much more readable and manageable than
the horrific piece of SQL shown earlier, yet which when run in debug mode,
can print that selfsame chunk of SQL.

That sort of talk really demonstrates the benefits of using an ORM, which is
of more general interest than just Storm and might attract more attendees.
However, it's a good showcase of Storm's capabilities.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.ubuntu.com/archives/storm/attachments/20091126/121cd109/attachment.htm 


More information about the storm mailing list