[Redis] Sentinel

Steffen Mueller smueller at cpan.org
Tue Jan 14 07:19:37 GMT 2014


Hi,

On 01/12/2014 07:30 PM, Damien Krotkine wrote:
> I've reimplemented the support of Sentinel in Redis (sorry Steffen! :P )
>
> It's in the sentinel2 branch on github.
>
> I would very much appreciate if anyone can test it. I've provided a test
> ( t/60... ) but it's a very simple situation with 2 sentinels and one
> master, and a lot of cases are not tested.
>
> Steffen: feel free to argue about this reimplementation, if you think
> things are missing or it's not modular enough or whatnot.

I haven't had a chance to take a look until now, but didn't want to 
delay answering any longer lest you think I'm angry/disappointed/sad/let 
down/whatever. I'm not. My attachment to my code isn't that strong. :)

The only feedback I have is that

+       ) # TODO make the timeout configurable

should probably be done before including it in a stable release and a 
question: My abstraction was to have a Sentinel*s* (plural) object. You 
now have a Sentinel (singular) object. And that's how the code actually 
works. The singular allows you to just subclass. I'm not sure how that 
works with some of the logic that relies on knowing about all sentinels 
rather than just the one you're connected to. I suppose that's owned by 
the top level Redis object?

--Steffen



More information about the Redis mailing list