<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>扇出 on Tony Bai</title><link>https://tonybai.com/tags/%E6%89%87%E5%87%BA/</link><description>Recent content in 扇出 on Tony Bai</description><generator>Hugo</generator><language>zh-cn</language><copyright>2004-2026 Tony Bai. 版权所有.</copyright><lastBuildDate>Sat, 13 Feb 2021 00:00:00 +0800</lastBuildDate><atom:link href="https://tonybai.com/tags/%E6%89%87%E5%87%BA/index.xml" rel="self" type="application/rss+xml"/><item><title>基于Redis Cluster的分布式锁实现以互斥方式操作共享资源</title><link>https://tonybai.com/2021/02/13/operate-with-shared-resources-in-a-mutually-exclusive-way-through-distributed-lock-implemented-by-redis-cluster/</link><pubDate>Sat, 13 Feb 2021 00:00:00 +0800</pubDate><guid>https://tonybai.com/2021/02/13/operate-with-shared-resources-in-a-mutually-exclusive-way-through-distributed-lock-implemented-by-redis-cluster/</guid><description>今天要说的技术方案也是有一定项目背景的。在上一个项目中，我们需要对一个redis集群中过期的key进行处理，这是一个分布式 系统，考虑到高可用性，需要具备过期处理功能的服务有多个副本，这样我们就要求在同一时间内仅有一个副本可以对过期的key&amp;gt;进行处理，如果该副本挂掉，系统会在其他副本中再挑选出一个来处理过期的key。 很显然，这里涉及到一个选主(leader election)的过程。每当涉及选主...</description></item></channel></rss>