[storm] Objects not notified when DB chnages
Gabriel Rossetti
gabriel.rossetti at arimaz.com
Fri Sep 19 10:08:16 BST 2008
James Henstridge wrote:
> On Mon, Aug 18, 2008 at 2:34 PM, Gabriel Rossetti
> <gabriel.rossetti at arimaz.com> wrote:
>
>> Hello,
>>
>> I noticed that if I change a value in the DB, Storm continues to use
>> it's cached value.
>> Is there a good way to have it update it's cache?
>>
>
> Hi Gabriel,
>
> Storm is designed to run using serialised transactions. This means
> that within the transaction the database effectively provides a
> snapshot of the database state for Storm to work with. When you
> commit a transaction and start another, you will see changes made by
> other database connections. Storm will invalidate its caches on
> transaction boundaries.
>
> So the answer to your question is to commit your transactions.
>
> James.
>
Just a commit didn't work, I had to do a flush() before the commit for
it to work.
Gabriel
More information about the storm
mailing list