FAQ
Hi,

Is it me, or it seems that Storm needs some context for worker process
(JVM) - level stuff? Or maybe it should be process-AND-topology-level...

I want to have some things constructed and accessible to all spouts/bolts
on JVM level, but I cannot see what is ideal way to achieve this? It seems
to me that people use lazy static field initialization during
Spout.open(...), but it's clearly not the nicest way to achieve this.

For example, I am used for years to use Spring as container for my (mostly
stateless) logic, and I would like to have the same with Storm. But I dunno
where should Spring's ApplicationContext be initialized?

Regards,
Vjeran

Search Discussions

  • Nathan Marz at Jan 5, 2013 at 7:41 am
    Yea, this is definitely a hole in the current API. You can currently hack
    around it by being clever with static variables and locks.
    On Fri, Jan 4, 2013 at 9:34 PM, wrote:

    Hi,

    Is it me, or it seems that Storm needs some context for worker process
    (JVM) - level stuff? Or maybe it should be process-AND-topology-level...

    I want to have some things constructed and accessible to all spouts/bolts
    on JVM level, but I cannot see what is ideal way to achieve this? It seems
    to me that people use lazy static field initialization during
    Spout.open(...), but it's clearly not the nicest way to achieve this.

    For example, I am used for years to use Spring as container for my (mostly
    stateless) logic, and I would like to have the same with Storm. But I dunno
    where should Spring's ApplicationContext be initialized?

    Regards,
    Vjeran


    --
    Twitter: @nathanmarz
    http://nathanmarz.com

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupstorm-user @
postedJan 5, '13 at 7:38a
activeJan 5, '13 at 7:41a
posts2
users2
websitestorm-project.net
irc#storm-user

2 users in discussion

Nathan Marz: 1 post Vmarcinko: 1 post

People

Translate

site design / logo © 2022 Grokbase