doc-exports/docs/dcs/umn/dcs-faq-0730025.html
Chen, Junjie ea05d1a734 DCS UMN Initial Version
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
Co-authored-by: Chen, Junjie <chenjunjie@huawei.com>
Co-committed-by: Chen, Junjie <chenjunjie@huawei.com>
2022-12-12 14:07:56 +00:00

15 lines
2.3 KiB
HTML

<a name="dcs-faq-0730025"></a><a name="dcs-faq-0730025"></a>
<h1 class="topictitle1">Why Is Redisson Distributed Lock Not Supported by DCS Proxy Cluster Redis 3.0 Instances?</h1>
<div id="body1596093268950"><p id="dcs-faq-0730025__en-us_topic_0152099097_p227692415350">Redisson implements lock acquisition and unlocking in the following process:</p>
<ol id="dcs-faq-0730025__en-us_topic_0152099097_ol106890279329"><li id="dcs-faq-0730025__en-us_topic_0152099097_li10690122714325">Redisson lock acquisition and unlocking are implemented by running Lua scripts.</li><li id="dcs-faq-0730025__en-us_topic_0152099097_li13690527103212">During lock acquisition, the <strong id="dcs-faq-0730025__b973819493115">EXISTS</strong>, <strong id="dcs-faq-0730025__b147431491411">HSET</strong>, <strong id="dcs-faq-0730025__b1474319496118">PEXPIRE</strong>, <strong id="dcs-faq-0730025__b574324919119">HEXISTS</strong>, <strong id="dcs-faq-0730025__b18743649813">HINCRBY</strong>, <strong id="dcs-faq-0730025__b37431549912">PEXPIRE</strong>, and <strong id="dcs-faq-0730025__b17441491117">PTTL</strong> commands must be executed in the Lua script.</li><li id="dcs-faq-0730025__en-us_topic_0152099097_li126904275320">During unlocking, the <strong id="dcs-faq-0730025__b6722145010113">EXISTS</strong>, <strong id="dcs-faq-0730025__b472325014114">PUBLISH</strong>, <strong id="dcs-faq-0730025__b1072320501312">HEXISTS</strong>, <strong id="dcs-faq-0730025__b1172313502117">PEXIPRE</strong>, and <strong id="dcs-faq-0730025__b47231850311">DEL</strong> commands must be executed in the Lua script.</li></ol>
<p id="dcs-faq-0730025__en-us_topic_0152099097_p82082536353">In a proxy-based cluster, the proxy processes <strong id="dcs-faq-0730025__b86291151212">PUBLISH</strong> and <strong id="dcs-faq-0730025__b5629135120111">SUBSCRIBE</strong> commands and forwards requests to the Redis server. The <strong id="dcs-faq-0730025__b146301851418">PUBLISH</strong> command cannot be executed in the Lua script.</p>
<p id="dcs-faq-0730025__en-us_topic_0152099097_p10806319113210">As a result, Proxy Cluster DCS Redis 3.0 instances do not support Redisson distributed locks. To use Redisson, resort to Redis 4.0 or 5.0 instead.</p>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dcs-faq-0326021.html">Redis Usage</a></div>
</div>
</div>