Thanks for your reply.

I am not sure I understand. How would defining a function make sure it is
run only once? I want all bolts that run on the same machine (or at least
in the same process) to share one import.

Is it performance-wise you can't recommend Python or another reason?

Best regards,
Joel


2014-07-03 4:51 GMT+02:00 Mark Hu <[email protected]>:

> I believe the below is a stub you can flesh out.
>
> def post_initialize( self ):
>      <flesh out>
>
> Please note that I can't recommend Storm and Python; language layers begin
> with Java -> Jruby -> Python, and the text pipe in between Jruby and Python
> makes it really hard to recover from. I recommend either Java, and worst
> case Jruby, for any production work you're thinking about.
>
>
> On Wed, Jul 2, 2014 at 8:41 AM, Joel Samuelsson <[email protected]
> > wrote:
>
>> Once per supervisor / worker, I should say.
>>
>> Best regards,
>> Joel
>>
>>
>> 2014-07-01 14:38 GMT+02:00 Joel Samuelsson <[email protected]>:
>>
>> We are using storm bolts written in python. In the bolt we have a
>>> dependency that takes a lot of time to import. Is there a way to make the
>>> import only once per instance of the bolt?
>>>
>>> Best regards,
>>> Joel
>>>
>>
>>
>

Reply via email to