storm-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eyal Golan <egola...@gmail.com>
Subject Shared static data between bolts
Date Thu, 04 Dec 2014 19:01:16 GMT
Hi all,
I am newbie with Storm and having some issues with static objects in the
topology.
In the main class, where I set the topology, I also set a static object.
It's actually a wrapper for a collection of strings.
This object needs to he shared between different bolts.
It's big so I want it to be only one instance.

The problem is that when a bolt tries to get this static instance: example
- MyMain.Shared... It's null. Although I instantiated it in the main method.

I guess I'm doing something wrong.

Thanks for any assistance.

Eyal

Sent from my Android phone

Mime
View raw message