You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi all, In riak_core_ring_manager.erl, every time you fresh the ring, or transfer the ring, you have to riak_core_ring:set_tainted/1, but I don't see anywhere to clear the tainted ring? So my question is what does riak_core_ring:set_tainted/1 actually did? What's the meaning of a tainted ring? Yeah, you may say a tainted ring is dangerous, the riak_core may stopped by app_helper:get_env(riak_core, exit_when_tainted, false). But I see after the cluster is set up, all nodes started, the ring is always tainted, seems it's useless?
The text was updated successfully, but these errors were encountered:
Basho-JIRA
changed the title
When to clear tainted ring state or what's the meaning of tainted ring
When to clear tainted ring state or what's the meaning of tainted ring [JIRA: RIAK-1864]
Jun 12, 2015
@jsvisa +1 also curious - changes were introduced by this P/R by @jtuple in 2011.
I never really understood the distinction between riak_core_ring:get_raw_ring and riak_core_ring:get_my_ring.
Examining the data structure returned by riak_core_ring_manager:get_raw_ring() - the only significant difference seems to be the following field: [[riak_core_ring_tainted|{meta_entry,t....
And the tainted ring check you mention is not enabled by default:
check_tainted(Ring=?CHSTATE{}, Msg) ->
Exit = app_helper:get_env(riak_core, exit_when_tainted, false),
case {get_meta(riak_core_ring_tainted, Ring), Exit} of
{{ok, true}, true} ->
riak_core:stop(Msg),
ok;
{{ok, true}, false} ->
lager:error(Msg),
ok;
_ ->
ok
end.
The ring state is held per node in ETS (which is cheap to update, but comparatively slow to query), after a certain period of cluster stability (60 seconds I think) stored as a module definition via mochiglobal for faster lookup speed.
I guess the taint checks might have something to do with this interplay?
Hi all, In riak_core_ring_manager.erl, every time you fresh the ring, or transfer the ring, you have to
riak_core_ring:set_tainted/1
, but I don't see anywhere to clear thetainted
ring? So my question is what doesriak_core_ring:set_tainted/1
actually did? What's the meaning of atainted
ring? Yeah, you may say a tainted ring is dangerous, the riak_core may stopped byapp_helper:get_env(riak_core, exit_when_tainted, false)
. But I see after the cluster is set up, all nodes started, the ring is alwaystainted
, seems it's useless?The text was updated successfully, but these errors were encountered: