url
stringlengths
38
157
content
stringlengths
72
15.1M
https://redis.io/docs/latest/develop/connect/clients/java/jedis/.html
<section class="prose w-full py-12 max-w-none"> <h1> Jedis guide (Java) </h1> <p class="text-lg -mt-5 mb-10"> Connect your Java application to a Redis database </p> <p> <a href="https://github.com/redis/jedis"> Jedis </a> is a synchronous Java client for Redis. Use <a href="/docs/latest/develop/clients/lettuce/"> Lettuce </a> if you need a more advanced Java client that also supports asynchronous and reactive connections. The sections below explain how to install <code> Jedis </code> and connect your application to a Redis database. </p> <p> <code> Jedis </code> requires a running Redis or <a href="/docs/latest/operate/oss_and_stack/install/install-stack/"> Redis Stack </a> server. See <a href="/docs/latest/operate/oss_and_stack/install/"> Getting started </a> for Redis installation instructions. </p> <h2 id="install"> Install </h2> <p> To include <code> Jedis </code> as a dependency in your application, edit the dependency file, as follows. </p> <ul> <li> <p> If you use <strong> Maven </strong> : </p> <div class="highlight"> <pre class="chroma"><code class="language-xml" data-lang="xml"><span class="line"><span class="cl"><span class="nt">&lt;dependency&gt;</span> </span></span><span class="line"><span class="cl"> <span class="nt">&lt;groupId&gt;</span>redis.clients<span class="nt">&lt;/groupId&gt;</span> </span></span><span class="line"><span class="cl"> <span class="nt">&lt;artifactId&gt;</span>jedis<span class="nt">&lt;/artifactId&gt;</span> </span></span><span class="line"><span class="cl"> <span class="nt">&lt;version&gt;</span>5.2.0<span class="nt">&lt;/version&gt;</span> </span></span><span class="line"><span class="cl"><span class="nt">&lt;/dependency&gt;</span> </span></span></code></pre> </div> </li> <li> <p> If you use <strong> Gradle </strong> : </p> <pre tabindex="0"><code>repositories { mavenCentral() } //... dependencies { implementation 'redis.clients:jedis:5.2.0' //... } </code></pre> </li> <li> <p> If you use the JAR files, download the latest Jedis and Apache Commons Pool2 JAR files from <a href="https://central.sonatype.com/"> Maven Central </a> or any other Maven repository. </p> </li> <li> <p> Build from <a href="https://github.com/redis/jedis"> source </a> </p> </li> </ul> <h2 id="connect-and-test"> Connect and test </h2> <p> The following code opens a basic connection to a local Redis server: </p> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="kn">package</span> <span class="nn">org.example</span><span class="o">;</span> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">redis.clients.jedis.UnifiedJedis</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">public</span> <span class="kd">class</span> <span class="nc">Main</span> <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="kd">public</span> <span class="kd">static</span> <span class="kt">void</span> <span class="nf">main</span><span class="o">(</span><span class="n">String</span><span class="o">[]</span> <span class="n">args</span><span class="o">)</span> <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="n">UnifiedJedis</span> <span class="n">jedis</span> <span class="o">=</span> <span class="k">new</span> <span class="n">UnifiedJedis</span><span class="o">(</span><span class="s">"redis://localhost:6379"</span><span class="o">);</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="c1">// Code that interacts with Redis... </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"> <span class="n">jedis</span><span class="o">.</span><span class="na">close</span><span class="o">();</span> </span></span><span class="line"><span class="cl"> <span class="o">}</span> </span></span><span class="line"><span class="cl"><span class="o">}</span> </span></span></code></pre> </div> <p> After you have connected, you can check the connection by storing and retrieving a simple string value: </p> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="o">...</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">String</span> <span class="n">res1</span> <span class="o">=</span> <span class="n">jedis</span><span class="o">.</span><span class="na">set</span><span class="o">(</span><span class="s">"bike:1"</span><span class="o">,</span> <span class="s">"Deimos"</span><span class="o">);</span> </span></span><span class="line"><span class="cl"><span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res1</span><span class="o">);</span> <span class="c1">// OK </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="n">String</span> <span class="n">res2</span> <span class="o">=</span> <span class="n">jedis</span><span class="o">.</span><span class="na">get</span><span class="o">(</span><span class="s">"bike:1"</span><span class="o">);</span> </span></span><span class="line"><span class="cl"><span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res2</span><span class="o">);</span> <span class="c1">// Deimos </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="o">...</span> </span></span></code></pre> </div> <h2 id="more-information"> More information </h2> <p> <code> Jedis </code> has a complete <a href="https://www.javadoc.io/doc/redis.clients/jedis/latest/index.html"> API reference </a> available on <a href="https://javadoc.io/"> javadoc.io/ </a> . The <code> Jedis </code> <a href="https://github.com/redis/jedis"> GitHub repository </a> also has useful docs and examples including a page about handling <a href="https://github.com/redis/jedis/blob/master/docs/failover.md"> failover with Jedis </a> </p> <p> See also the other pages in this section for more information and examples: </p> <nav> <a href="/docs/latest/develop/clients/jedis/connect/"> Connect to the server </a> <p> Connect your Java application to a Redis database </p> <a href="/docs/latest/develop/clients/jedis/produsage/"> Production usage </a> <p> Get your Jedis app ready for production </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/clients/jedis/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/msetnx/.html
<section class="prose w-full py-12"> <h1 class="command-name"> MSETNX </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">MSETNX key value [key value ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 1.0.1 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the number of keys to set. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @write </code> <span class="mr-1 last:hidden"> , </span> <code> @string </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Sets the given keys to their respective values. <code> MSETNX </code> will not perform any operation at all even if just a single key already exists. </p> <p> Because of this semantic <code> MSETNX </code> can be used in order to set different keys representing different fields of a unique logic object in a way that ensures that either all the fields or none at all are set. </p> <p> <code> MSETNX </code> is atomic, so all given keys are set at once. It is not possible for clients to see that some of the keys were updated while others are unchanged. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; MSETNX key1 "Hello" key2 "there" (integer) 1 redis&gt; MSETNX key2 "new" key3 "world" (integer) 0 redis&gt; MGET key1 key2 key3 1) "Hello" 2) "there" 3) (nil) </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> <p> One of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#integers"> Integer reply </a> : <code> 0 </code> if no key was set (at least one key already existed). </li> <li> <a href="../../develop/reference/protocol-spec#integers"> Integer reply </a> : <code> 1 </code> if all the keys were set. </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/msetnx/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/.html
<section class="prose w-full py-12 max-w-none"> <h1> Redis Enterprise Software release notes 7.4.x </h1> <p class="text-lg -mt-5 mb-10"> New Cluster Manager UI enhancements, including Active-Active database management. Full TLS 1.3 support. Automatic recovery configuration. Full IPv6 support, including for internal traffic. Maintenance mode enhancements. Module management enhancements. RHEL 9 support. </p> <p> ​ <a href="https://redis.com/redis-enterprise-software/download-center/software/"> ​Redis Enterprise Software version 7.4 </a> is now available! </p> <h2 id="highlights"> Highlights </h2> <p> This version offers: </p> <ul> <li> <p> New Cluster Manager UI enhancements, including Active-Active database management </p> </li> <li> <p> Full TLS 1.3 support </p> </li> <li> <p> Automatic recovery configuration </p> </li> <li> <p> Full IPv6 support, including for internal traffic </p> </li> <li> <p> Maintenance mode enhancements </p> </li> <li> <p> Module management enhancements </p> </li> <li> <p> RHEL 7 and Oracle Linux 7, which were previously deprecated, are no longer supported </p> </li> <li> <p> RHEL 9 support </p> </li> </ul> <h2 id="detailed-release-notes"> Detailed release notes </h2> <p> For more detailed release notes, select a build version from the following table: </p> <table> <thead> <tr> <th style="text-align:left"> VersionΒ (ReleaseΒ date) </th> <th style="text-align:left"> Major changes </th> <th style="text-align:left"> OSSΒ Redis compatibility </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-6-102/"> 7.4.6-102 (October 2024) </a> </td> <td style="text-align:left"> Updated module feature sets with later versions of RediSearch and RedisTimeSeries. </td> <td style="text-align:left"> Redis 7.2.4 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-6-77/"> 7.4.6-77 (September 2024) </a> </td> <td style="text-align:left"> Updated module feature sets. Bug fixes. </td> <td style="text-align:left"> Redis 7.2.4 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-6-22/"> 7.4.6-22 (July 2024) </a> </td> <td style="text-align:left"> Support for SHA-384 certificates in client authentication. New parameters for optimize_shard_placement and recover database REST API requests. </td> <td style="text-align:left"> Redis 7.2.4 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-216/"> 7.4.2-216 (July 2024) </a> </td> <td style="text-align:left"> region_name field for new AWS S3 regions. Bug fixes. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-169/"> 7.4.2-169 (May 2024) </a> </td> <td style="text-align:left"> Configuration options for cluster management API workers and threads. Reduced Cluster Configuration Store CPU usage. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-129/"> 7.4.2-129 (April 2024) </a> </td> <td style="text-align:left"> Fixes for bugs and known limitations that affect Redis Enterprise Software v7.4.2-126. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-126/"> 7.4.2-126 (April 2024) </a> </td> <td style="text-align:left"> Redis database version selection during database creation in the Cluster Manager UI. New Redis logo. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-104/"> 7.4.2-104 (March 2024) </a> </td> <td style="text-align:left"> New Cluster Manager UI enhancements to change passwords from the sign-in screen, view locked user accounts, and unlock user accounts with password reset. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-54/"> 7.4.2-54 (February 2024) </a> </td> <td style="text-align:left"> New Cluster Manager UI enhancements, including Active-Active database management. Full TLS 1.3 support. Automatic recovery configuration. Full IPv6 support, including for internal traffic. Maintenance mode enhancements. Module management enhancements. RHEL 9 support. </td> <td style="text-align:left"> Redis 7.2.0 </td> </tr> </tbody> </table> <h2 id="version-changes"> Version changes </h2> <h3 id="product-lifecycle-updates"> Product lifecycle updates </h3> <h4 id="end-of-life-policy-extension"> End-of-life policy extension </h4> <p> The end-of-life policy for Redis Enterprise Software versions 6.2 and later has been extended to 24 months after the formal release of the subsequent major version. For the updated end-of-life schedule, see the <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/"> Redis Enterprise Software product lifecycle </a> . </p> <h4 id="supported-upgrade-paths"> Supported upgrade paths </h4> <p> Redis Enterprise Software versions 6.2.4 and 6.2.8 do not support direct upgrades beyond version 7.4.x. Versions 6.2.10, 6.2.12, and 6.2.18 are part of the <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/upgrade-cluster/#supported-upgrade-paths"> upgrade path </a> . To upgrade from 6.2.4 or 6.2.8 to versions later than 7.4.x, an intermediate upgrade is required. </p> <p> The next major Redis Enterprise Software release will still bundle Redis database version 6.2 and allow database upgrades from Redis database version 6.2 to 7.x. </p> <p> See the <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/"> Redis Enterprise Software product lifecycle </a> for more information about release numbers. </p> <h3 id="deprecations"> Deprecations </h3> <h4 id="api-deprecations"> API deprecations </h4> <ul> <li> <p> The replica HA cluster policy is deprecated. </p> </li> <li> <p> The maintenance mode option <code> keep_slave_shards </code> is deprecated in <code> rladmin </code> and the REST API. Use <code> evict_ha_replica </code> and <code> evict_active_active_replica </code> instead. </p> </li> <li> <p> <code> /v1/debuginfo </code> REST API paths are deprecated. Use the new paths <a href="/docs/latest/operate/rs/references/rest-api/requests/cluster/debuginfo/"> <code> /v1/cluster/debuginfo </code> </a> , <a href="/docs/latest/operate/rs/references/rest-api/requests/nodes/debuginfo/"> <code> /v1/nodes/debuginfo </code> </a> , and <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/debuginfo/"> <code> /v1/bdbs/debuginfo </code> </a> instead. </p> </li> </ul> <h4 id="legacy-ui-deprecation"> Legacy UI deprecation </h4> <p> The legacy UI is deprecated in favor of the new Cluster Manager UI and will be removed in a future release. </p> <h4 id="redis-60-database-deprecation"> Redis 6.0 database deprecation </h4> <p> Redis database version 6.0 is deprecated as of Redis Enterprise Software version 7.4.2 and will be removed in a future release. </p> <p> To prepare for the future removal of Redis 6.0: </p> <ul> <li> <p> For Redis Enterprise 6.2.* clusters, upgrade Redis 6.0 databases to Redis 6.2. See the <a href="https://raw.githubusercontent.com/redis/redis/6.2/00-RELEASENOTES"> Redis 6.2 release notes </a> for the list of changes. </p> </li> <li> <p> For Redis Enterprise 7.2.4 and 7.4.x clusters, upgrade Redis 6.0 databases to Redis 7.2. Before you upgrade your databases, see the list of <a href="/docs/latest/operate/rs/release-notes/rs-7-2-4-releases/rs-7-2-4-52/#redis-72-breaking-changes"> Redis 7.2 breaking changes </a> and update any applications that connect to your database to handle these changes. </p> </li> </ul> <h4 id="end-of-triggers-and-functions-preview"> End of triggers and functions preview </h4> <p> The <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/deprecated-features/triggers-and-functions/"> triggers and functions </a> (RedisGears) preview has been discontinued. </p> <ul> <li> <p> Commands such as <code> TFCALL </code> , <code> TFCALLASYNC </code> , and <code> TFUNCTION </code> will be deprecated and will return error messages. </p> </li> <li> <p> Any JavaScript functions stored in Redis will be removed. </p> </li> <li> <p> JavaScript-based triggers will be blocked. </p> </li> <li> <p> Lua functions and scripts will not be affected. </p> </li> </ul> <p> If your database currently uses triggers and functions, you need to: </p> <ol> <li> <p> Adjust your applications to accommodate these changes. </p> </li> <li> <p> Delete all triggers and functions libraries from your existing database: </p> <ol> <li> <p> Run <code> TFUNCTION LIST </code> . </p> </li> <li> <p> Copy all library names. </p> </li> <li> <p> Run <code> TFUNCTION DELETE </code> for each library in the list. </p> </li> </ol> <p> If any triggers and functions libraries remain in the database, the RDB snapshot won't load on a cluster without RedisGears. </p> </li> <li> <p> Migrate your database to a new database without the RedisGears module. </p> </li> </ol> <h4 id="redisgraph-end-of-life"> RedisGraph end of life </h4> <p> Redis has announced the end of life for RedisGraph. Redis will continue to support all RedisGraph customers, including releasing patch versions until January 31, 2025. </p> <p> See the <a href="https://redis.com/blog/redisgraph-eol/"> RedisGraph end-of-life announcement </a> for more details. </p> <h4 id="operating-system-retirements"> Operating system retirements </h4> <ul> <li> RHEL 7 and Oracle Linux 7 were previously announced as deprecated in the <a href="/docs/latest/operate/rs/release-notes/rs-7-2-4-releases/#deprecations"> Redis Enterprise Software 7.2.4 release notes </a> . As of Redis Enterprise Software 7.4.2, RHEL 7 and Oracle Linux 7 are no longer supported. </li> </ul> <h4 id="security-retirements"> Security retirements </h4> <ul> <li> <p> The RC4 encryption cipher, which was previously deprecated in favor of stronger ciphers, is no longer supported. </p> </li> <li> <p> The 3DES encryption cipher, which was previously deprecated in favor of stronger ciphers like AES, is no longer supported. Verify that all clients, applications, and connections support the AES cipher. </p> </li> <li> <p> TLS 1.0 and TLS 1.1 connections, which were previously deprecated in favor of TLS 1.2 or later, are no longer supported. Verify that all clients, applications, and connections support TLS 1.2 or later. </p> </li> </ul> <h3 id="upcoming-changes"> Upcoming changes </h3> <h4 id="default-image-change-for-redis-enterprise-software-containers"> Default image change for Redis Enterprise Software containers </h4> <p> Starting with the next major version, Redis Enterprise Software containers with the image tag <code> x.y.z-build </code> will be based on RHEL instead of Ubuntu. </p> <p> This change will only affect you if you use containers outside the official <a href="/docs/latest/operate/kubernetes/"> Redis Enterprise for Kubernetes </a> product and use Ubuntu-specific commands. </p> <p> To use Ubuntu-based images after this change, you can specify the operating system suffix in the image tag. For example, use the image tag <code> 7.4.2-216.focal </code> instead of <code> 7.4.2-216 </code> . </p> <h3 id="supported-platforms"> Supported platforms </h3> <p> The following table provides a snapshot of supported platforms as of this Redis Enterprise Software release. See the <a href="/docs/latest/operate/rs/references/supported-platforms/"> supported platforms reference </a> for more details about operating system compatibility. </p> <p> <span title="Check mark icon"> βœ… </span> Supported – The platform is supported for this version of Redis Enterprise Software and Redis Stack modules. </p> <p> <span class="font-serif" title="Warning icon"> ⚠️ </span> Deprecation warning – The platform is still supported for this version of Redis Enterprise Software, but support will be removed in a future release. </p> <table> <thead> <tr> <th> Redis Enterprise <br/> major versions </th> <th style="text-align:center"> 7.4 </th> <th style="text-align:center"> 7.2 </th> <th style="text-align:center"> 6.4 </th> <th style="text-align:center"> 6.2 </th> </tr> </thead> <tbody> <tr> <td> <strong> Release date </strong> </td> <td style="text-align:center"> Feb 2024 </td> <td style="text-align:center"> Aug 2023 </td> <td style="text-align:center"> Feb 2023 </td> <td style="text-align:center"> Aug 2021 </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/#endoflife-schedule"> <strong> End-of-life date </strong> </a> </td> <td style="text-align:center"> Determined after <br/> next major release </td> <td style="text-align:center"> Feb 2026 </td> <td style="text-align:center"> Aug 2025 </td> <td style="text-align:center"> Feb 2025 </td> </tr> <tr> <td> <strong> Platforms </strong> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> </tr> <tr> <td> RHEL 9 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> </tr> <tr> <td> RHEL 8 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> RHEL 7 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 20.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Ubuntu 18.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 16.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Amazon Linux 2 </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Amazon Linux 1 </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Kubernetes <sup> <a href="#table-note-3"> 3 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Docker <sup> <a href="#table-note-4"> 4 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> </tbody> </table> <ol> <li> <p> <a name="table-note-1" style="display: block; height: 80px; margin-top: -80px;"> </a> The RHEL-compatible distributions CentOS, CentOS Stream, Alma, and Rocky are supported if they have full RHEL compatibility. Oracle Linux running the Red Hat Compatible Kernel (RHCK) is supported, but the Unbreakable Enterprise Kernel (UEK) is not supported. </p> </li> <li> <p> <a name="table-note-2" style="display: block; height: 80px; margin-top: -80px;"> </a> The server version of Ubuntu is recommended for production installations. The desktop version is only recommended for development deployments. </p> </li> <li> <p> <a name="table-note-3" style="display: block; height: 80px; margin-top: -80px;"> </a> See the <a href="/docs/latest/operate/kubernetes/reference/supported_k8s_distributions/"> Redis Enterprise for Kubernetes documentation </a> for details about support per version and Kubernetes distribution. </p> </li> <li> <p> <a name="table-note-4" style="display: block; height: 80px; margin-top: -80px;"> </a> <a href="/docs/latest/operate/rs/installing-upgrading/quickstarts/docker-quickstart/"> Docker images </a> of Redis Enterprise Software are certified for development and testing only. </p> </li> </ol> <h2 id="known-issues"> Known issues </h2> <ul> <li> <p> RS131972: Creating an ACL that contains a line break in the Cluster Manager UI can cause shard migration to fail due to ACL errors. </p> </li> <li> <p> RS61676: Full chain certificate update fails if any certificate in the chain does not have a Common Name (CN). </p> </li> <li> <p> RS119958: The <code> debuginfo </code> script fails with the error <code> /bin/tar: Argument list too long </code> if there are too many RocksDB log files. This issue only affects clusters with Auto Tiering. </p> </li> <li> <p> RS122570: REST API <code> POST /crdbs </code> responds with a confusing error message if the cluster does not have the requested CRDB-compatible module that complies with the requested featureset. </p> <p> This issue was fixed in <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-126/"> Redis Enterprise Software version 7.4.2-126 </a> . </p> </li> <li> <p> RS123142: In an Active-Active setup with at least three participating clusters, removing and re-adding a cluster after removing older clusters without re-adding them can cause missing keys and potentially lead to data loss or data inconsistency. </p> <p> To prevent this issue, avoid adding clusters until you upgrade to the upcoming maintenance release when available. </p> <p> This issue was fixed in <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-169/"> Redis Enterprise Software version 7.4.2-169 </a> . </p> </li> </ul> <h2 id="known-limitations"> Known limitations </h2> <h4 id="new-cluster-manager-ui-limitations"> New Cluster Manager UI limitations </h4> <p> The following legacy UI features are not yet available in the new Cluster Manager UI: </p> <ul> <li> <p> Remove a node. </p> <p> Use the REST API or legacy UI instead. See <a href="/docs/latest/operate/rs/clusters/remove-node/"> Remove a cluster node </a> for instructions. </p> </li> <li> <p> Purge an Active-Active instance. </p> <p> Use <a href="/docs/latest/operate/rs/references/cli-utilities/crdb-cli/crdb/purge-instance/"> <code> crdb-cli crdb purge-instance </code> </a> instead. </p> </li> <li> <p> Search and export the log. </p> </li> </ul> <h4 id="openssl-compatibility-issue-for-742-modules-on-amazon-linux-2"> OpenSSL compatibility issue for 7.4.2 modules on Amazon Linux 2 </h4> <p> Due to an OpenSSL 1.1 compatibility issue between modules and clusters, Redis Enterprise Software version 7.4.2-54 is not fully supported on Amazon Linux 2 clusters with databases that use the following modules: RedisGears, RediSearch, or RedisTimeSeries. </p> <p> This issue will be fixed in a future maintenance release. </p> <h4 id="redisgraph-prevents-upgrade-to-rhel-9"> RedisGraph prevents upgrade to RHEL 9 </h4> <p> You cannot upgrade from a prior RHEL version to RHEL 9 if the Redis Enterprise cluster contains a RedisGraph module, even if unused by any database. The <a href="https://redis.com/blog/redisgraph-eol/"> RedisGraph module has reached End-of-Life </a> and is completely unavailable in RHEL 9. </p> <h4 id="cannot-create-redis-v6x-active-active-databases-with-modules"> Cannot create Redis v6.x Active-Active databases with modules </h4> <p> You cannot create Active-Active databases that use Redis version 6.0 or 6.2 with modules. Databases that use Redis version 7.2 do not have this limitation. </p> <p> This limitation was fixed in <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-104/"> Redis Enterprise Software version 7.4.2-104 </a> . </p> <h4 id="firewalld-configuration-fails-on-rhel-9-due-to-file-permissions"> Firewalld configuration fails on RHEL 9 due to file permissions </h4> <p> When you install Redis Enterprise Software version 7.4.2 on RHEL 9, <code> firewalld </code> configuration fails to add the <code> redislabs </code> service if <code> /etc/firewalld/services/redislabs-clients.xml </code> and <code> /etc/firewalld/services/redislabs.xml </code> are owned by <code> redislabs </code> instead of <code> root </code> . </p> <p> As a workaround: </p> <ol> <li> <p> Change the files' owner and group to <code> root </code> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ chown root:root /etc/firewalld/services/redislabs-clients.xml </span></span><span class="line"><span class="cl">$ chown root:root /etc/firewalld/services/redislabs.xml </span></span></code></pre> </div> </li> <li> <p> Add the <code> redislabs </code> service to <code> firewalld </code> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ systemctl daemon-reload </span></span><span class="line"><span class="cl">$ systemctl restart firewalls </span></span><span class="line"><span class="cl">$ /bin/firewall-cmd --add-service<span class="o">=</span>redislabs </span></span></code></pre> </div> </li> </ol> <p> This limitation was fixed in <a href="/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-129/"> Redis Enterprise Software version 7.4.2-129 </a> . </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.8-release-notes.html
<section class="prose w-full py-12 max-w-none"> <h1> RediSearch 2.8 release notes </h1> <p class="text-lg -mt-5 mb-10"> RESP3 support. Geo Polygon Search. Performance improvements. </p> <h2 id="requirements"> Requirements </h2> <p> RediSearch v2.8.17 requires: </p> <ul> <li> Minimum Redis compatibility version (database): 7.2 </li> <li> Minimum Redis Enterprise Software version (cluster): 7.2.4 </li> </ul> <h2 id="v2817-august-2024"> v2.8.17 (August 2024) </h2> <p> This is a maintenance release for RediSearch 2.8 </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/redisearch/redisearch/pull/4941"> #4941 </a> Adjusting the module configuration to avoid routing overload on the first shard in a clustered database (MOD-7505) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4950"> #4950 </a> <code> FT.PROFILE </code> on <code> AGGREGATE </code> numeric queries could cause a crash due to reusing internal <code> CURSOR </code> in large range of numeric values (MOD-7454) </li> </ul> </li> </ul> <h2 id="v2816-august-2024"> v2.8.16 (August 2024) </h2> <p> This is a maintenance release for RediSearch 2.8 </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/redisearch/redisearch/pull/4896"> #4896 </a> - <code> FT.AGGREGATE </code> with <code> VERBATIM </code> option is not handled by the shards in cluster mode (MOD-7463) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4917"> #4917 </a> - Union query, similar to <code> "is|the" </code> , starting with 2 <a href="https://redis.io/docs/latest/develop/interact/search-and-query/advanced-concepts/stopwords/"> stopwords </a> could cause a crash (MOD-7495) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4921"> #4921 </a> - Counting twice the field statistics at the <code> #search </code> section of an <code> INFO </code> response (MOD-7339) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4939"> #4939 </a> - Query warning when using RESP3 response for reaching <code> MAXPREFIXEXPANSION </code> (MOD-7588) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4930"> #4930 </a> - Loop when using the wildcard <code> w'term' </code> and prefix/infix/suffix pattern <code> 'ter*' </code> leading shard to restart (MOD-7453) </li> <li> <a href="https://github.com/redisearch/redisearch/pull/4912"> #4912 </a> - Avoid stemming expansion when querying for numeric values (MOD-7025) </li> </ul> </li> </ul> <h2 id="v2815-july-2024"> v2.8.15 (July 2024) </h2> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4754"> #4754 </a> - Correct return the maximum value for negative values when using <code> MAX </code> reducer (MOD-7252) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4737"> #4737 </a> - Separators ignored when escaping backslash <code> \ </code> after the escaped character such as in <code> hello\\,world </code> ignoring <code> , </code> (MOD-7240) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4717"> #4717 </a> - Sorting by multiple fields <code> SORTBY 2 @field1 @field2 </code> was ignoring the subsequent field(MOD-7206) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4803"> #4803 </a> - Keys expiring during query returning empty array (MOD-7010) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4794"> #4794 </a> - Index sanitiser (GC) trying to clean deleted numeric index could cause a crash (MOD-7303) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4792"> #4792 </a> - Add character validations to simple string replies and escape it when required(MOD-7258) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4768"> #4768 </a> - Indicate which value is missing on the error message at the aggregation pipeline (MOD-7201) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4745"> #4745 </a> - <code> GROUPBY </code> recursion cleanup (MOD-7245) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4823"> #4823 </a> - Mechanism of keys expiration during the query execution clearing intermediate results </li> </ul> </li> </ul> <h2 id="v2814-june-2024"> v2.8.14 (June 2024) </h2> <p> This is a maintenance release for RediSearch 2.8 </p> <p> Update urgency: <code> MODERATE </code> : Program an upgrade of the server, but it's not urgent. </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4614"> #4614 </a> Shards become unresponsive when using <code> FT.AGGREGATE </code> with <code> APPLY 'split(...)' </code> (MOD-6759) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4556"> #4556 </a> <code> FT.EXPLAIN </code> returns additional <code> } </code> when querying using wildcards (MOD-6768) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4646"> #4646 </a> <code> FT.DROPINDEX </code> with <code> DD </code> flag deleted keys in one AA cluster but not the others (MOD-1855) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4595"> #4595 </a> Report memory of the <code> TAG </code> and <code> TEXT </code> tries (MOD-5902) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4669"> #4669 </a> Inverted index memory counting (MOD-5977,MOD-5866) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4687"> #4687 </a> Add missing <code> FT.INFO </code> fields when used within a cluster (MOD-6920) </li> </ul> </li> </ul> <h2 id="v2813-march-2024"> v2.8.13 (March 2024) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4481"> #4481 </a> Query syntax on <code> GEOSHAPE </code> accepting just prefix instead of complete predicate (MOD-6663) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4513"> #4513 </a> <code> FT.CURSOR READ </code> in a numeric query causing a crash (MOD-6597) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4534"> #4534 </a> <code> FT.PROFILE </code> with incorrect arguments could cause a crash on cluster setup (MOD-6791) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4530"> #4530 </a> Some parameter settings using just prefixes instead of full values were working (MOD-6709) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4539"> #4539 </a> Unfree memory while re-indexing a new RDB as it's loading could cause a crash (MOD-6831, 6810) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4498"> #4498 </a> Vector pre-filtered query (hybrid query) that times out causing a crash due to deadlock when trying to write a new document (MOD-6510, MOD-6244) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4495"> #4495 </a> <code> FT.SEARCH </code> accessing an inexistent memory address causes a crash if using the deprecated <code> FT.ADD </code> command (MOD-6599) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4502"> #4502 </a> Handle error properly when trying to execute Search commands on cluster setup as part of <code> MULTI ... EXEC </code> or LUA script (MOD-6541) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4526"> #4526 </a> Adding detailed geometry info on error messages (MOD-6701) </li> </ul> </li> </ul> <h2 id="v2812-march-2024"> v2.8.12 (March 2024) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> MODERATE </code> : Program an upgrade of the server, but it's not urgent. </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4476"> #4476 </a> Split <code> INFIX </code> and <code> SUFFIX </code> report on <code> FT.EXPLAIN </code> and <code> FT.EXPLAINCLI </code> (MOD-6186) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4467"> #4467 </a> Memory leak upon suffix query for a <code> TAG </code> indexed with <code> WITHSUFFIXTRIE </code> (MOD-6644) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4403"> #4403 </a> Clustered <code> FT.SEARCH </code> hangs forever without replying when an invalid topology is found (MOD-6557) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4355"> #4355 </a> Searching for a synonym will iterate in the same group multiple times, causing a performance hit (MOD-6490) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4313"> #4313 </a> Memory allocation patterns on the memory used to query <code> GEOSHAPE </code> types (MOD-6431) </li> </ul> </li> </ul> <h2 id="v2811-january-2024"> v2.8.11 (January 2024) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> MODERATE </code> : Program an upgrade of the server, but it's not urgent. </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4324"> #4324 </a> Internal cluster mechanism not waiting until all replies from shards causing a crash (MOD-6287) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4297"> #4297 </a> Execution loader when using <code> FT.AGGREGATE </code> with <code> LOAD </code> stage failing to buffer the right results potentially causing a crash (MOD-6385) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4264"> #4264 </a> Granularity of the time reporting counters on <code> FT.PROFILE </code> (MOD-6002) </li> </ul> </li> </ul> <h2 id="v2810-january-2024"> v2.8.10 (January 2024) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4287"> #4287 </a> Re-index process while syncing from the replica causes a crash due to internal index variable initialization (MOD-6337, MOD-6336) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4249"> #4249 </a> Memory tracking on cluster setups causing high memory usage and potentially Out-of-Memory (MOD-6123, MOD-5639) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4244"> #4244 </a> Profiling <code> FT.AGGREGATE </code> using the <code> WITHCURSOR </code> flag with a <code> - </code> clause causes a crash due to timeout (MOD-5512) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3916"> #3916 </a> Expiring <code> JSON </code> documents while querying it causing a crash due to deadlock (MOD-5769, MOD-5895, MOD-6189, MOD-5895) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4235"> #4235 </a> Memory excessively growing on databases caused by unbalanced nodes on inverted index trie (MOD-5880, MOD-5952, MOD-6003) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4190"> #4190 </a> Profiling <code> FT.AGGREGATE </code> causes a crash on RESP3 replies (MOD-6250, MOD-6295) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4148"> #4148 </a> , <a href="https://github.com/RediSearch/RediSearch/pull/4038"> #4038 </a> <code> ON_TIMEOUT FAIL\RETURN </code> policies in the cluster setup not being respected (MOD-6035, MOD-5948, MOD-6090) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4110"> #4110 </a> Format of error response contains inconsistencies when timing out (MOD-6011, MOD-5965) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4104"> #4104 </a> <code> FT.SEARCH </code> not responding when using TLS encryption on Amazon Linux 2 (MOD-6012) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4009"> #4009 </a> In cluster setup does not return a timeout error for <code> FT.SEARCH </code> (MOD-5911) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3920"> #3920 </a> In cluster setup does not return a timeout error for <code> FT.AGGREGATE </code> (MOD-5209) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3914"> #3914 </a> <code> FT.CURSOR READ </code> with geo queries causing a crash when data is updated between the cursor reads (MOD-5646) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4220"> #4220 </a> Server crash when attempting to run the ForkGC (Garbage Collection routine) after dropping the index (MOD-6276) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3682"> #3682 </a> Report last key error and field type indexing failures on <code> FT.INFO </code> (MOD-5364) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4236"> #4236 </a> Adding Vector index parameters at the <code> FT.INFO </code> report (MOD-6198) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4196"> #4196 </a> Check for timeout after results processing in <code> FT.SEARCH </code> on cluster setup (MOD-6278) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4164"> #4164 </a> Report <code> TIMEOUT </code> , <code> MAXPREFIXEXPANSION </code> warnings in RESP3 replies (MOD-6234) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4165"> #4165 </a> Indicate timeout on <code> FT.PROFILE </code> report (MOD-6184) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4149"> #4149 </a> Indicate timeout from Cursor on <code> FAIL </code> timeout policy (MOD-5990) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4147"> #4147 </a> Initialization of the maximum numeric value range leading to a better balance of the index leaf splitting (MOD-6232) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3940"> #3940 </a> Query optimization when predicate contains multiple <code> INTERSECTION </code> (AND) of <code> UNION </code> (OR) (MOD-5910) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4059"> #4059 </a> Return cursor id when experiencing a timeout, when the policy is <code> ON_TIMEOUT RETURN </code> (MOD-5966) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/4006"> #4006 </a> Possibly problematic index name alias validation (MOD-5945) </li> </ul> </li> </ul> <h2 id="v289-october-2023"> v2.8.9 (October 2023) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3874"> #3874 </a> Heavy document updates causing memory growth once memory blocks weren't properly released (MOD-5181) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3967"> #3967 </a> Resharding optimizations causing the process to get stuck (MOD-5874, MOD-5864) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3892"> #3892 </a> After cleaning the index the GC could cause corruption on unique values (MOD-5815) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3853"> #3853 </a> Queries with <code> WITHCURSOR </code> making memory growth since <code> CURSOR </code> wasn't invalidated in the shards (MOD-5580) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3938"> #3938 </a> Propagating error messages in multiple shards database, instead of failing silently (MOD-5211) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3903"> #3903 </a> Added support for Rocky Linux 9 and RHEL9 (MOD-5759) </li> </ul> </li> </ul> <h2 id="v288-september-2023"> v2.8.8 (September 2023) </h2> <p> This is a maintenance release for RediSearch 2.8. </p> <p> Update urgency: <code> SECURITY </code> : There are security fixes in the release. </p> <p> Details: </p> <ul> <li> <p> Security and privacy: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3788"> #3788 </a> Don’t expose internal cluster commands (MOD-5706) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3844"> #3844 </a> Limits maximum phonetic length avoiding to be exploit (MOD 5767) </li> </ul> </li> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3771"> #3771 </a> Broken <code> lower() </code> and <code> upper() </code> functions on <code> APPLY </code> stage in <code> FT.AGGREGATE </code> in <code> DIALECT 3 </code> (MOD-5041) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3752"> #3752 </a> Setting low <code> MAXIDLE </code> parameter value in <code> FT.AGGREGATE </code> cause a crash (MOD-5608) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3780"> #3780 </a> Wrong document length calculation causing incorrect score values (MOD-5622) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3808"> #3808 </a> <code> LOAD </code> step after a <code> FILTER </code> step could cause a crash on <code> FT.AGGREGATE </code> (MOD-5267) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3823"> #3823 </a> <code> APPLY </code> or <code> FILTER </code> parser leak (MOD-5751) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3837"> #3837 </a> Connection using TLS fail on Redis 7.2 (MOD-5768) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3856"> #3856 </a> Adding new nodes to OSS cluster causing a crash (MOD-5778) </li> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3854"> #3854 </a> Vector range query could cause Out-of-Memory due to a memory corruption (MOD-5791) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3534"> #3534 </a> Vector Similarity 0.7.1 (MOD-5624) </li> </ul> </li> </ul> <h2 id="v28-ga-v284-july-2023"> v2.8 GA (v2.8.4) (July 2023) </h2> <p> This is the General Availability release of RediSearch 2.8. </p> <h3 id="headlines"> Headlines </h3> <p> RediSearch 2.8 introduces support for RESP3, new features, performance improvements, and bug fixes. </p> <h3 id="whats-new-in-284"> What's new in 2.8.4 </h3> <p> This new major version introduces new and frequently asked for Geo Polygon Search, adding the <code> GEOSHAPE </code> field type that supports polygon shapes using <a href="https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry"> WKT notation </a> . Besides the current <code> GEO </code> (alias for <code> GEOPOINT </code> ) used in geo range queries, we add support for <code> POLYGON </code> and <code> POINT </code> as new geo shape formats (new <code> GEOSHAPE </code> ). In addition, 2.8 brings performance improvements for <code> SORT BY </code> operations using <code> FT.SEARCH </code> and <code> FT.AGGREGATE </code> , and new <code> FORMAT </code> for enhanced responses on <code> FT.SEARCH </code> and <code> FT.AGGREGATE </code> in RESP3 only. </p> <p> Features: </p> <ul> <li> <p> Introduce support for geo polygon shapes and queries: </p> <ul> <li> <p> Adding <code> GEOSHAPE </code> <a href="/docs/latest/commands/ft.create"> field type </a> to map polygons in the <code> SCHEMA </code> on <code> FT.CREATE </code> (MOD-4798) </p> </li> <li> <p> Support for polygons <code> POLYGON </code> and <code> POINT </code> using <a href="https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry"> WKT notation </a> , for example <code> POLYGON((lon1 lat1, lon2 lat2, ...)) </code> </p> </li> <li> <p> Adjust the <a href="/docs/latest/commands/ft.search#examples"> query syntax </a> on <code> FT.SEARCH </code> for polygons using the predicate <code> @geom:[OPERATOR $poly] </code> and defining polygon in WKT format as <code> PARAMS 2 poly "POLYGON((10 20, ...))" </code> using <code> DIALECT 3 </code> </p> </li> <li> <p> Initially <code> WITHIN </code> and <code> CONTAINS </code> operators with <code> GEOSHAPES </code> for now </p> </li> <li> <p> Support multiple coordinate systems: cartesian (X,Y) with the flag <code> FLAT </code> for flat earth and geographic (lon, lat) using the flag <code> SPHERICAL </code> (MOD-5303). Geographic coordinate system using spherical indexing as default ( <code> SPHERICAL </code> ) </p> </li> <li> <p> Add memory usage per Geometry Index in the <code> FT.INFO </code> response report (MOD-5278) </p> </li> </ul> </li> <li> <p> Introduce performance optimization for sorting operations on <code> FT.SEARCH </code> and <code> FT.AGGREGATE </code> as default on <code> DIALECT 4 </code> . It will improve performance in 4 different scenarios, listed below: </p> <ul> <li> <p> Skip Sorter - applied when there is no sort of any kind. The query can return once it reaches the <code> LIMIT </code> requested results. </p> </li> <li> <p> Partial Range - applied when there is a <code> SORTBY </code> a numeric field, with no filter or filter by the same numeric field, the query iterates on a range large enough to satisfy the <code> LIMIT </code> requested results. </p> </li> <li> <p> Hybrid - applied when there is a <code> SORTBY </code> a numeric field in addition to another non-numeric filter. Some results will get filtered, and the initial range may not be large enough. The iterator then is rewinded with the following ranges, and an additional iteration takes place to collect <code> LIMIT </code> requested results. </p> </li> <li> <p> No optimization - If there is a sort by score or by non-numeric field, there is no other option but to retrieve all results and compare their values. </p> </li> </ul> </li> <li> <p> Add <code> WITHCOUNT </code> argument that allow return accurate counts for the query results with sorting. This operation processes all results in order to get accurate count, being less performant than the optimized option (default behavior on <code> DIALECT 4 </code> ) (MOD-5311) </p> </li> <li> <p> New <code> FORMAT </code> argument in <code> FT.SEARCH </code> and <code> FT.AGGREGATE </code> to retrieve the results as JSON strings or RESP3 hierarchical structures (RESP3 only) (MOD-5390) </p> </li> </ul> <p> Improvements (since 2.8.3): </p> <ul> <li> <p> <a href="https://github.com/RediSearch/RediSearch/pull/3717"> #3717 </a> - Polygon shapes validation and orientation correction when clockwise (MOD-5575) </p> </li> <li> <p> <a href="https://github.com/RediSearch/RediSearch/pull/3534"> #3534 </a> - Vector Similarity [ <a href="https://github.com/RedisAI/VectorSimilarity/releases/tag/v0.7.0"> 0.7.0 </a> ] </p> </li> <li> <p> <a href="https://github.com/RediSearch/RediSearch/pull/3657"> #3657 </a> - Allow GC calls for all tiered indexes in the schema </p> </li> <li> <p> <a href="https://github.com/RediSearch/RediSearch/pull/3701"> #3701 </a> - HNSW is now using data blocks to store vectors and metadata instead of array </p> </li> </ul> <p> Changed behavior: </p> <ul> <li> <a href="https://github.com/RediSearch/RediSearch/pull/3355"> #3355 </a> , <a href="https://github.com/RediSearch/RediSearch/pull/3635"> #3635 </a> Expired keys deleted from replica's index, returning an empty array instead of <code> nil </code> (MOD-4739) </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> <ul> <li> <p> The version inside Redis will be 2.8.4 in semantic versioning. Since the version of a module in Redis is numeric, we could not add a GA flag. </p> </li> <li> <p> Minimal Redis version: 7.2 </p> </li> <li> <p> If indexing and querying RedisJSON data structures, this version is best combined with RedisJSON 2.6 (v2.6.0 onwards). </p> </li> </ul> </div> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.8-release-notes/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/apis.html
<section class="prose w-full py-12 max-w-none"> <h1> APIs </h1> <p class="text-lg -mt-5 mb-10"> An overview of Redis APIs for developers and operators </p> <p> Redis provides a number of APIs for developers and operators. The following sections provide you easy access to the client API, the several programmability APIs, the RESTFul management APIs and the Kubernetes resource defintions. </p> <h2 id="apis-for-developers"> APIs for Developers </h2> <h3 id="client-api"> Client API </h3> <p> Redis comes with a wide range of commands that help you to develop real-time applications. You can find a complete overview of the Redis commands here: </p> <ul> <li> <a href="/docs/latest/commands/"> Redis commands </a> </li> </ul> <p> As a developer, you will likely use one of our supported client libraries for connecting and executing commands. </p> <ul> <li> <a href="/docs/latest/develop/clients/"> Connect with Redis clients introduction </a> </li> </ul> <h3 id="programmability-apis"> Programmability APIs </h3> <p> The existing Redis commands cover most use cases, but if low latency is a critical requirement, you might need to extend Redis' server-side functionality. </p> <p> Lua scripts have been available since early versions of Redis. With Lua, the script is provided by the client and cached on the server side, which implies the risk that different clients might use a different script version. </p> <ul> <li> <a href="/docs/latest/develop/interact/programmability/lua-api/"> Redis Lua API reference </a> </li> <li> <a href="/docs/latest/develop/interact/programmability/eval-intro/"> Scripting with Lua introduction </a> </li> </ul> <p> The Redis functions feature, which became available in Redis 7, supersedes the use of Lua in prior versions of Redis. The client is still responsible for invoking the execution, but unlike the previous Lua scripts, functions can now be replicated and persisted. </p> <ul> <li> <a href="/docs/latest/develop/interact/programmability/functions-intro/"> Functions and scripting in Redis 7 and beyond </a> </li> </ul> <p> If none of the previous methods fulfills your needs, then you can extend the functionality of Redis with new commands using the Redis Modules API. </p> <ul> <li> <a href="/docs/latest/develop/reference/modules/"> Redis Modules API introduction </a> </li> <li> <a href="/docs/latest/develop/reference/modules/modules-api-ref/"> Redis Modules API reference </a> </li> </ul> <h2 id="apis-for-operators"> APIs for Operators </h2> <h3 id="redis-cloud-api"> Redis Cloud API </h3> <p> Redis Cloud is a fully managed Database as a Service offering and the fastest way to deploy Redis at scale. You can programmatically manage your databases, accounts, access, and credentials using the Redis Cloud REST API. </p> <ul> <li> <a href="/docs/latest/operate/rc/api/"> Redis Cloud REST API introduction </a> </li> <li> <a href="/docs/latest/operate/rc/api/examples/"> Redis Cloud REST API examples </a> </li> <li> <a href="https://api.redislabs.com/v1/swagger-ui.html"> Redis Cloud REST API reference </a> </li> </ul> <h3 id="redis-enterprise-software-api"> Redis Enterprise Software API </h3> <p> If you have installed Redis Enterprise Software, you can automate operations with the Redis Enterprise REST API. </p> <ul> <li> <a href="/docs/latest/operate/rs/references/rest-api/"> Redis Enterprise Software REST API introduction </a> </li> <li> <a href="/docs/latest/operate/rs/references/rest-api/requests/"> Redis Enterprise Software REST API requests </a> </li> <li> <a href="/docs/latest/operate/rs/references/rest-api/objects/"> Redis Enterprise Software REST API objects </a> </li> </ul> <h3 id="redis-enterprise-for-kubernetes-api"> Redis Enterprise for Kubernetes API </h3> <p> If you need to install Redis Enterprise on Kubernetes, then you can use the <a href="/docs/latest/operate/kubernetes/"> Redis Enterprise for Kubernetes Operators </a> . You can find the resource definitions here: </p> <ul> <li> <a href="/docs/latest/operate/kubernetes/reference/redis_enterprise_cluster_api/"> Redis Enterprise Cluster API </a> </li> <li> <a href="/docs/latest/operate/kubernetes/reference/redis_enterprise_database_api/"> Redis Enterprise Database API </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/apis/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/kubernetes/active-active/edit-clusters/.html
<section class="prose w-full py-12 max-w-none"> <h1> Edit participating clusters for Active-Active database </h1> <p class="text-lg -mt-5 mb-10"> Steps to add or remove a participating cluster to an existing Active-Active database with Redis Enterprise for Kubernetes. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> This feature is supported for general availability in releases 6.4.2-6 and later. Some of these features were available as a preview in 6.4.2-4 and 6.4.2-5. Please upgrade to 6.4.2-6 for the full set of general availability features and bug fixes. and later. </div> </div> <h2 id="add-a-participating-cluster"> Add a participating cluster </h2> <p> Use the following steps to add a participating cluster to an existing Redis Enterprise Active-Active database (REAADB) for Kubernetes. </p> <h3 id="prerequisites"> Prerequisites </h3> <p> To prepare the Redis Enterprise cluster (REC) to participate in an Active-Active database, perform the following tasks from <a href="/docs/latest/operate/kubernetes/active-active/prepare-clusters/"> Prepare participating clusters </a> : </p> <ul> <li> Make sure the cluster meets the hardware and naming requirements. </li> <li> Enable the Active-Active controllers. </li> <li> Configure external routing. </li> <li> Configure <code> ValidatingWebhookConfiguration </code> . </li> </ul> <h3 id="collect-rec-credentials"> Collect REC credentials </h3> <p> To communicate with other clusters, all participating clusters need access to the admin credentials for all other clusters. </p> <ol> <li> <p> Get the REC credentials secret for the new participating cluster. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get secret -o yaml &lt;rec-name&gt; </span></span></code></pre> </div> <p> This example shows an admin credentials secret for an REC named <code> rec-boston </code> : </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">apiVersion</span><span class="p">:</span><span class="w"> </span><span class="l">v1</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">data</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l">ABcdef12345</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l">GHij56789</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">kind</span><span class="p">:</span><span class="w"> </span><span class="l">Secret</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">metadata</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l">rec-boston</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l">Opaque</span><span class="w"> </span></span></span></code></pre> </div> </li> <li> <p> Create a secret for the new participating cluster named <code> redis-enterprise-&lt;rerc&gt; </code> and add the username and password. </p> <p> The example below shows a secret file for a remote cluster named <code> rerc-logan </code> . </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">apiVersion</span><span class="p">:</span><span class="w"> </span><span class="l">v1</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">data</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l">ABcdef12345</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l">GHij56789</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">kind</span><span class="p">:</span><span class="w"> </span><span class="l">Secret</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">metadata</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l">redis-enterprise-rerc-logan</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l">Opaque</span><span class="w"> </span></span></span></code></pre> </div> </li> <li> <p> Apply the file of collected secrets to every participating REC. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl apply -f &lt;rec-secret-file&gt; </span></span></code></pre> </div> </li> </ol> <p> If the admin credentials for any of the clusters change, update and reapply the file to all clusters. </p> <h3 id="create-rerc"> Create RERC </h3> <ol> <li> <p> From one of the existing participating clusters, create a <code> RedisEnterpriseRemoteCluster </code> (RERC) custom resource for the new participating cluster. </p> <p> This example shows an RERC custom resource for an REC named <code> rec-boston </code> in the namespace <code> ns-massachusetts </code> . </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">apiVersion</span><span class="p">:</span><span class="w"> </span><span class="l">app.redislabs.com/v1alpha1</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">kind</span><span class="p">:</span><span class="w"> </span><span class="l">RedisEnterpriseRemoteCluster</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">metadata</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l">rerc-logan</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">spec</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">recName</span><span class="p">:</span><span class="w"> </span><span class="l">rec-boston</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">recNamespace</span><span class="p">:</span><span class="w"> </span><span class="l">ns-massachusetts</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">apiFqdnUrl</span><span class="p">:</span><span class="w"> </span><span class="l">test-example-api-rec-boston-ns-massachusetts.example.com</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">dbFqdnSuffix</span><span class="p">:</span><span class="w"> </span>-<span class="l">example-cluster-rec-boston-ns-massachusetts.example.com</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">secretName</span><span class="p">:</span><span class="w"> </span><span class="l">redis-enterprise-rerc-logan</span><span class="w"> </span></span></span></code></pre> </div> </li> <li> <p> Create the RERC custom resource. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl create -f &lt;new-RERC-file&gt; </span></span></code></pre> </div> </li> <li> <p> Check the status of the newly created RERC custom resource. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get rerc &lt;RERC-name&gt; </span></span></code></pre> </div> <p> The output should look like this: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">NAME STATUS SPEC STATUS LOCAL </span></span><span class="line"><span class="cl">rerc-logan Active Valid <span class="nb">true</span> </span></span></code></pre> </div> </li> </ol> <h3 id="edit-reaadb-spec"> Edit REAADB spec </h3> <ol> <li> <p> Patch the REAADB spec to add the new RERC name to the <code> participatingClusters </code> , replacing <code> &lt;reaadb-name&gt; </code> and <code> &lt;rerc-name&gt; </code> with your own values. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl patch reaadb &lt;reaadb-name&gt; &lt; --type merge --patch <span class="s1">'{"spec": {"participatingClusters": [{"name": "&lt;rerc-name&gt;"}]}}'</span> </span></span></code></pre> </div> </li> <li> <p> View the REAADB <code> participatingClusters </code> status to verify the cluster was added. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get reaadb &lt;reaadb-name&gt; -o<span class="o">=</span><span class="nv">jsonpath</span><span class="o">=</span><span class="s1">'{.status.participatingClusters}'</span> </span></span></code></pre> </div> <p> The output should look like this: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl"><span class="o">[{</span><span class="s2">"id"</span>:1,<span class="s2">"name"</span>:<span class="s2">"rerc-ohare"</span><span class="o">}</span>,<span class="o">{</span><span class="s2">"id"</span>:2,<span class="s2">"name"</span>:<span class="s2">"rerc-reagan"</span><span class="o">}</span>,<span class="o">{</span><span class="s2">"id"</span>:3,<span class="s2">"name"</span>:<span class="s2">"rerc-logan"</span><span class="o">}]</span> </span></span></code></pre> </div> </li> </ol> <h2 id="remove-a-participating-cluster"> Remove a participating cluster </h2> <ol> <li> <p> On an existing participating cluster,remove the desired cluster from the <code> participatingCluster </code> section of the REAADB spec. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl edit reaadb &lt;reaadb-name&gt; </span></span></code></pre> </div> </li> <li> <p> On each of the other participating clusters, verify the status is <code> active </code> and the spec status is <code> Valid </code> and the cluster was removed. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get reaadb &lt;reaadb-name -o<span class="o">=</span><span class="nv">jasonpath</span><span class="o">=</span><span class="sb">`</span><span class="o">{</span>.status<span class="o">}</span><span class="sb">`</span> </span></span></code></pre> </div> <p> The output should look like this: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl"><span class="o">{</span>... ,<span class="s2">"participatingClusters"</span>:<span class="o">[{</span><span class="s2">"id"</span>:1,<span class="s2">"name"</span>:<span class="s2">"rerc1"</span><span class="o">}</span>,<span class="o">{</span><span class="s2">"id"</span>:2,<span class="s2">"name"</span>:<span class="s2">"rerc2"</span><span class="o">}]</span>,<span class="s2">"redisEnterpriseCluster"</span>:<span class="s2">"rec1"</span>,<span class="s2">"specStatus"</span>:<span class="s2">"Valid"</span>,<span class="s2">"status"</span>:<span class="s2">"active"</span><span class="o">}</span> </span></span></code></pre> </div> </li> <li> <p> On the removed participating cluster, list all REAADB resources on the cluster to verify they were deleted. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get reaadb -o+jasonpath<span class="o">=</span><span class="sb">`</span><span class="o">{</span>range.items<span class="o">[</span>*<span class="o">]}{</span>.metadata.name<span class="o">}</span><span class="sb">`</span> </span></span></code></pre> </div> </li> </ol> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/kubernetes/active-active/edit-clusters/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/job_scheduler/log_rotation_job_settings/.html
<section class="prose w-full py-12 max-w-none"> <h1> Log rotation job settings object </h1> <p class="text-lg -mt-5 mb-10"> Documents the log_rotation_job_settings object used with Redis Enterprise Software REST API calls. </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> cron_expression </td> <td> string </td> <td> <a href="https://en.wikipedia.org/wiki/Cron#CRON_expression"> CRON expression </a> that defines the log rotation schedule </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/job_scheduler/log_rotation_job_settings/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/job_scheduler/cert_rotation_job_settings/.html
<section class="prose w-full py-12 max-w-none"> <h1> Certificate rotation job settings object </h1> <p class="text-lg -mt-5 mb-10"> Documents the cert_rotation_job_settings object used with Redis Enterprise Software REST API calls. </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> cron_expression </td> <td> string </td> <td> <a href="https://en.wikipedia.org/wiki/Cron#CRON_expression"> CRON expression </a> that defines the certificate rotation schedule </td> </tr> <tr> <td> expiry_days_before_rotation </td> <td> integer, (range:Β 1-90) (default:Β 60) </td> <td> Number of days before a certificate expires before rotation </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/job_scheduler/cert_rotation_job_settings/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/clusters/optimize/disk-sizing-heavy-write-scenarios/.html
<section class="prose w-full py-12 max-w-none"> <h1> Disk sizing for heavy write scenarios </h1> <p class="text-lg -mt-5 mb-10"> Sizing considerations for persistent disk space for heavy throughput databases. </p> <p> In extreme write scenarios, when AOF is enabled, the AOF rewrite process may require considerably more disk space for database persistence. </p> <p> To estimate the required persistent disk space in such cases, use the formula described below. </p> <p> <strong> The required persistent disk space for AOF rewrite purposes in extreme write scenarios, assuming identical shard sizes: </strong> </p> <p> <strong> X (1 + 3Y +YΒ²) </strong> where: <strong> X </strong> = each shard size <strong> Y </strong> = number of shards </p> <p> Following are examples of database configurations and the persistence disk space they would require in this scenario: </p> <table> <thead> <tr> <th> </th> <th> Example 1 </th> <th> Example 2 </th> <th> Example 3 </th> <th> Example 4 </th> </tr> </thead> <tbody> <tr> <td> Database size (GB) </td> <td> 10 </td> <td> 10 </td> <td> 40 </td> <td> 40 </td> </tr> <tr> <td> Number of shards </td> <td> 4 </td> <td> 16 </td> <td> 5 </td> <td> 15 </td> </tr> <tr> <td> Shard size (GB) </td> <td> 2.5 </td> <td> 0.625 </td> <td> 8 </td> <td> 2.67 </td> </tr> <tr> <td> Required disk space (GB) </td> <td> 73 </td> <td> 191 </td> <td> 328 </td> <td> 723 </td> </tr> </tbody> </table> <p> For disk size requirements in standard usage scenarios, refer to the <a href="/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/hardware-requirements/"> Hardware requirements </a> section. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/clusters/optimize/disk-sizing-heavy-write-scenarios/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/management/security/acl.html
<section class="prose w-full py-12 max-w-none"> <h1> ACL </h1> <p class="text-lg -mt-5 mb-10"> Redis Access Control List </p> <p> The Redis ACL, short for Access Control List, is the feature that allows certain connections to be limited in terms of the commands that can be executed and the keys that can be accessed. The way it works is that, after connecting, a client is required to provide a username and a valid password to authenticate. If authentication succeeded, the connection is associated with a given user and the limits the user has. Redis can be configured so that new connections are already authenticated with a "default" user (this is the default configuration). Configuring the default user has, as a side effect, the ability to provide only a specific subset of functionalities to connections that are not explicitly authenticated. </p> <p> In the default configuration, Redis 6 (the first version to have ACLs) works exactly like older versions of Redis. Every new connection is capable of calling every possible command and accessing every key, so the ACL feature is backward compatible with old clients and applications. Also the old way to configure a password, using the <strong> requirepass </strong> configuration directive, still works as expected. However, it now sets a password for the default user. </p> <p> The Redis <a href="/commands/auth"> <code> AUTH </code> </a> command was extended in Redis 6, so now it is possible to use it in the two-arguments form: </p> <pre><code>AUTH &lt;username&gt; &lt;password&gt; </code></pre> <p> Here's an example of the old form: </p> <pre><code>AUTH &lt;password&gt; </code></pre> <p> What happens is that the username used to authenticate is "default", so just specifying the password implies that we want to authenticate against the default user. This provides backward compatibility. </p> <h2 id="when-acls-are-useful"> When ACLs are useful </h2> <p> Before using ACLs, you may want to ask yourself what's the goal you want to accomplish by implementing this layer of protection. Normally there are two main goals that are well served by ACLs: </p> <ol> <li> You want to improve security by restricting the access to commands and keys, so that untrusted clients have no access and trusted clients have just the minimum access level to the database in order to perform the work needed. For instance, certain clients may just be able to execute read only commands. </li> <li> You want to improve operational safety, so that processes or humans accessing Redis are not allowed to damage the data or the configuration due to software errors or manual mistakes. For instance, there is no reason for a worker that fetches delayed jobs from Redis to be able to call the <a href="/commands/flushall"> <code> FLUSHALL </code> </a> command. </li> </ol> <p> Another typical usage of ACLs is related to managed Redis instances. Redis is often provided as a managed service both by internal company teams that handle the Redis infrastructure for the other internal customers they have, or is provided in a software-as-a-service setup by cloud providers. In both setups, we want to be sure that configuration commands are excluded for the customers. </p> <h2 id="configure-acls-with-the-acl-command"> Configure ACLs with the ACL command </h2> <p> ACLs are defined using a DSL (domain specific language) that describes what a given user is allowed to do. Such rules are always implemented from the first to the last, left-to-right, because sometimes the order of the rules is important to understand what the user is really able to do. </p> <p> By default there is a single user defined, called <em> default </em> . We can use the <a href="/commands/acl-list"> <code> ACL LIST </code> </a> command in order to check the currently active ACLs and verify what the configuration of a freshly started, defaults-configured Redis instance is: </p> <pre><code>&gt; ACL LIST 1) "user default on nopass ~* &amp;* +@all" </code></pre> <p> The command above reports the list of users in the same format that is used in the Redis configuration files, by translating the current ACLs set for the users back into their description. </p> <p> The first two words in each line are "user" followed by the username. The next words are ACL rules that describe different things. We'll show how the rules work in detail, but for now it is enough to say that the default user is configured to be active (on), to require no password (nopass), to access every possible key ( <code> ~* </code> ) and Pub/Sub channel ( <code> &amp;* </code> ), and be able to call every possible command ( <code> +@all </code> ). </p> <p> Also, in the special case of the default user, having the <em> nopass </em> rule means that new connections are automatically authenticated with the default user without any explicit <a href="/commands/auth"> <code> AUTH </code> </a> call needed. </p> <h2 id="acl-rules"> ACL rules </h2> <p> The following is the list of valid ACL rules. Certain rules are just single words that are used in order to activate or remove a flag, or to perform a given change to the user ACL. Other rules are char prefixes that are concatenated with command or category names, key patterns, and so forth. </p> <p> Enable and disallow users: </p> <ul> <li> <code> on </code> : Enable the user: it is possible to authenticate as this user. </li> <li> <code> off </code> : Disallow the user: it's no longer possible to authenticate with this user; however, previously authenticated connections will still work. Note that if the default user is flagged as <em> off </em> , new connections will start as not authenticated and will require the user to send <a href="/commands/auth"> <code> AUTH </code> </a> or <a href="/commands/hello"> <code> HELLO </code> </a> with the AUTH option in order to authenticate in some way, regardless of the default user configuration. </li> </ul> <p> Allow and disallow commands: </p> <ul> <li> <code> +&lt;command&gt; </code> : Add the command to the list of commands the user can call. Can be used with <code> | </code> for allowing subcommands (e.g "+config|get"). </li> <li> <code> -&lt;command&gt; </code> : Remove the command to the list of commands the user can call. Starting Redis 7.0, it can be used with <code> | </code> for blocking subcommands (e.g "-config|set"). </li> <li> <code> +@&lt;category&gt; </code> : Add all the commands in such category to be called by the user, with valid categories being like @admin, @set, @sortedset, ... and so forth, see the full list by calling the <a href="/commands/acl-cat"> <code> ACL CAT </code> </a> command. The special category @all means all the commands, both the ones currently present in the server, and the ones that will be loaded in the future via modules. </li> <li> <code> -@&lt;category&gt; </code> : Like <code> +@&lt;category&gt; </code> but removes the commands from the list of commands the client can call. </li> <li> <code> +&lt;command&gt;|first-arg </code> : Allow a specific first argument of an otherwise disabled command. It is only supported on commands with no sub-commands, and is not allowed as negative form like -SELECT|1, only additive starting with "+". This feature is deprecated and may be removed in the future. </li> <li> <code> allcommands </code> : Alias for +@all. Note that it implies the ability to execute all the future commands loaded via the modules system. </li> <li> <code> nocommands </code> : Alias for -@all. </li> </ul> <p> Allow and disallow certain keys and key permissions: </p> <ul> <li> <code> ~&lt;pattern&gt; </code> : Add a pattern of keys that can be mentioned as part of commands. For instance <code> ~* </code> allows all the keys. The pattern is a glob-style pattern like the one of <a href="/commands/keys"> <code> KEYS </code> </a> . It is possible to specify multiple patterns. </li> <li> <code> %R~&lt;pattern&gt; </code> : (Available in Redis 7.0 and later) Add the specified read key pattern. This behaves similar to the regular key pattern but only grants permission to read from keys that match the given pattern. See <a href="#key-permissions"> key permissions </a> for more information. </li> <li> <code> %W~&lt;pattern&gt; </code> : (Available in Redis 7.0 and later) Add the specified write key pattern. This behaves similar to the regular key pattern but only grants permission to write to keys that match the given pattern. See <a href="#key-permissions"> key permissions </a> for more information. </li> <li> <code> %RW~&lt;pattern&gt; </code> : (Available in Redis 7.0 and later) Alias for <code> ~&lt;pattern&gt; </code> . </li> <li> <code> allkeys </code> : Alias for <code> ~* </code> . </li> <li> <code> resetkeys </code> : Flush the list of allowed keys patterns. For instance the ACL <code> ~foo:* ~bar:* resetkeys ~objects:* </code> , will only allow the client to access keys that match the pattern <code> objects:* </code> . </li> </ul> <p> Allow and disallow Pub/Sub channels: </p> <ul> <li> <code> &amp;&lt;pattern&gt; </code> : (Available in Redis 6.2 and later) Add a glob style pattern of Pub/Sub channels that can be accessed by the user. It is possible to specify multiple channel patterns. Note that pattern matching is done only for channels mentioned by <a href="/commands/publish"> <code> PUBLISH </code> </a> and <a href="/commands/subscribe"> <code> SUBSCRIBE </code> </a> , whereas <a href="/commands/psubscribe"> <code> PSUBSCRIBE </code> </a> requires a literal match between its channel patterns and those allowed for user. </li> <li> <code> allchannels </code> : Alias for <code> &amp;* </code> that allows the user to access all Pub/Sub channels. </li> <li> <code> resetchannels </code> : Flush the list of allowed channel patterns and disconnect the user's Pub/Sub clients if these are no longer able to access their respective channels and/or channel patterns. </li> </ul> <p> Configure valid passwords for the user: </p> <ul> <li> <code> &gt;&lt;password&gt; </code> : Add this password to the list of valid passwords for the user. For example <code> &gt;mypass </code> will add "mypass" to the list of valid passwords. This directive clears the <em> nopass </em> flag (see later). Every user can have any number of passwords. </li> <li> <code> &lt;&lt;password&gt; </code> : Remove this password from the list of valid passwords. Emits an error in case the password you are trying to remove is actually not set. </li> <li> <code> #&lt;hash&gt; </code> : Add this SHA-256 hash value to the list of valid passwords for the user. This hash value will be compared to the hash of a password entered for an ACL user. This allows users to store hashes in the <code> acl.conf </code> file rather than storing cleartext passwords. Only SHA-256 hash values are accepted as the password hash must be 64 characters and only contain lowercase hexadecimal characters. </li> <li> <code> !&lt;hash&gt; </code> : Remove this hash value from the list of valid passwords. This is useful when you do not know the password specified by the hash value but would like to remove the password from the user. </li> <li> <code> nopass </code> : All the set passwords of the user are removed, and the user is flagged as requiring no password: it means that every password will work against this user. If this directive is used for the default user, every new connection will be immediately authenticated with the default user without any explicit AUTH command required. Note that the <em> resetpass </em> directive will clear this condition. </li> <li> <code> resetpass </code> : Flushes the list of allowed passwords and removes the <em> nopass </em> status. After <em> resetpass </em> , the user has no associated passwords and there is no way to authenticate without adding some password (or setting it as <em> nopass </em> later). </li> </ul> <p> <em> Note: if a user is not flagged with nopass and has no list of valid passwords, that user is effectively impossible to use because there will be no way to log in as that user. </em> </p> <p> Configure selectors for the user: </p> <ul> <li> <code> (&lt;rule list&gt;) </code> : (Available in Redis 7.0 and later) Create a new selector to match rules against. Selectors are evaluated after the user permissions, and are evaluated according to the order they are defined. If a command matches either the user permissions or any selector, it is allowed. See <a href="#selectors"> selectors </a> for more information. </li> <li> <code> clearselectors </code> : (Available in Redis 7.0 and later) Delete all of the selectors attached to the user. </li> </ul> <p> Reset the user: </p> <ul> <li> <code> reset </code> Performs the following actions: resetpass, resetkeys, resetchannels, allchannels (if acl-pubsub-default is set), off, clearselectors, -@all. The user returns to the same state it had immediately after its creation. </li> </ul> <h2 id="create-and-edit-user-acls-with-the-acl-setuser-command"> Create and edit user ACLs with the ACL SETUSER command </h2> <p> Users can be created and modified in two main ways: </p> <ol> <li> Using the ACL command and its <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> subcommand. </li> <li> Modifying the server configuration, where users can be defined, and restarting the server. With an <em> external ACL file </em> , just call <a href="/commands/acl-load"> <code> ACL LOAD </code> </a> . </li> </ol> <p> In this section we'll learn how to define users using the <a href="/commands/acl"> <code> ACL </code> </a> command. With such knowledge, it will be trivial to do the same things via the configuration files. Defining users in the configuration deserves its own section and will be discussed later separately. </p> <p> To start, try the simplest <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> command call: </p> <pre><code>&gt; ACL SETUSER alice OK </code></pre> <p> The <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> command takes the username and a list of ACL rules to apply to the user. However the above example did not specify any rule at all. This will just create the user if it did not exist, using the defaults for new users. If the user already exists, the command above will do nothing at all. </p> <p> Check the default user status: </p> <pre><code>&gt; ACL LIST 1) "user alice off resetchannels -@all" 2) "user default on nopass ~* &amp;* +@all" </code></pre> <p> The new user "alice" is: </p> <ul> <li> In the off status, so <a href="/commands/auth"> <code> AUTH </code> </a> will not work for the user "alice". </li> <li> The user also has no passwords set. </li> <li> Cannot access any command. Note that the user is created by default without the ability to access any command, so the <code> -@all </code> in the output above could be omitted; however, <a href="/commands/acl-list"> <code> ACL LIST </code> </a> attempts to be explicit rather than implicit. </li> <li> There are no key patterns that the user can access. </li> <li> There are no Pub/Sub channels that the user can access. </li> </ul> <p> New users are created with restrictive permissions by default. Starting with Redis 6.2, ACL provides Pub/Sub channels access management as well. To ensure backward compatibility with version 6.0 when upgrading to Redis 6.2, new users are granted the 'allchannels' permission by default. The default can be set to <code> resetchannels </code> via the <code> acl-pubsub-default </code> configuration directive. </p> <p> From 7.0, The <code> acl-pubsub-default </code> value is set to <code> resetchannels </code> to restrict the channels access by default to provide better security. The default can be set to <code> allchannels </code> via the <code> acl-pubsub-default </code> configuration directive to be compatible with previous versions. </p> <p> Such user is completely useless. Let's try to define the user so that it is active, has a password, and can access with only the <a href="/commands/get"> <code> GET </code> </a> command to key names starting with the string "cached:". </p> <pre><code>&gt; ACL SETUSER alice on &gt;p1pp0 ~cached:* +get OK </code></pre> <p> Now the user can do something, but will refuse to do other things: </p> <pre><code>&gt; AUTH alice p1pp0 OK &gt; GET foo (error) NOPERM this user has no permissions to access one of the keys used as arguments &gt; GET cached:1234 (nil) &gt; SET cached:1234 zap (error) NOPERM this user has no permissions to run the 'set' command </code></pre> <p> Things are working as expected. In order to inspect the configuration of the user alice (remember that user names are case sensitive), it is possible to use an alternative to <a href="/commands/acl-list"> <code> ACL LIST </code> </a> which is designed to be more suitable for computers to read, while <a href="/commands/acl-getuser"> <code> ACL GETUSER </code> </a> is more human readable. </p> <pre><code>&gt; ACL GETUSER alice 1) "flags" 2) 1) "on" 3) "passwords" 4) 1) "2d9c75..." 5) "commands" 6) "-@all +get" 7) "keys" 8) "~cached:*" 9) "channels" 10) "" 11) "selectors" 12) (empty array) </code></pre> <p> The <a href="/commands/acl-getuser"> <code> ACL GETUSER </code> </a> returns a field-value array that describes the user in more parsable terms. The output includes the set of flags, a list of key patterns, passwords, and so forth. The output is probably more readable if we use RESP3, so that it is returned as a map reply: </p> <pre><code>&gt; ACL GETUSER alice 1# "flags" =&gt; 1~ "on" 2# "passwords" =&gt; 1) "2d9c75273d72b32df726fb545c8a4edc719f0a95a6fd993950b10c474ad9c927" 3# "commands" =&gt; "-@all +get" 4# "keys" =&gt; "~cached:*" 5# "channels" =&gt; "" 6# "selectors" =&gt; (empty array) </code></pre> <p> <em> Note: from now on, we'll continue using the Redis default protocol, version 2 </em> </p> <p> Using another <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> command (from a different user, because alice cannot run the <a href="/commands/acl"> <code> ACL </code> </a> command), we can add multiple patterns to the user: </p> <pre><code>&gt; ACL SETUSER alice ~objects:* ~items:* ~public:* OK &gt; ACL LIST 1) "user alice on #2d9c75... ~cached:* ~objects:* ~items:* ~public:* resetchannels -@all +get" 2) "user default on nopass ~* &amp;* +@all" </code></pre> <p> The user representation in memory is now as we expect it to be. </p> <h2 id="multiple-calls-to-acl-setuser"> Multiple calls to ACL SETUSER </h2> <p> It is very important to understand what happens when <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> is called multiple times. What is critical to know is that every <a href="/commands/acl-setuser"> <code> ACL SETUSER </code> </a> call will NOT reset the user, but will just apply the ACL rules to the existing user. The user is reset only if it was not known before. In that case, a brand new user is created with zeroed-ACLs. The user cannot do anything, is disallowed, has no passwords, and so forth. This is the best default for safety. </p> <p> However later calls will just modify the user incrementally. For instance, the following sequence: </p> <pre><code>&gt; ACL SETUSER myuser +set OK &gt; ACL SETUSER myuser +get OK </code></pre> <p> Will result in myuser being able to call both <a href="/commands/get"> <code> GET </code> </a> and <a href="/commands/set"> <code> SET </code> </a> : </p> <pre><code>&gt; ACL LIST 1) "user default on nopass ~* &amp;* +@all" 2) "user myuser off resetchannels -@all +get +set" </code></pre> <h2 id="command-categories"> Command categories </h2> <p> Setting user ACLs by specifying all the commands one after the other is really annoying, so instead we do things like this: </p> <pre><code>&gt; ACL SETUSER antirez on +@all -@dangerous &gt;42a979... ~* </code></pre> <p> By saying +@all and -@dangerous, we included all the commands and later removed all the commands that are tagged as dangerous inside the Redis command table. Note that command categories <strong> never include modules commands </strong> with the exception of +@all. If you say +@all, all the commands can be executed by the user, even future commands loaded via the modules system. However if you use the ACL rule +@read or any other, the modules commands are always excluded. This is very important because you should just trust the Redis internal command table. Modules may expose dangerous things and in the case of an ACL that is just additive, that is, in the form of <code> +@all -... </code> You should be absolutely sure that you'll never include what you did not mean to. </p> <p> The following is a list of command categories and their meanings: </p> <ul> <li> <strong> admin </strong> - Administrative commands. Normal applications will never need to use these. Includes <a href="/commands/replicaof"> <code> REPLICAOF </code> </a> , <a href="/commands/config"> <code> CONFIG </code> </a> , <a href="/commands/debug"> <code> DEBUG </code> </a> , <a href="/commands/save"> <code> SAVE </code> </a> , <a href="/commands/monitor"> <code> MONITOR </code> </a> , <a href="/commands/acl"> <code> ACL </code> </a> , <a href="/commands/shutdown"> <code> SHUTDOWN </code> </a> , etc. </li> <li> <strong> bitmap </strong> - Data type: bitmaps related. </li> <li> <strong> blocking </strong> - Potentially blocking the connection until released by another command. </li> <li> <strong> connection </strong> - Commands affecting the connection or other connections. This includes <a href="/commands/auth"> <code> AUTH </code> </a> , <a href="/commands/select"> <code> SELECT </code> </a> , <a href="/commands/command"> <code> COMMAND </code> </a> , <a href="/commands/client"> <code> CLIENT </code> </a> , <a href="/commands/echo"> <code> ECHO </code> </a> , <a href="/commands/ping"> <code> PING </code> </a> , etc. </li> <li> <strong> dangerous </strong> - Potentially dangerous commands (each should be considered with care for various reasons). This includes <a href="/commands/flushall"> <code> FLUSHALL </code> </a> , <a href="/commands/migrate"> <code> MIGRATE </code> </a> , <a href="/commands/restore"> <code> RESTORE </code> </a> , <a href="/commands/sort"> <code> SORT </code> </a> , <a href="/commands/keys"> <code> KEYS </code> </a> , <a href="/commands/client"> <code> CLIENT </code> </a> , <a href="/commands/debug"> <code> DEBUG </code> </a> , <a href="/commands/info"> <code> INFO </code> </a> , <a href="/commands/config"> <code> CONFIG </code> </a> , <a href="/commands/save"> <code> SAVE </code> </a> , <a href="/commands/replicaof"> <code> REPLICAOF </code> </a> , etc. </li> <li> <strong> geo </strong> - Data type: geospatial indexes related. </li> <li> <strong> hash </strong> - Data type: hashes related. </li> <li> <strong> hyperloglog </strong> - Data type: hyperloglog related. </li> <li> <strong> fast </strong> - Fast O(1) commands. May loop on the number of arguments, but not the number of elements in the key. </li> <li> <strong> keyspace </strong> - Writing or reading from keys, databases, or their metadata in a type agnostic way. Includes <a href="/commands/del"> <code> DEL </code> </a> , <a href="/commands/restore"> <code> RESTORE </code> </a> , <a href="/commands/dump"> <code> DUMP </code> </a> , <a href="/commands/rename"> <code> RENAME </code> </a> , <a href="/commands/exists"> <code> EXISTS </code> </a> , <a href="/commands/dbsize"> <code> DBSIZE </code> </a> , <a href="/commands/keys"> <code> KEYS </code> </a> , <a href="/commands/expire"> <code> EXPIRE </code> </a> , <a href="/commands/ttl"> <code> TTL </code> </a> , <a href="/commands/flushall"> <code> FLUSHALL </code> </a> , etc. Commands that may modify the keyspace, key, or metadata will also have the <code> write </code> category. Commands that only read the keyspace, key, or metadata will have the <code> read </code> category. </li> <li> <strong> list </strong> - Data type: lists related. </li> <li> <strong> pubsub </strong> - PubSub-related commands. </li> <li> <strong> read </strong> - Reading from keys (values or metadata). Note that commands that don't interact with keys, will not have either <code> read </code> or <code> write </code> . </li> <li> <strong> scripting </strong> - Scripting related. </li> <li> <strong> set </strong> - Data type: sets related. </li> <li> <strong> sortedset </strong> - Data type: sorted sets related. </li> <li> <strong> slow </strong> - All commands that are not <code> fast </code> . </li> <li> <strong> stream </strong> - Data type: streams related. </li> <li> <strong> string </strong> - Data type: strings related. </li> <li> <strong> transaction </strong> - <a href="/commands/watch"> <code> WATCH </code> </a> / <a href="/commands/multi"> <code> MULTI </code> </a> / <a href="/commands/exec"> <code> EXEC </code> </a> related commands. </li> <li> <strong> write </strong> - Writing to keys (values or metadata). </li> </ul> <p> Redis can also show you a list of all categories and the exact commands each category includes using the Redis <a href="/commands/acl-cat"> <code> ACL CAT </code> </a> command. It can be used in two forms: </p> <pre><code>ACL CAT -- Will just list all the categories available ACL CAT &lt;category-name&gt; -- Will list all the commands inside the category </code></pre> <p> Examples: </p> <pre><code> &gt; ACL CAT 1) "keyspace" 2) "read" 3) "write" 4) "set" 5) "sortedset" 6) "list" 7) "hash" 8) "string" 9) "bitmap" 10) "hyperloglog" 11) "geo" 12) "stream" 13) "pubsub" 14) "admin" 15) "fast" 16) "slow" 17) "blocking" 18) "dangerous" 19) "connection" 20) "transaction" 21) "scripting" </code></pre> <p> As you can see, so far there are 21 distinct categories. Now let's check what command is part of the <em> geo </em> category: </p> <pre><code> &gt; ACL CAT geo 1) "geohash" 2) "georadius_ro" 3) "georadiusbymember" 4) "geopos" 5) "geoadd" 6) "georadiusbymember_ro" 7) "geodist" 8) "georadius" 9) "geosearch" 10) "geosearchstore" </code></pre> <p> Note that commands may be part of multiple categories. For example, an ACL rule like <code> +@geo -@read </code> will result in certain geo commands to be excluded because they are read-only commands. </p> <h2 id="allowblock-subcommands"> Allow/block subcommands </h2> <p> Starting from Redis 7.0, subcommands can be allowed/blocked just like other commands (by using the separator <code> | </code> between the command and subcommand, for example: <code> +config|get </code> or <code> -config|set </code> ) </p> <p> That is true for all commands except DEBUG. In order to allow/block specific DEBUG subcommands, see the next section. </p> <h2 id="allow-the-first-arg-of-a-blocked-command"> Allow the first-arg of a blocked command </h2> <p> <strong> Note: This feature is deprecated since Redis 7.0 and may be removed in the future. </strong> </p> <p> Sometimes the ability to exclude or include a command or a subcommand as a whole is not enough. Many deployments may not be happy providing the ability to execute a <a href="/commands/select"> <code> SELECT </code> </a> for any DB, but may still want to be able to run <code> SELECT 0 </code> . </p> <p> In such case we could alter the ACL of a user in the following way: </p> <pre><code>ACL SETUSER myuser -select +select|0 </code></pre> <p> First, remove the <a href="/commands/select"> <code> SELECT </code> </a> command and then add the allowed first-arg. Note that <strong> it is not possible to do the reverse </strong> since first-args can be only added, not excluded. It is safer to specify all the first-args that are valid for some user since it is possible that new first-args may be added in the future. </p> <p> Another example: </p> <pre><code>ACL SETUSER myuser -debug +debug|digest </code></pre> <p> Note that first-arg matching may add some performance penalty; however, it is hard to measure even with synthetic benchmarks. The additional CPU cost is only paid when such commands are called, and not when other commands are called. </p> <p> It is possible to use this mechanism in order to allow subcommands in Redis versions prior to 7.0 (see above section). </p> <h2 id="all-vs--all"> +@all VS -@all </h2> <p> In the previous section, it was observed how it is possible to define command ACLs based on adding/removing single commands. </p> <h2 id="selectors"> Selectors </h2> <p> Starting with Redis 7.0, Redis supports adding multiple sets of rules that are evaluated independently of each other. These secondary sets of permissions are called selectors and added by wrapping a set of rules within parentheses. In order to execute a command, either the root permissions (rules defined outside of parenthesis) or any of the selectors (rules defined inside parenthesis) must match the given command. Internally, the root permissions are checked first followed by selectors in the order they were added. </p> <p> For example, consider a user with the ACL rules <code> +GET ~key1 (+SET ~key2) </code> . This user is able to execute <code> GET key1 </code> and <code> SET key2 hello </code> , but not <code> GET key2 </code> or <code> SET key1 world </code> . </p> <p> Unlike the user's root permissions, selectors cannot be modified after they are added. Instead, selectors can be removed with the <code> clearselectors </code> keyword, which removes all of the added selectors. Note that <code> clearselectors </code> does not remove the root permissions. </p> <h2 id="key-permissions"> Key permissions </h2> <p> Starting with Redis 7.0, key patterns can also be used to define how a command is able to touch a key. This is achieved through rules that define key permissions. The key permission rules take the form of <code> %(&lt;permission&gt;)~&lt;pattern&gt; </code> . Permissions are defined as individual characters that map to the following key permissions: </p> <ul> <li> W (Write): The data stored within the key may be updated or deleted. </li> <li> R (Read): User supplied data from the key is processed, copied or returned. Note that this does not include metadata such as size information (example <a href="/commands/strlen"> <code> STRLEN </code> </a> ), type information (example <a href="/commands/type"> <code> TYPE </code> </a> ) or information about whether a value exists within a collection (example <a href="/commands/sismember"> <code> SISMEMBER </code> </a> ). </li> </ul> <p> Permissions can be composed together by specifying multiple characters. Specifying the permission as 'RW' is considered full access and is analogous to just passing in <code> ~&lt;pattern&gt; </code> . </p> <p> For a concrete example, consider a user with ACL rules <code> +@all ~app1:* (+@read ~app2:*) </code> . This user has full access on <code> app1:* </code> and readonly access on <code> app2:* </code> . However, some commands support reading data from one key, doing some transformation, and storing it into another key. One such command is the <a href="/commands/copy"> <code> COPY </code> </a> command, which copies the data from the source key into the destination key. The example set of ACL rules is unable to handle a request copying data from <code> app2:user </code> into <code> app1:user </code> , since neither the root permission nor the selector fully matches the command. However, using key selectors you can define a set of ACL rules that can handle this request <code> +@all ~app1:* %R~app2:* </code> . The first pattern is able to match <code> app1:user </code> and the second pattern is able to match <code> app2:user </code> . </p> <p> Which type of permission is required for a command is documented through <a href="/docs/latest/develop/reference/key-specs#logical-operation-flags"> key specifications </a> . The type of permission is based off the keys logical operation flags. The insert, update, and delete flags map to the write key permission. The access flag maps to the read key permission. If the key has no logical operation flags, such as <a href="/commands/exists"> <code> EXISTS </code> </a> , the user still needs either key read or key write permissions to execute the command. </p> <p> Note: Side channels to accessing user data are ignored when it comes to evaluating whether read permissions are required to execute a command. This means that some write commands that return metadata about the modified key only require write permission on the key to execute. For example, consider the following two commands: </p> <ul> <li> <code> LPUSH key1 data </code> : modifies "key1" but only returns metadata about it, the size of the list after the push, so the command only requires write permission on "key1" to execute. </li> <li> <code> LPOP key2 </code> : modifies "key2" but also returns data from it, the left most item in the list, so the command requires both read and write permission on "key2" to execute. </li> </ul> <p> If an application needs to make sure no data is accessed from a key, including side channels, it's recommended to not provide any access to the key. </p> <h2 id="how-passwords-are-stored-internally"> How passwords are stored internally </h2> <p> Redis internally stores passwords hashed with SHA256. If you set a password and check the output of <a href="/commands/acl-list"> <code> ACL LIST </code> </a> or <a href="/commands/acl-getuser"> <code> ACL GETUSER </code> </a> , you'll see a long hex string that looks pseudo random. Here is an example, because in the previous examples, for the sake of brevity, the long hex string was trimmed: </p> <pre><code>&gt; ACL GETUSER default 1) "flags" 2) 1) "on" 3) "passwords" 4) 1) "2d9c75273d72b32df726fb545c8a4edc719f0a95a6fd993950b10c474ad9c927" 5) "commands" 6) "+@all" 7) "keys" 8) "~*" 9) "channels" 10) "&amp;*" 11) "selectors" 12) (empty array) </code></pre> <p> Using SHA256 provides the ability to avoid storing the password in clear text while still allowing for a very fast <a href="/commands/auth"> <code> AUTH </code> </a> command, which is a very important feature of Redis and is coherent with what clients expect from Redis. </p> <p> However ACL <em> passwords </em> are not really passwords. They are shared secrets between the server and the client, because the password is not an authentication token used by a human being. For instance: </p> <ul> <li> There are no length limits, the password will just be memorized in some client software. There is no human that needs to recall a password in this context. </li> <li> The ACL password does not protect any other thing. For example, it will never be the password for some email account. </li> <li> Often when you are able to access the hashed password itself, by having full access to the Redis commands of a given server, or corrupting the system itself, you already have access to what the password is protecting: the Redis instance stability and the data it contains. </li> </ul> <p> For this reason, slowing down the password authentication, in order to use an algorithm that uses time and space to make password cracking hard, is a very poor choice. What we suggest instead is to generate strong passwords, so that nobody will be able to crack it using a dictionary or a brute force attack even if they have the hash. To do so, there is a special ACL command <a href="/commands/acl-genpass"> <code> ACL GENPASS </code> </a> that generates passwords using the system cryptographic pseudorandom generator: </p> <pre><code>&gt; ACL GENPASS "dd721260bfe1b3d9601e7fbab36de6d04e2e67b0ef1c53de59d45950db0dd3cc" </code></pre> <p> The command outputs a 32-byte (256-bit) pseudorandom string converted to a 64-byte alphanumerical string. This is long enough to avoid attacks and short enough to be easy to manage, cut &amp; paste, store, and so forth. This is what you should use in order to generate Redis passwords. </p> <h2 id="use-an-external-acl-file"> Use an external ACL file </h2> <p> There are two ways to store users inside the Redis configuration: </p> <ol> <li> Users can be specified directly inside the <code> redis.conf </code> file. </li> <li> It is possible to specify an external ACL file. </li> </ol> <p> The two methods are <em> mutually incompatible </em> , so Redis will ask you to use one or the other. Specifying users inside <code> redis.conf </code> is good for simple use cases. When there are multiple users to define, in a complex environment, we recommend you use the ACL file instead. </p> <p> The format used inside <code> redis.conf </code> and in the external ACL file is exactly the same, so it is trivial to switch from one to the other, and is the following: </p> <pre><code>user &lt;username&gt; ... acl rules ... </code></pre> <p> For instance: </p> <pre><code>user worker +@list +@connection ~jobs:* on &gt;ffa9203c493aa99 </code></pre> <p> When you want to use an external ACL file, you are required to specify the configuration directive called <code> aclfile </code> , like this: </p> <pre><code>aclfile /etc/redis/users.acl </code></pre> <p> When you are just specifying a few users directly inside the <code> redis.conf </code> file, you can use <a href="/commands/config-rewrite"> <code> CONFIG REWRITE </code> </a> in order to store the new user configuration inside the file by rewriting it. </p> <p> The external ACL file however is more powerful. You can do the following: </p> <ul> <li> Use <a href="/commands/acl-load"> <code> ACL LOAD </code> </a> if you modified the ACL file manually and you want Redis to reload the new configuration. Note that this command is able to load the file <em> only if all the users are correctly specified </em> . Otherwise, an error is reported to the user, and the old configuration will remain valid. </li> <li> Use <a href="/commands/acl-save"> <code> ACL SAVE </code> </a> to save the current ACL configuration to the ACL file. </li> </ul> <p> Note that <a href="/commands/config-rewrite"> <code> CONFIG REWRITE </code> </a> does not also trigger <a href="/commands/acl-save"> <code> ACL SAVE </code> </a> . When you use an ACL file, the configuration and the ACLs are handled separately. </p> <h2 id="acl-rules-for-sentinel-and-replicas"> ACL rules for Sentinel and Replicas </h2> <p> In case you don't want to provide Redis replicas and Redis Sentinel instances full access to your Redis instances, the following is the set of commands that must be allowed in order for everything to work correctly. </p> <p> For Sentinel, allow the user to access the following commands both in the master and replica instances: </p> <ul> <li> AUTH, CLIENT, SUBSCRIBE, SCRIPT, PUBLISH, PING, INFO, MULTI, SLAVEOF, CONFIG, CLIENT, EXEC. </li> </ul> <p> Sentinel does not need to access any key in the database but does use Pub/Sub, so the ACL rule would be the following (note: <a href="/commands/auth"> <code> AUTH </code> </a> is not needed since it is always allowed): </p> <pre><code>ACL SETUSER sentinel-user on &gt;somepassword allchannels +multi +slaveof +ping +exec +subscribe +config|rewrite +role +publish +info +client|setname +client|kill +script|kill </code></pre> <p> Redis replicas require the following commands to be allowed on the master instance: </p> <ul> <li> PSYNC, REPLCONF, PING </li> </ul> <p> No keys need to be accessed, so this translates to the following rules: </p> <pre><code>ACL setuser replica-user on &gt;somepassword +psync +replconf +ping </code></pre> <p> Note that you don't need to configure the replicas to allow the master to be able to execute any set of commands. The master is always authenticated as the root user from the point of view of replicas. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/management/security/acl/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/ft.dictdump/.html
<section class="prose w-full py-12"> <h1 class="command-name"> FT.DICTDUMP </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">FT.DICTDUMP dict </pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/interact/search-and-query"> Search 1.4.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N), where N is the size of the dictionary </dd> </dl> <p> Dump all terms in the given dictionary </p> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-argumemts"> Required argumemts </h2> <details open=""> <summary> <code> dict </code> </summary> <p> is dictionary name. </p> </details> <h2 id="return"> Return </h2> <p> FT.DICTDUMP returns an array, where each element is term (string). </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Dump all terms in the dictionary </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.DICTDUMP dict </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="s2">"foo"</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> <span class="s2">"bar"</span> </span></span><span class="line"><span class="cl">3<span class="o">)</span> <span class="s2">"hello world"</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/ft.dictadd/"> <code> FT.DICTADD </code> </a> | <a href="/docs/latest/commands/ft.dictdel/"> <code> FT.DICTDEL </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <p> <a href="/docs/latest/develop/interact/search-and-query/"> RediSearch </a> </p> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/ft.dictdump/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/json/.html
<section class="prose w-full py-12 max-w-none"> <h1> JSON </h1> <p class="text-lg -mt-5 mb-10"> Redis Stack adds support for JSON to Redis databases. </p> <p> Redis Stack adds support for the <a href="http://www.json.org/"> JSON data structure </a> to Redis databases. </p> <p> Applications developed with the <a href="https://github.com/RedisJSON/RedisJSON"> source available version of RedisJSON </a> are 100% compatible with Redis Enterprise databases with JSON enabled. </p> <h2 id="json-paths"> JSON paths </h2> <p> <a href="/docs/latest/develop/data-types/json/path/"> Paths </a> let you traverse the structure of a JSON document, starting from the root, and interact only with the data you want. You can also use paths to perform operations on specific JSON elements. </p> <p> Since there is no standard for JSON path syntax, Redis Stack implements its own. </p> <h3 id="jsonpath-syntax"> JSONPath syntax </h3> <p> RedisJSON v2.0 and later support the <a href="/docs/latest/develop/data-types/json/path/"> JSONPath syntax </a> , which resembles <a href="https://goessner.net/articles/JsonPath/"> Goessner's design </a> : </p> <ul> <li> <p> Paths start with a dollar sign ( <code> $ </code> ), which represents the root of the JSON document. </p> </li> <li> <p> See the <a href="/docs/latest/develop/data-types/json/path/"> JSONPath syntax table </a> to learn how to access various elements within a JSON document. </p> </li> </ul> <p> The following path refers to <code> headphones </code> , which is a child of <code> inventory </code> under the root: </p> <p> <code> $.inventory.headphones </code> </p> <p> See <a href="/docs/latest/develop/data-types/json/path/"> JSONPath examples </a> for examples with more complex syntax. </p> <h3 id="legacy-path-syntax"> Legacy path syntax </h3> <p> The <a href="/docs/latest/develop/data-types/json/path/#legacy-path-syntax"> legacy path syntax </a> refers to the path implementation in RedisJSON v1. RedisJSON v2 still supports this legacy path syntax in addition to JSONPath syntax. </p> <p> The legacy path syntax works as follows: </p> <ul> <li> <p> A period character represents the root. </p> </li> <li> <p> For paths to the root's children, it is optional to prefix the path with a period. </p> </li> <li> <p> Supports both dot notation and bracket notation for JSON object key access. </p> </li> </ul> <p> The following paths refer to <code> headphones </code> , which is a child of <code> inventory </code> under the root: </p> <p> <code> .inventory.headphones </code> </p> <p> <code> inventory["headphones"] </code> </p> <p> <code> ['inventory']["headphones"] </code> </p> <h3 id="key-name-rules"> Key name rules </h3> <p> You can only use the legacy path syntax to access JSON keys if they follow these name syntax rules: </p> <ul> <li> Key names must begin with a letter, a dollar sign ( <code> $ </code> ), or an underscore ( <code> _ </code> ). </li> <li> Key names can contain letters, digits, dollar signs, and underscores. </li> <li> Key names are case-sensitive. </li> </ul> <h2 id="index-and-search-json-documents"> Index and search JSON documents </h2> <p> You can index, search, and query stored JSON documents. </p> <p> For more information about how to search and query JSON documents, see the <a href="/docs/latest/develop/get-started/document-database/"> quick start </a> . </p> <h2 id="json-in-active-active-databases"> JSON in Active-Active databases </h2> <p> RedisJSON v2.2 and later support the JSON data structure as a conflict-free replicated data type <a href="https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type"> (CRDT) </a> in <a href="/docs/latest/operate/rs/databases/active-active/"> Active-Active Redis Enterprise databases </a> . </p> <p> For details about how Redis Enterprise resolves JSON operation conflicts that can arise when replicas attempt to sync, see the JSON <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/json/active-active/#conflict-resolution-rules"> conflict resolution rules </a> . </p> <h2 id="more-info"> More info </h2> <ul> <li> <a href="/docs/latest/develop/data-types/json/#use-redisjson"> JSON quick start </a> </li> <li> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/json/commands/"> JSON commands </a> </li> <li> <a href="https://github.com/RedisJSON/RedisJSON"> RedisJSON source </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/json/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/brpop/.html
<section class="prose w-full py-12"> <h1 class="command-name"> BRPOP </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">BRPOP key [key ...] timeout</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 2.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the number of provided keys. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @write </code> <span class="mr-1 last:hidden"> , </span> <code> @list </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> <code> @blocking </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> <code> BRPOP </code> is a blocking list pop primitive. It is the blocking version of <a href="/docs/latest/commands/rpop/"> <code> RPOP </code> </a> because it blocks the connection when there are no elements to pop from any of the given lists. An element is popped from the tail of the first list that is non-empty, with the given keys being checked in the order that they are given. </p> <p> See the <a href="/commands/blpop"> BLPOP documentation </a> for the exact semantics, since <code> BRPOP </code> is identical to <a href="/docs/latest/commands/blpop/"> <code> BLPOP </code> </a> with the only difference being that it pops elements from the tail of a list instead of popping from the head. </p> <h2 id="examples"> Examples </h2> <pre tabindex="0"><code>redis&gt; DEL list1 list2 (integer) 0 redis&gt; RPUSH list1 a b c (integer) 3 redis&gt; BRPOP list1 list2 0 1) "list1" 2) "c" </code></pre> <h2 id="resp2-reply"> RESP2 Reply </h2> <p> One of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#bulk-strings"> Nil reply </a> : no element could be popped and the timeout expired. </li> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : the key from which the element was popped and the value of the popped element </li> </ul> <h2 id="resp3-reply"> RESP3 Reply </h2> <p> One of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#nulls"> Null reply </a> : no element could be popped and the timeout expired. </li> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : the key from which the element was popped and the value of the popped element </li> </ul> <br/> <h2> History </h2> <ul> <li> Starting with Redis version 6.0.0: <code> timeout </code> is interpreted as a double instead of an integer. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/brpop/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/xrevrange/.html
<section class="prose w-full py-12"> <h1 class="command-name"> XREVRANGE </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">XREVRANGE key end start [COUNTΒ count]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 5.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) with N being the number of elements returned. If N is constant (e.g. always asking for the first 10 elements with COUNT), you can consider it O(1). </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @read </code> <span class="mr-1 last:hidden"> , </span> <code> @stream </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> This command is exactly like <a href="/docs/latest/commands/xrange/"> <code> XRANGE </code> </a> , but with the notable difference of returning the entries in reverse order, and also taking the start-end range in reverse order: in <code> XREVRANGE </code> you need to state the <em> end </em> ID and later the <em> start </em> ID, and the command will produce all the element between (or exactly like) the two IDs, starting from the <em> end </em> side. </p> <p> So for instance, to get all the elements from the higher ID to the lower ID one could use: </p> <pre><code>XREVRANGE somestream + - </code></pre> <p> Similarly to get just the last element added into the stream it is enough to send: </p> <pre><code>XREVRANGE somestream + - COUNT 1 </code></pre> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; XADD writers * name Virginia surname Woolf "1731583336130-0" redis&gt; XADD writers * name Jane surname Austen "1731583336130-1" redis&gt; XADD writers * name Toni surname Morrison "1731583336130-2" redis&gt; XADD writers * name Agatha surname Christie "1731583336131-0" redis&gt; XADD writers * name Ngozi surname Adichie "1731583336131-1" redis&gt; XLEN writers (integer) 5 redis&gt; XREVRANGE writers + - COUNT 1 1) 1) "1731583336131-1" 2) 1) "name" 2) "Ngozi" 3) "surname" 4) "Adichie" </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : The command returns the entries with IDs matching the specified range. The returned entries are complete, which means that the ID and all the fields they are composed of are returned. Moreover, the entries are returned with their fields and values in the same order as <code> XADD </code> added them. <br/> <h2> History </h2> <ul> <li> Starting with Redis version 6.2.0: Added exclusive ranges. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/xrevrange/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/api/get-started/manage-tasks/.html
<section class="prose w-full py-12 max-w-none"> <h1> Manage API tasks </h1> <p class="text-lg -mt-5 mb-10"> A task is an API operation that is performed asynchronously because it exceeds the time allowed for the synchronous request/response model. </p> <p> Examples of API operations that use tasks are: </p> <ul> <li> create subscription </li> <li> create database </li> <li> update database </li> <li> delete database </li> </ul> <p> All create, update, and delete API operations ( <code> POST </code> , <code> PUT </code> , and <code> DELETE </code> ) and some query operations ( <code> GET </code> ) use tasks. </p> <p> After you request an asynchronous operation, the operation returns a <code> taskId </code> that identities the specific task, and contains contextual and status data on the API operation performed by the task. </p> <p> Tasks are part of the API <a href="/docs/latest/operate/rc/api/get-started/process-lifecycle/"> processing and provisioning lifecycle </a> . </p> <h3 id="task-information"> Task information </h3> <p> When you query a task of an asynchronous API operation, the response to the request includes the task status and additional information about the task: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"taskId"</span><span class="p">:</span> <span class="s2">"f3ec0e7b-0548-46e3-82f3-1977012ec738"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"commandType"</span><span class="p">:</span> <span class="s2">"subscriptionCreateRequest"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"status"</span><span class="p">:</span> <span class="s2">"received"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"description"</span><span class="p">:</span> <span class="s2">"Task request received and is being queued for processing."</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"timestamp"</span><span class="p">:</span> <span class="s2">"2019-08-08T09:07:39.826Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"_links"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"task"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"href"</span><span class="p">:</span> <span class="s2">"https://api.redislabs.com/v1/tasks/f3ec0e7b-0548-46e3-82f3-1977012ec738"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"title"</span><span class="p">:</span> <span class="s2">"getTaskStatusUpdates"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"GET"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> Where: </p> <ul> <li> <code> taskId </code> - The unique identifier (UUID) of the specific task </li> <li> <code> commandType </code> - The request (command) type </li> <li> <code> status </code> - The <a href="/docs/latest/operate/rc/api/get-started/process-lifecycle/#task-process-states"> status </a> of the task </li> <li> <code> description </code> - A description of the status </li> <li> <code> timestamp </code> - The time of the response in ISO-8601 date format and in the UTC timezone </li> <li> <code> _links </code> - URI links to resources related to the task including: <ul> <li> A link to itself </li> <li> Additional links based on the context of the response </li> </ul> </li> </ul> <h3 id="task-status-updates"> Task status updates </h3> <p> With the task ID, you can query the task status for updates and progress information. The response in the above example shows a URL with the title <code> getTaskStatusUpdates </code> . The URL in the <code> href </code> property returns updates for the specified task. </p> <p> This request returns the updated status of the task identifier: </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">GET <span class="s2">"https://[host]/v1/tasks/&lt;taskId&gt;"</span> </span></span></code></pre> </div> <p> The response to the <code> getTaskStatusUpdates </code> request shows: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"taskId"</span><span class="p">:</span> <span class="s2">"36d4b04d-72d4-4404-8600-a223120a553e"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"commandType"</span><span class="p">:</span> <span class="s2">"subscriptionCreateRequest"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"status"</span><span class="p">:</span> <span class="s2">"processing-completed"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"description"</span><span class="p">:</span> <span class="s2">"Request processing completed successfully and its resources are now being provisioned / de-provisioned."</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"timestamp"</span><span class="p">:</span> <span class="s2">"2019-08-08T06:49:15.929Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"response"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"resourceId"</span><span class="p">:</span> <span class="mi">77899</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="nt">"_links"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"resource"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"href"</span><span class="p">:</span> <span class="s2">"https://api.redislabs.com/v1/subscriptions/77899"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"title"</span><span class="p">:</span> <span class="s2">"getSubscriptionInformation"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"GET"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="nt">"self"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"href"</span><span class="p">:</span> <span class="s2">"https://api.redislabs.com/v1/tasks/36d4b04d-72d4-4404-8600-a223120a553e"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"GET"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> This response example shows: </p> <ul> <li> The <code> status </code> value is <code> "processing-completed" </code> . </li> <li> The <code> response </code> field contains the resource identifier of the subscription resource changed by this task. </li> <li> The <code> links </code> array contains another <code> getSubscriptionInformation </code> URL that links to the newly created subscription. This link queries the subscription status during <a href="/docs/latest/operate/rc/api/get-started/process-lifecycle/"> provisioning </a> ) </li> </ul> <h3 id="tasks-list"> Tasks list </h3> <p> You can use the API operation <code> GET /tasks </code> to list the recently submitted and completed tasks for the current account. </p> <p> This API operation returns a list of tasks for the current account, sorted by most recent status update. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">GET <span class="s2">"https://</span><span class="nv">$HOST</span><span class="s2">/tasks"</span> </span></span></code></pre> </div> <p> The result returns all the tasks submitted during the past 10 days. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/api/get-started/manage-tasks/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/zrandmember/.html
<section class="prose w-full py-12"> <h1 class="command-name"> ZRANDMEMBER </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">ZRANDMEMBER key [count [WITHSCORES]]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 6.2.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the number of members returned </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @read </code> <span class="mr-1 last:hidden"> , </span> <code> @sortedset </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> When called with just the <code> key </code> argument, return a random element from the sorted set value stored at <code> key </code> . </p> <p> If the provided <code> count </code> argument is positive, return an array of <strong> distinct elements </strong> . The array's length is either <code> count </code> or the sorted set's cardinality ( <a href="/docs/latest/commands/zcard/"> <code> ZCARD </code> </a> ), whichever is lower. </p> <p> If called with a negative <code> count </code> , the behavior changes and the command is allowed to return the <strong> same element multiple times </strong> . In this case, the number of returned elements is the absolute value of the specified <code> count </code> . </p> <p> The optional <code> WITHSCORES </code> modifier changes the reply so it includes the respective scores of the randomly selected elements from the sorted set. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; ZADD dadi 1 uno 2 due 3 tre 4 quattro 5 cinque 6 sei (integer) 6 redis&gt; ZRANDMEMBER dadi "quattro" redis&gt; ZRANDMEMBER dadi "due" redis&gt; ZRANDMEMBER dadi -5 WITHSCORES 1) "cinque" 2) "5" 3) "cinque" 4) "5" 5) "due" 6) "2" 7) "quattro" 8) "4" 9) "quattro" 10) "4" </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="specification-of-the-behavior-when-count-is-passed"> Specification of the behavior when count is passed </h2> <p> When the <code> count </code> argument is a positive value this command behaves as follows: </p> <ul> <li> No repeated elements are returned. </li> <li> If <code> count </code> is bigger than the cardinality of the sorted set, the command will only return the whole sorted set without additional elements. </li> <li> The order of elements in the reply is not truly random, so it is up to the client to shuffle them if needed. </li> </ul> <p> When the <code> count </code> is a negative value, the behavior changes as follows: </p> <ul> <li> Repeating elements are possible. </li> <li> Exactly <code> count </code> elements, or an empty array if the sorted set is empty (non-existing key), are always returned. </li> <li> The order of elements in the reply is truly random. </li> </ul> <h2 id="resp2-reply"> RESP2 Reply </h2> <a href="../../develop/reference/protocol-spec#bulk-strings"> Bulk string reply </a> : without the additional <em> count </em> argument, the command returns a randomly selected member, or <a href="../../develop/reference/protocol-spec#bulk-strings"> Nil reply </a> when <em> key </em> doesn't exist. <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : when the additional <em> count </em> argument is passed, the command returns an array of members, or an empty array when <em> key </em> doesn't exist. If the <em> WITHSCORES </em> modifier is used, the reply is a list of members and their scores from the sorted set. <h2 id="resp3-reply"> RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#bulk-strings"> Bulk string reply </a> : without the additional <em> count </em> argument, the command returns a randomly selected member, or <a href="../../develop/reference/protocol-spec#nulls"> Null reply </a> when <em> key </em> doesn't exist. <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : when the additional <em> count </em> argument is passed, the command returns an array of members, or an empty array when <em> key </em> doesn't exist. If the <em> WITHSCORES </em> modifier is used, the reply is a list of members and their scores from the sorted set. <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/zrandmember/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/xclaim/.html
<section class="prose w-full py-12"> <h1 class="command-name"> XCLAIM </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">XCLAIM key group consumer min-idle-time id [id ...] [IDLEΒ ms] [TIMEΒ unix-time-milliseconds] [RETRYCOUNTΒ count] [FORCE] [JUSTID] [LASTIDΒ lastid]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 5.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(log N) with N being the number of messages in the PEL of the consumer group. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @write </code> <span class="mr-1 last:hidden"> , </span> <code> @stream </code> <span class="mr-1 last:hidden"> , </span> <code> @fast </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> In the context of a stream consumer group, this command changes the ownership of a pending message, so that the new owner is the consumer specified as the command argument. Normally this is what happens: </p> <ol> <li> There is a stream with an associated consumer group. </li> <li> Some consumer A reads a message via <a href="/docs/latest/commands/xreadgroup/"> <code> XREADGROUP </code> </a> from a stream, in the context of that consumer group. </li> <li> As a side effect a pending message entry is created in the Pending Entries List (PEL) of the consumer group: it means the message was delivered to a given consumer, but it was not yet acknowledged via <a href="/docs/latest/commands/xack/"> <code> XACK </code> </a> . </li> <li> Then suddenly that consumer fails forever. </li> <li> Other consumers may inspect the list of pending messages, that are stale for quite some time, using the <a href="/docs/latest/commands/xpending/"> <code> XPENDING </code> </a> command. In order to continue processing such messages, they use <code> XCLAIM </code> to acquire the ownership of the message and continue. Consumers can also use the <a href="/docs/latest/commands/xautoclaim/"> <code> XAUTOCLAIM </code> </a> command to automatically scan and claim stale pending messages. </li> </ol> <p> This dynamic is clearly explained in the <a href="/docs/latest/develop/data-types/streams/"> Stream intro documentation </a> . </p> <p> Note that the message is claimed only if its idle time is greater than the minimum idle time we specify when calling <code> XCLAIM </code> . Because as a side effect <code> XCLAIM </code> will also reset the idle time (since this is a new attempt at processing the message), two consumers trying to claim a message at the same time will never both succeed: only one will successfully claim the message. This avoids that we process a given message multiple times in a trivial way (yet multiple processing is possible and unavoidable in the general case). </p> <p> Moreover, as a side effect, <code> XCLAIM </code> will increment the count of attempted deliveries of the message unless the <code> JUSTID </code> option has been specified (which only delivers the message ID, not the message itself). In this way messages that cannot be processed for some reason, for instance because the consumers crash attempting to process them, will start to have a larger counter and can be detected inside the system. </p> <p> <code> XCLAIM </code> will not claim a message in the following cases: </p> <ol> <li> The message doesn't exist in the group PEL (i.e. it was never read by any consumer) </li> <li> The message exists in the group PEL but not in the stream itself (i.e. the message was read but never acknowledged, and then was deleted from the stream, either by trimming or by <a href="/docs/latest/commands/xdel/"> <code> XDEL </code> </a> ) </li> </ol> <p> In both cases the reply will not contain a corresponding entry to that message (i.e. the length of the reply array may be smaller than the number of IDs provided to <code> XCLAIM </code> ). In the latter case, the message will also be deleted from the PEL in which it was found. This feature was introduced in Redis 7.0. </p> <h2 id="command-options"> Command options </h2> <p> The command has multiple options, however most are mainly for internal use in order to transfer the effects of <code> XCLAIM </code> or other commands to the AOF file and to propagate the same effects to the replicas, and are unlikely to be useful to normal users: </p> <ol> <li> <code> IDLE &lt;ms&gt; </code> : Set the idle time (last time it was delivered) of the message. If IDLE is not specified, an IDLE of 0 is assumed, that is, the time count is reset because the message has now a new owner trying to process it. </li> <li> <code> TIME &lt;ms-unix-time&gt; </code> : This is the same as IDLE but instead of a relative amount of milliseconds, it sets the idle time to a specific Unix time (in milliseconds). This is useful in order to rewrite the AOF file generating <code> XCLAIM </code> commands. </li> <li> <code> RETRYCOUNT &lt;count&gt; </code> : Set the retry counter to the specified value. This counter is incremented every time a message is delivered again. Normally <code> XCLAIM </code> does not alter this counter, which is just served to clients when the XPENDING command is called: this way clients can detect anomalies, like messages that are never processed for some reason after a big number of delivery attempts. </li> <li> <code> FORCE </code> : Creates the pending message entry in the PEL even if certain specified IDs are not already in the PEL assigned to a different client. However the message must be exist in the stream, otherwise the IDs of non existing messages are ignored. </li> <li> <code> JUSTID </code> : Return just an array of IDs of messages successfully claimed, without returning the actual message. Using this option means the retry counter is not incremented. </li> </ol> <h2 id="examples"> Examples </h2> <pre tabindex="0"><code>&gt; XCLAIM mystream mygroup Alice 3600000 1526569498055-0 1) 1) 1526569498055-0 2) 1) "message" 2) "orange" </code></pre> <p> In the above example we claim the message with ID <code> 1526569498055-0 </code> , only if the message is idle for at least one hour without the original consumer or some other consumer making progresses (acknowledging or claiming it), and assigns the ownership to the consumer <code> Alice </code> . </p> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> <p> Any of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : when the <em> JUSTID </em> option is specified, an array of IDs of messages successfully claimed. </li> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : an array of stream entries, each of which contains an array of two elements, the entry ID and the entry data itself. </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/xclaim/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/release-notes/rs-7-8-releases/rs-7-8-2-34/.html
<section class="prose w-full py-12 max-w-none"> <h1> Redis Software release notes 7.8.2-34 (November 2024) </h1> <p class="text-lg -mt-5 mb-10"> Redis Community Edition 7.4 features. Hash field expiration. Client-side caching support. Metrics stream engine preview. New APIs to check database availability, rebalance shards, fail over shards, and control database traffic. Cluster Manager UI enhancements for node actions, database tags, and database configuration. User manager role. Log rotation based on both size and time. Module management enhancements. Configurable minimum password length. Configurable license expiration alert threshold. </p> <p> ​ <a href="https://redis.com/redis-enterprise-software/download-center/software/"> ​Redis Software version 7.8.2 </a> is now available! </p> <h2 id="highlights"> Highlights </h2> <p> This version offers: </p> <ul> <li> <p> Redis Community Edition 7.4 features </p> </li> <li> <p> Hash field expiration </p> </li> <li> <p> Client-side caching support </p> </li> <li> <p> Metrics stream engine preview </p> </li> <li> <p> New APIs to check database availability, rebalance shards, fail over shards, and control database traffic </p> </li> <li> <p> Cluster Manager UI enhancements for node actions, database tags, and database configuration </p> </li> <li> <p> User manager role </p> </li> <li> <p> Log rotation based on both size and time </p> </li> <li> <p> Module management enhancements </p> </li> <li> <p> Configurable minimum password length </p> </li> <li> <p> Configurable license expiration alert threshold </p> </li> </ul> <h2 id="new-in-this-release"> New in this release </h2> <h3 id="new-features"> New features </h3> <ul> <li> <p> Redis Community Edition and Redis Stack 7.4 features are now available when you <a href="/docs/latest/operate/rs/databases/create/"> create </a> or <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/upgrade-database/"> upgrade </a> a database with database version 7.4, including: </p> <ul> <li> <p> <a href="/docs/latest/develop/data-types/hashes/#field-expiration"> Hash field expiration </a> </p> </li> <li> <p> New vector data types to reduce β€Œmemory usage </p> </li> <li> <p> Time series insertion filters </p> </li> <li> <p> See the <a href="https://redis.io/blog/announcing-redis-community-edition-and-redis-stack-74/"> Redis 7.4 release blog post </a> and <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisce/redisce-7.4-release-notes/"> Redis Community Edition 7.4 release notes </a> for details. </p> </li> </ul> </li> <li> <p> Client-side caching support: </p> <ul> <li> <p> Client-side caching allows Redis clients to store a subset of data in a local cache and avoid sending repeated read requests to the Redis database. </p> </li> <li> <p> When used to cache frequently accessed data, this technique can improve performance by decreasing network traffic, latency, and load on the database. </p> </li> <li> <p> Supported for Redis databases with Redis versions 7.4 and later. </p> </li> <li> <p> For more information, see the <a href="/docs/latest/develop/clients/client-side-caching/"> client-side caching introduction </a> and <a href="/docs/latest/operate/rs/references/compatibility/client-side-caching/"> client-side caching compatibility with Redis Software </a> . </p> </li> </ul> </li> <li> <p> Database availability API: </p> <ul> <li> <p> Verifies whether a Redis Software database is available to perform read and write operations and can respond to queries from client applications. </p> </li> <li> <p> Load balancers and automated monitoring tools can use this API to monitor database availability. </p> </li> <li> <p> See <a href="/docs/latest/operate/rs/databases/durability-ha/db-availability/"> Check database availability </a> and the <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/availability/"> REST API reference </a> for details. </p> </li> </ul> </li> <li> <p> Metrics stream engine preview: </p> <ul> <li> <p> The new metrics stream engine's exporter-based infrastructure provides access to more accurate, real-time data. This enhanced, scalable monitoring system allows you to set up more effective alerts and respond to issues faster. </p> </li> <li> <p> Exposes a new <code> /v2 </code> Prometheus scraping endpoint that you can use to export metrics to external monitoring tools such as Grafana, DataDog, NewRelic, and Dynatrace. </p> </li> <li> <p> Exports raw data instead of aggregated data to improve monitoring at scale and accuracy compared to v1 Prometheus metrics. </p> </li> <li> <p> For an initial list of metrics exported by the new metrics stream engine, see <a href="/docs/latest/integrate/prometheus-with-redis-enterprise/prometheus-metrics-definitions/"> Prometheus metrics v2 </a> . While the metrics stream engine is in preview, this document provides only a partial list. More metrics will be added. </p> </li> <li> <p> V1 Prometheus metrics are deprecated. To transition to the new metrics stream engine, either migrate your existing dashboards using <a href="/docs/latest/integrate/prometheus-with-redis-enterprise/prometheus-metrics-v1-to-v2/"> Prometheus v1 metrics and equivalent v2 PromQL </a> now, or wait to use new preconfigured dashboards when they become available in a future release. </p> </li> </ul> </li> <li> <p> <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/rebalance/"> Rebalance shard placement REST API request </a> , which distributes the database's shards across nodes based on the database's shard placement policy. See <a href="/docs/latest/operate/rs/databases/memory-performance/shard-placement-policy/"> Shard placement policy </a> for more information about shard placement and available policies. </p> </li> <li> <p> <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/failover/"> Shard failover REST API requests </a> , which perform failover on specified primary shards and promotes their replicas to primary shards. </p> </li> <li> <p> REST API requests to <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/stop_traffic/"> stop traffic </a> or <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/resume_traffic/"> resume traffic </a> to a database. </p> </li> </ul> <h3 id="enhancements"> Enhancements </h3> <ul> <li> <p> New Cluster Manager UI enhancements: </p> <ul> <li> <p> Perform node actions from the <strong> Nodes </strong> screen to <a href="/docs/latest/operate/rs/clusters/add-node/#verify-node"> verify nodes </a> , <a href="/docs/latest/operate/rs/clusters/change-node-role/"> set a node as primary or secondary </a> , <a href="/docs/latest/operate/rs/clusters/remove-node/"> remove nodes </a> , and manage node alert settings. </p> </li> <li> <p> Categorize databases with <a href="/docs/latest/operate/rs/databases/configure/db-tags/"> custom tags </a> . When you add new tags to a database, the keys and values already used by existing tags will appear as suggestions. </p> </li> <li> <p> Moved several settings on the database configuration screen: </p> <ul> <li> <p> The eviction setting now appears in the <a href="/docs/latest/operate/rs/databases/configure/#capacity"> <strong> Capacity </strong> </a> section. </p> </li> <li> <p> <a href="/docs/latest/operate/rs/databases/configure/#high-availability"> <strong> High availability </strong> </a> and <a href="/docs/latest/operate/rs/databases/configure/#durability"> <strong> Durability </strong> </a> have separate sections. </p> </li> </ul> </li> <li> <p> Improved error messages on the sign-in screen for locked out users versus incorrect or expired passwords. </p> </li> <li> <p> Flush an Active-Active database. </p> </li> </ul> </li> <li> <p> A new <strong> User Manager </strong> role designed for user administration is available for <a href="/docs/latest/operate/rs/security/access-control/"> role-based access control </a> . </p> <ul> <li> <p> This management role allows assigned users to create, edit, and delete users using the Cluster Manager UI and REST API. </p> </li> <li> <p> For more details about the privileges granted by the <strong> User Manager </strong> role, see <a href="/docs/latest/operate/rs/security/access-control/create-cluster-roles/#cluster-manager-ui-permissions"> Cluster Manager UI permissions </a> and <a href="/docs/latest/operate/rs/references/rest-api/permissions/#user-manager-role"> REST API permissions </a> . </p> </li> </ul> </li> <li> <p> When you upgrade a database, the upgrade process also attempts to upgrade database modules by default. </p> <ul> <li> <p> <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/upgrade/#upgrade-db"> <code> rladmin upgrade db </code> </a> will always upgrade the database's modules. </p> </li> <li> <p> If you <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/upgrade/#post-bdbs-upgrade"> upgrade a database </a> using the REST API, you can set <code> "latest_with_modules": false </code> in the request body to prevent module upgrades. </p> </li> </ul> </li> <li> <p> Added support for <a href="/docs/latest/operate/rs/clusters/logging/log-security/#log-rotation"> log rotation </a> based on both size and time. </p> </li> <li> <p> <a href="/docs/latest/operate/rs/security/access-control/manage-passwords/password-complexity-rules/#change-minimum-password-length"> Minimum password length </a> , previously hardcoded as 8 characters, is now configurable in the Cluster Manager UI and the REST API. </p> </li> <li> <p> The <a href="/docs/latest/operate/rs/clusters/configure/license-keys/#configure-license-expiration-alert"> cluster license expiration alert threshold </a> , which determines how far in advance you want to be notified of the license expiration, is configurable in the Cluster Manager UI and the REST API. </p> </li> <li> <p> The Cluster Manager UI's time zone can be configured with an <a href="/docs/latest/operate/rs/references/rest-api/requests/cm_settings/#put-cm-settings"> update CM settings REST API request </a> . </p> </li> <li> <p> Timeouts for raising connection alarms can be configured with an <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/#put-bdbs"> update database configuration REST API request </a> : </p> <ul> <li> <p> <code> crdt_sync_connection_alarm_timeout_seconds </code> : if the syncer takes longer than the specified number of seconds to connect to an Active-Active database, raise a connection alarm. </p> </li> <li> <p> <code> replica_sync_connection_alarm_timeout_seconds </code> : if the syncer takes longer than the specified number of seconds to connect to a replica, raise a connection alarm. </p> </li> </ul> </li> <li> <p> Reserved the following ports: </p> <table> <thead> <tr> <th> Port </th> <th> Process name </th> <th> Usage </th> </tr> </thead> <tbody> <tr> <td> 3347 </td> <td> cert_exporter </td> <td> Reports cluster certificate metrics </td> </tr> <tr> <td> 3348 </td> <td> process_exporter </td> <td> Reports process metrics for DMC and Redis processes </td> </tr> <tr> <td> 3349 </td> <td> cluster_wd_exporter </td> <td> Reports cluster watchdog metrics </td> </tr> <tr> <td> 3350 </td> <td> db_controller </td> <td> Internode communication </td> </tr> <tr> <td> 9091 </td> <td> node_exporter </td> <td> Reports host node metrics related to CPU, memory, disk, and more </td> </tr> <tr> <td> 9125 </td> <td> statsd_exporter </td> <td> Reports push metrics related to the DMC and syncer, and some cluster and node metrics </td> </tr> </tbody> </table> </li> </ul> <h3 id="redis-database-versions"> Redis database versions </h3> <p> Redis Software version 7.8.2 includes three Redis database versions: 7.4, 7.2, and 6.2. </p> <p> The <a href="/docs/latest/operate/rs/databases/configure/db-defaults/#database-version"> default Redis database version </a> is 7.4. </p> <h3 id="redis-module-feature-sets"> Redis module feature sets </h3> <p> Redis Software comes packaged with several modules. As of version 7.8.2, Redis Software includes three feature sets, compatible with different Redis database versions. </p> <p> The following table shows which Redis modules are compatible with each Redis database version included in this release. </p> <table> <thead> <tr> <th> Redis database version </th> <th> Compatible Redis modules </th> </tr> </thead> <tbody> <tr> <td> 7.4 </td> <td> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.10-release-notes/"> RediSearch 2.10.8 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisjson/redisjson-2.8-release-notes/"> RedisJSON 2.8.4 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redistimeseries/redistimeseries-1.12-release-notes/"> RedisTimeSeries 1.12.3 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.8-release-notes/"> RedisBloom 2.8.2 </a> </td> </tr> <tr> <td> 7.2 </td> <td> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.8-release-notes/"> RediSearch 2.8.19 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisjson/redisjson-2.6-release-notes/"> RedisJSON 2.6.13 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redistimeseries/redistimeseries-1.10-release-notes/"> RedisTimeSeries 1.10.15 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.6-release-notes/"> RedisBloom 2.6.15 </a> </td> </tr> <tr> <td> 6.2 </td> <td> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.6-release-notes/"> RediSearch 2.6.23 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisjson/redisjson-2.4-release-notes/"> RedisJSON 2.4.9 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redistimeseries/redistimeseries-1.8-release-notes/"> RedisTimeSeries 1.8.15 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.4-release-notes/"> RedisBloom 2.4.12 </a> <br/> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisgraph/redisgraph-2.10-release-notes/"> RedisGraph v2.10.15 </a> <sup> <a href="#module-note-1"> 1 </a> </sup> </td> </tr> </tbody> </table> <ol> <li> <a name="module-note-1"> </a> RedisGraph end-of-life has been announced and will be removed in a future release. See the <a href="https://redis.io/blog/redisgraph-eol/"> RedisGraph end-of-life announcement </a> for more details. </li> </ol> <h3 id="resolved-issues"> Resolved issues </h3> <ul> <li> <p> RS123645: Fixed inconsistent behavior for shard creation when you enable sharding. Now, when creating a database with sharding enabled, you must always provide a <code> shard_key_regex </code> . </p> </li> <li> <p> RS130444: Fixed an issue that prevented creating or editing users without an email address in the Cluster Manager UI. </p> </li> <li> <p> RS121796: The "multiple endpoint" configuration database default setting should also enable sharding when selected. </p> </li> <li> <p> RS128768: Fixed an issue that prevented metric graph timestamp details from displaying in the Cluster Manager UI. </p> </li> <li> <p> RS127120: Fixed an issue where <code> crdt_replicas </code> were not properly updated when flushing an Active-Active database. </p> </li> <li> <p> RS127054: Fixed an issue where the install script incorrectly reported "Port 53 is occupied" instead of the correct value of the occupied port. </p> </li> <li> <p> RS125934: Fixed validation that prevented updating the Active-Active database configuration if existing TLS certificates expired. </p> </li> <li> <p> RS125412: Fixed an issue where deleted external IP addresses were still listed as available during node configuration when joining a cluster. </p> </li> <li> <p> RS122012: Fixed an issue that sent a cutoff email message for long-running alerts. </p> </li> <li> <p> RS121726: Block the <code> remove_shards </code> option for <code> rlutil </code> . You can use Replica Of to decrease the shard count instead. </p> </li> <li> <p> RS121076: Added a 5-minute connection timeout when promoting a replica shard to a primary role. </p> </li> <li> <p> RS118103: Removed the inaccurate shard <code> BACKUP_PROGRESS </code> column from the <code> rladmin status </code> command's output. </p> </li> <li> <p> RS116990: Fixed an issue with flash-enabled databases where <code> FLUSHDB </code> could cause shard crashes in versions 7.0 and 7.2, and cause clients to stop responding in earlier versions. </p> </li> <li> <p> RS114923: Fixed an issue where the legacy RDB parser could generate an <code> XGROUP CREATE </code> command with an incorrect <code> ENTRIESREAD </code> value when syncing a source RDB to a database with Redis version 7.0 or later. </p> </li> <li> <p> RS114258: Fixed an issue where an Active-Active database instance could lose keys during partial syncing if the destination shard was stale. </p> </li> <li> <p> RS133653: Fixed a validation issue where expired client certificates prevented updates to database configuration unrelated to TLS. </p> </li> <li> <p> RS126235: Fixed an issue where database updates could time out and enter a change pending state due to outdated shard data. </p> </li> <li> <p> RS125128: Improved real-time logging for installation and upgrade for better visibility. </p> </li> <li> <p> RS119958: Removed the log file limit that caused the debuginfo script to fail with the error "/bin/tar: Argument list too long" in Auto Tiering clusters and improved RocksDB log file rotation. </p> </li> <li> <p> RS137396: Providing an email address is no longer mandatory when creating new ACL users in the Cluster Manager UI. </p> </li> <li> <p> RS134238: Improved database sorting performance in the Cluster Manager UI. </p> </li> <li> <p> RS129418: Improved log rotation mechanism for Auto Tiering clusters to reduce excessive logs. </p> </li> <li> <p> RS137231: Fixed an issue where database shards could become stuck during migration due to outdated node data. </p> </li> </ul> <h2 id="version-changes"> Version changes </h2> <ul> <li> <p> Added validation to verify the LDAP server URI contains a host and port when updating LDAP configuration. </p> </li> <li> <p> The value of the <code> oss_sharding </code> API field had no effect in previous versions of Redis Software. However, <code> oss_sharding </code> is now set to take effect as part of future plans. Until further notice, set this field to <code> false </code> to avoid unintended impacts. </p> </li> </ul> <h3 id="breaking-changes"> Breaking changes </h3> <p> Redis Software version 7.8.2 introduces the following breaking changes: </p> <ul> <li> <p> When you upgrade a database, the upgrade process also attempts to upgrade database modules by default. </p> <ul> <li> <p> The default value of <code> latest_with_modules </code> has changed to <code> true </code> . </p> </li> <li> <p> <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/upgrade/#upgrade-db"> <code> rladmin upgrade db </code> </a> will always upgrade the database's modules. </p> </li> <li> <p> When you <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/upgrade/#post-bdbs-upgrade"> upgrade a database </a> using the REST API, you can set <code> "latest_with_modules": false </code> in the request body to prevent module upgrades. </p> </li> </ul> </li> </ul> <h3 id="redis-74-breaking-changes"> Redis database version 7.4 breaking changes </h3> <p> When new major versions of Redis Community Edition change existing commands, upgrading your database to a new version can potentially break some functionality. Before you upgrade, read the provided list of breaking changes that affect Redis Software and update any applications that connect to your database to handle these changes. </p> <p> Confirm your Redis database version ( <code> redis_version </code> ) using the Cluster Manager UI or run the following <a href="/docs/latest/commands/info/"> <code> INFO </code> </a> command with <a href="/docs/latest/operate/rs/references/cli-utilities/redis-cli/"> <code> redis-cli </code> </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ redis-cli -p &lt;port&gt; INFO </span></span><span class="line"><span class="cl"><span class="s2">"# Server </span></span></span><span class="line"><span class="cl"><span class="s2">redis_version:7.0.8 </span></span></span><span class="line"><span class="cl"><span class="s2">..."</span> </span></span></code></pre> </div> <h4 id="security-behavior-changes"> Security behavior changes </h4> <ul> <li> <a href="https://github.com/redis/redis/pull/13108"> #13108 </a> Lua: LRU eviction for scripts generated with <code> EVAL </code> . </li> </ul> <h4 id="other-general-behavior-changes"> Other general behavior changes </h4> <ul> <li> <p> <a href="https://github.com/redis/redis/pull/13133"> #13133 </a> Lua: allocate VM code with jemalloc instead of libc and count it as used memory. </p> </li> <li> <p> <a href="https://github.com/redis/redis/pull/12171"> #12171 </a> <code> ACL LOAD </code> : do not disconnect all clients. </p> </li> </ul> <h3 id="product-lifecycle-updates"> Product lifecycle updates </h3> <h4 id="end-of-life-policy-extension"> End-of-life policy extension </h4> <p> The end-of-life policy for Redis Software versions 6.2 and later has been extended to 24 months after the formal release of the subsequent major version. For the updated end-of-life schedule, see the <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/"> Redis Software product lifecycle </a> . </p> <h4 id="supported-upgrade-paths"> Supported upgrade paths </h4> <p> Redis Software versions 6.2.4 and 6.2.8 do not support direct upgrades beyond version 7.4.x. Versions 6.2.10, 6.2.12, and 6.2.18 are part of the <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/upgrade-cluster/#supported-upgrade-paths"> upgrade path </a> . To upgrade from 6.2.4 or 6.2.8 to versions later than 7.4.x, an intermediate upgrade is required. </p> <p> The next major Redis Software release will still bundle Redis database version 6.2 and allow database upgrades from Redis database version 6.2 to 7.x. </p> <p> See the <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/"> Redis Software product lifecycle </a> for more information about release numbers. </p> <h4 id="end-of-triggers-and-functions-preview"> End of triggers and functions preview </h4> <p> The <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/deprecated-features/triggers-and-functions/"> triggers and functions </a> (RedisGears) preview has been discontinued. </p> <ul> <li> <p> Commands such as <code> TFCALL </code> , <code> TFCALLASYNC </code> , and <code> TFUNCTION </code> will be deprecated and will return error messages. </p> </li> <li> <p> Any JavaScript functions stored in Redis will be removed. </p> </li> <li> <p> JavaScript-based triggers will be blocked. </p> </li> <li> <p> Lua functions and scripts will not be affected. </p> </li> </ul> <p> If your database currently uses triggers and functions, you need to: </p> <ol> <li> <p> Adjust your applications to accommodate these changes. </p> </li> <li> <p> Delete all triggers and functions libraries from your existing database: </p> <ol> <li> <p> Run <code> TFUNCTION LIST </code> . </p> </li> <li> <p> Copy all library names. </p> </li> <li> <p> Run <code> TFUNCTION DELETE </code> for each library in the list. </p> </li> </ol> <p> If any triggers and functions libraries remain in the database, the RDB snapshot won't load on a cluster without RedisGears. </p> </li> <li> <p> Migrate your database to a new database without the RedisGears module. </p> </li> </ol> <h3 id="deprecations"> Deprecations </h3> <h4 id="api-deprecations"> API deprecations </h4> <ul> <li> <p> Deprecated <code> background_op </code> field from BDB REST API object. Use <a href="/docs/latest/operate/rs/references/rest-api/requests/actions/bdb/"> <code> GET /v1/actions/bdb/&lt;bdb_uid&gt; </code> </a> instead. </p> </li> <li> <p> Deprecated the following fields for <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/upgrade/"> upgrade database </a> REST API requests: </p> <ul> <li> <p> <code> keep_redis_version </code> ; use <code> redis_version </code> instead </p> </li> <li> <p> <code> current_module </code> ; use <code> new_module_args </code> instead </p> </li> <li> <p> <code> new_module </code> ; use <code> new_module_args </code> instead </p> </li> </ul> </li> <li> <p> Deprecated the following <code> module_list </code> fields for <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/#post-bdbs-v1"> create database </a> REST API requests: </p> <ul> <li> <p> <code> module_id </code> ; use <code> module_name </code> instead </p> </li> <li> <p> <code> semantic_version </code> ; use module_args instead </p> </li> </ul> </li> <li> <p> <code> min_redis_version </code> is only relevant to Redis database versions earlier than 7.4 and is replaced with <code> compatible_redis_version </code> in <a href="/docs/latest/operate/rs/references/rest-api/requests/modules/"> module REST API </a> responses. </p> </li> <li> <p> Deprecated the <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/upgrade/#upgrade-module"> <code> rladmin upgrade modules </code> </a> command. Use <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/upgrade/#upgrade-db"> <code> rladmin upgrade db </code> </a> instead. </p> </li> <li> <p> Deprecated <a href="/docs/latest/operate/rs/references/rest-api/requests/modules/upgrade/#post-modules-upgrade-bdb"> <code> POST /v1/modules/upgrade/bdb/&lt;uid&gt; </code> </a> REST API request. Use <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/upgrade/#post-bdbs-upgrade"> <code> POST /v1/bdbs/&lt;uid&gt;/upgrade </code> </a> to upgrade modules instead. </p> </li> </ul> <h4 id="v1-prometheus-metrics-deprecation"> V1 Prometheus metrics deprecation </h4> <p> V1 Prometheus metrics are deprecated. To transition to the new metrics stream engine, either migrate your existing dashboards using <a href="/docs/latest/integrate/prometheus-with-redis-enterprise/prometheus-metrics-v1-to-v2/"> Prometheus v1 metrics and equivalent v2 PromQL </a> now, or wait to use new preconfigured dashboards when they become available in a future release. </p> <h4 id="download-center-modules-deprecation"> Download center modules deprecation </h4> <p> New Redis modules will not be available for download from the Redis download center. </p> <h4 id="legacy-ui-not-supported"> Legacy UI not supported </h4> <p> The legacy UI was deprecated in favor of the new Cluster Manager UI in Redis Software version 7.2.4 and is no longer supported as of Redis Software version 7.8.2. </p> <h4 id="redis-60-databases-not-supported"> Redis 6.0 databases not supported </h4> <p> Redis database version 6.0 was deprecated in Redis Software version 7.4.2 and is no longer supported as of Redis Software version 7.8.2. </p> <p> To prepare for the removal of Redis database version 6.0 before you upgrade to Redis Software version 7.8.2: </p> <ul> <li> <p> For Redis Software 6.2.* clusters, upgrade Redis 6.0 databases to Redis 6.2. See the <a href="https://raw.githubusercontent.com/redis/redis/6.2/00-RELEASENOTES"> Redis 6.2 release notes </a> for the list of changes. </p> </li> <li> <p> For Redis Software 7.2.4 and 7.4.2 clusters, upgrade Redis 6.0 databases to Redis 7.2. Before you upgrade your databases, see the list of <a href="/docs/latest/operate/rs/release-notes/rs-7-2-4-releases/rs-7-2-4-52/#redis-72-breaking-changes"> Redis 7.2 breaking changes </a> and update any applications that connect to your database to handle these changes. </p> </li> </ul> <h4 id="ubuntu-1804-not-supported"> Ubuntu 18.04 not supported </h4> <p> Ubuntu 18.04 was deprecated in Redis Software version 7.2.4 and is no longer supported as of Redis Software version 7.8.2. </p> <h3 id="upcoming-changes"> Upcoming changes </h3> <h4 id="default-image-change-for-redis-software-containers"> Default image change for Redis Software containers </h4> <p> Starting with version 7.8, Redis Software containers with the image tag <code> x.y.z-build </code> will be based on RHEL instead of Ubuntu. </p> <p> This change will only affect you if you use containers outside the official <a href="/docs/latest/operate/kubernetes/"> Redis Enterprise for Kubernetes </a> product and use Ubuntu-specific commands. </p> <p> To use Ubuntu-based images after this change, you can specify the operating system suffix in the image tag. For example, use the image tag <code> 7.4.2-216.focal </code> instead of <code> 7.4.2-216 </code> . </p> <h3 id="supported-platforms"> Supported platforms </h3> <p> The following table provides a snapshot of supported platforms as of this Redis Software release. See the <a href="/docs/latest/operate/rs/references/supported-platforms/"> supported platforms reference </a> for more details about operating system compatibility. </p> <p> <span title="Check mark icon"> βœ… </span> Supported – The platform is supported for this version of Redis Software and Redis Stack modules. </p> <p> <span class="font-serif" title="Warning icon"> ⚠️ </span> Deprecation warning – The platform is still supported for this version of Redis Software, but support will be removed in a future release. </p> <table> <thead> <tr> <th> Redis Software <br/> major versions </th> <th style="text-align:center"> 7.8 </th> <th style="text-align:center"> 7.4 </th> <th style="text-align:center"> 7.2 </th> <th style="text-align:center"> 6.4 </th> <th style="text-align:center"> 6.2 </th> </tr> </thead> <tbody> <tr> <td> <strong> Release date </strong> </td> <td style="text-align:center"> Nov 2024 </td> <td style="text-align:center"> Feb 2024 </td> <td style="text-align:center"> Aug 2023 </td> <td style="text-align:center"> Feb 2023 </td> <td style="text-align:center"> Aug 2021 </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/#endoflife-schedule"> <strong> End-of-life date </strong> </a> </td> <td style="text-align:center"> Determined after <br/> next major release </td> <td style="text-align:center"> Nov 2026 </td> <td style="text-align:center"> Feb 2026 </td> <td style="text-align:center"> Aug 2025 </td> <td style="text-align:center"> Feb 2025 </td> </tr> <tr> <td> <strong> Platforms </strong> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> </tr> <tr> <td> RHEL 9 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> </tr> <tr> <td> RHEL 9 <br/> FIPS mode <sup> <a href="#table-note-5"> 5 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> </tr> <tr> <td> RHEL 8 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> RHEL 7 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 20.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Ubuntu 18.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 16.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Amazon Linux 2 </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Amazon Linux 1 </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Kubernetes <sup> <a href="#table-note-3"> 3 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Docker <sup> <a href="#table-note-4"> 4 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> </tbody> </table> <ol> <li> <p> <a name="table-note-1"> </a> The RHEL-compatible distributions CentOS, CentOS Stream, Alma, and Rocky are supported if they have full RHEL compatibility. Oracle Linux running the Red Hat Compatible Kernel (RHCK) is supported, but the Unbreakable Enterprise Kernel (UEK) is not supported. </p> </li> <li> <p> <a name="table-note-2"> </a> The server version of Ubuntu is recommended for production installations. The desktop version is only recommended for development deployments. </p> </li> <li> <p> <a name="table-note-3"> </a> See the <a href="/docs/latest/operate/kubernetes/reference/supported_k8s_distributions/"> Redis Enterprise for Kubernetes documentation </a> for details about support per version and Kubernetes distribution. </p> </li> <li> <p> <a name="table-note-4"> </a> <a href="/docs/latest/operate/rs/installing-upgrading/quickstarts/docker-quickstart/"> Docker images </a> of Redis Software are certified for development and testing only. </p> </li> <li> <p> <a name="table-note-5"> </a> Supported only if <a href="https://docs.redhat.com/en/documentation/red_hat_enterprise_linux/9/html/security_hardening/switching-rhel-to-fips-mode_security-hardening#proc_installing-the-system-with-fips-mode-enabled_switching-rhel-to-fips-mode"> FIPS was enabled during RHEL installation </a> to ensure FIPS compliance. </p> </li> </ol> <h2 id="downloads"> Downloads </h2> <p> The following table shows the SHA256 checksums for the available packages: </p> <table> <thead> <tr> <th> Package </th> <th> SHA256 checksum (7.8.2-34 Nov release) </th> </tr> </thead> <tbody> <tr> <td> Ubuntu 20 </td> <td> <span class="break-all"> 17500356d8338e4f8fd8a37e7b39a190d05ca66d35ae6c4aa3aa8cbc7bb99864 </span> </td> </tr> <tr> <td> Red Hat Enterprise Linux (RHEL) 8 </td> <td> <span class="break-all"> caa2ccd24749ae1fb904841df50a8b69b69c74441458649ca49b9b617e286191 </span> </td> </tr> <tr> <td> Red Hat Enterprise Linux (RHEL) 9 </td> <td> <span class="break-all"> 31f9d07beb7dfd9239083ecad99ecbfe3cdfcf96673881ebed08171d8194bff3 </span> </td> </tr> <tr> <td> Amazon Linux 2 </td> <td> <span class="break-all"> a737ca86d800caf9ca266d5771fbcffd3f973a7fb8e63e7b819681322ff6ed67 </span> </td> </tr> </tbody> </table> <h2 id="known-issues"> Known issues </h2> <ul> <li> RS131972: Creating an ACL that contains a line break in the Cluster Manager UI can cause shard migration to fail due to ACL errors. </li> </ul> <h2 id="known-limitations"> Known limitations </h2> <h4 id="new-cluster-manager-ui-limitations"> New Cluster Manager UI limitations </h4> <p> The following legacy UI features are not yet available in the new Cluster Manager UI: </p> <ul> <li> <p> Purge an Active-Active instance. </p> <p> Use <a href="/docs/latest/operate/rs/references/cli-utilities/crdb-cli/crdb/purge-instance/"> <code> crdb-cli crdb purge-instance </code> </a> instead. </p> </li> <li> <p> Search and export the log. </p> </li> </ul> <h4 id="redisgraph-prevents-upgrade-to-rhel-9"> RedisGraph prevents upgrade to RHEL 9 </h4> <p> You cannot upgrade from a prior RHEL version to RHEL 9 if the Redis Software cluster contains a RedisGraph module, even if unused by any database. The <a href="https://redis.com/blog/redisgraph-eol/"> RedisGraph module has reached End-of-Life </a> and is completely unavailable in RHEL 9. </p> <h2 id="security"> Security </h2> <h4 id="open-source-redis-security-fixes-compatibility"> Open source Redis security fixes compatibility </h4> <p> As part of Redis's commitment to security, Redis Software implements the latest <a href="https://github.com/redis/redis/releases"> security fixes </a> available with <a href="https://github.com/redis/redis"> open source Redis </a> . Redis Software has already included the fixes for the relevant CVEs. </p> <p> Some CVEs announced for open source Redis do not affect Redis Software due to different or additional functionality available in Redis Software that is not available in open source Redis. </p> <p> Redis Software 7.8.2-34 supports open source Redis 7.4, 7.2, and 6.2. Below is the list of open source Redis CVEs fixed by version. </p> <p> Redis 7.2.x: </p> <ul> <li> <p> (CVE-2024-31449) An authenticated user may use a specially crafted Lua script to trigger a stack buffer overflow in the bit library, which may potentially lead to remote code execution. </p> </li> <li> <p> (CVE-2024-31228) An authenticated user can trigger a denial-of-service by using specially crafted, long string match patterns on supported commands such as <code> KEYS </code> , <code> SCAN </code> , <code> PSUBSCRIBE </code> , <code> FUNCTION LIST </code> , <code> COMMAND LIST </code> , and ACL definitions. Matching of extremely long patterns may result in unbounded recursion, leading to stack overflow and process crashes. </p> </li> <li> <p> (CVE-2023-41056) In some cases, Redis may incorrectly handle resizing of memory buffers, which can result in incorrect accounting of buffer sizes and lead to heap overflow and potential remote code execution. </p> </li> <li> <p> (CVE-2023-41053) Redis does not correctly identify keys accessed by <code> SORT_RO </code> and, as a result, may grant users executing this command access to keys that are not explicitly authorized by the ACL configuration. (Redis 7.2.1) </p> </li> </ul> <p> Redis 7.0.x: </p> <ul> <li> <p> (CVE-2024-31449) An authenticated user may use a specially crafted Lua script to trigger a stack buffer overflow in the bit library, which may potentially lead to remote code execution. </p> </li> <li> <p> (CVE-2024-31228) An authenticated user can trigger a denial-of-service by using specially crafted, long string match patterns on supported commands such as <code> KEYS </code> , <code> SCAN </code> , <code> PSUBSCRIBE </code> , <code> FUNCTION LIST </code> , <code> COMMAND LIST </code> , and ACL definitions. Matching of extremely long patterns may result in unbounded recursion, leading to stack overflow and process crashes. </p> </li> <li> <p> (CVE-2023-41056) In some cases, Redis may incorrectly handle resizing of memory buffers, which can result in incorrect accounting of buffer sizes and lead to heap overflow and potential remote code execution. </p> </li> <li> <p> (CVE-2023-41053) Redis does not correctly identify keys accessed by <code> SORT_RO </code> and, as a result, may grant users executing this command access to keys that are not explicitly authorized by the ACL configuration. (Redis 7.0.13) </p> </li> <li> <p> (CVE-2023-36824) Extracting key names from a command and a list of arguments may, in some cases, trigger a heap overflow and result in reading random heap memory, heap corruption, and potentially remote code execution. Specifically: using <code> COMMAND GETKEYS* </code> and validation of key names in ACL rules. (Redis 7.0.12) </p> </li> <li> <p> (CVE-2023-28856) Authenticated users can use the <code> HINCRBYFLOAT </code> command to create an invalid hash field that will crash Redis on access. (Redis 7.0.11) </p> </li> <li> <p> (CVE-2023-28425) Specially crafted <code> MSETNX </code> commands can lead to assertion and denial-of-service. (Redis 7.0.10) </p> </li> <li> <p> (CVE-2023-25155) Specially crafted <code> SRANDMEMBER </code> , <code> ZRANDMEMBER </code> , and <code> HRANDFIELD </code> commands can trigger an integer overflow, resulting in a runtime assertion and termination of the Redis server process. (Redis 7.0.9) </p> </li> <li> <p> (CVE-2023-22458) Integer overflow in the Redis <code> HRANDFIELD </code> and <code> ZRANDMEMBER </code> commands can lead to denial-of-service. (Redis 7.0.8) </p> </li> <li> <p> (CVE-2022-36021) String matching commands (like <code> SCAN </code> or <code> KEYS </code> ) with a specially crafted pattern to trigger a denial-of-service attack on Redis can cause it to hang and consume 100% CPU time. (Redis 7.0.9) </p> </li> <li> <p> (CVE-2022-35977) Integer overflow in the Redis <code> SETRANGE </code> and <code> SORT </code> / <code> SORT_RO </code> commands can drive Redis to OOM panic. (Redis 7.0.8) </p> </li> <li> <p> (CVE-2022-35951) Executing an <code> XAUTOCLAIM </code> command on a stream key in a specific state, with a specially crafted <code> COUNT </code> argument, may cause an integer overflow, a subsequent heap overflow, and potentially lead to remote code execution. The problem affects Redis versions 7.0.0 or newer. (Redis 7.0.5) </p> </li> <li> <p> (CVE-2022-31144) A specially crafted <code> XAUTOCLAIM </code> command on a stream key in a specific state may result in heap overflow and potentially remote code execution. The problem affects Redis versions 7.0.0 or newer. (Redis 7.0.4) </p> </li> <li> <p> (CVE-2022-24834) A specially crafted Lua script executing in Redis can trigger a heap overflow in the cjson and cmsgpack libraries, and result in heap corruption and potentially remote code execution. The problem exists in all versions of Redis with Lua scripting support, starting from 2.6, and affects only authenticated and authorized users. (Redis 7.0.12) </p> </li> <li> <p> (CVE-2022-24736) An attacker attempting to load a specially crafted Lua script can cause NULL pointer dereference which will result in a crash of the <code> redis-server </code> process. This issue affects all versions of Redis. (Redis 7.0.0) </p> </li> <li> <p> (CVE-2022-24735) By exploiting weaknesses in the Lua script execution environment, an attacker with access to Redis can inject Lua code that will execute with the (potentially higher) privileges of another Redis user. (Redis 7.0.0) </p> </li> </ul> <p> Redis 6.2.x: </p> <ul> <li> <p> (CVE-2024-31449) An authenticated user may use a specially crafted Lua script to trigger a stack buffer overflow in the bit library, which may potentially lead to remote code execution. </p> </li> <li> <p> (CVE-2024-31228) An authenticated user can trigger a denial-of-service by using specially crafted, long string match patterns on supported commands such as <code> KEYS </code> , <code> SCAN </code> , <code> PSUBSCRIBE </code> , <code> FUNCTION LIST </code> , <code> COMMAND LIST </code> , and ACL definitions. Matching of extremely long patterns may result in unbounded recursion, leading to stack overflow and process crashes. </p> </li> <li> <p> (CVE-2023-28856) Authenticated users can use the <code> HINCRBYFLOAT </code> command to create an invalid hash field that will crash Redis on access. (Redis 6.2.12) </p> </li> <li> <p> (CVE-2023-25155) Specially crafted <code> SRANDMEMBER </code> , <code> ZRANDMEMBER </code> , and <code> HRANDFIELD </code> commands can trigger an integer overflow, resulting in a runtime assertion and termination of the Redis server process. (Redis 6.2.11) </p> </li> <li> <p> (CVE-2023-22458) Integer overflow in the Redis <code> HRANDFIELD </code> and <code> ZRANDMEMBER </code> commands can lead to denial-of-service. (Redis 6.2.9) </p> </li> <li> <p> (CVE-2022-36021) String matching commands (like <code> SCAN </code> or <code> KEYS </code> ) with a specially crafted pattern to trigger a denial-of-service attack on Redis can cause it to hang and consume 100% CPU time. (Redis 6.2.11) </p> </li> <li> <p> (CVE-2022-35977) Integer overflow in the Redis <code> SETRANGE </code> and <code> SORT </code> / <code> SORT_RO </code> commands can drive Redis to OOM panic. (Redis 6.2.9) </p> </li> <li> <p> (CVE-2022-24834) A specially crafted Lua script executing in Redis can trigger a heap overflow in the cjson and cmsgpack libraries, and result in heap corruption and potentially remote code execution. The problem exists in all versions of Redis with Lua scripting support, starting from 2.6, and affects only authenticated and authorized users. (Redis 6.2.13) </p> </li> <li> <p> (CVE-2022-24736) An attacker attempting to load a specially crafted Lua script can cause NULL pointer dereference which will result in a crash of the <code> redis-server </code> process. This issue affects all versions of Redis. (Redis 6.2.7) </p> </li> <li> <p> (CVE-2022-24735) By exploiting weaknesses in the Lua script execution environment, an attacker with access to Redis can inject Lua code that will execute with the (potentially higher) privileges of another Redis user. (Redis 6.2.7) </p> </li> <li> <p> (CVE-2021-41099) Integer to heap buffer overflow handling certain string commands and network payloads, when <code> proto-max-bulk-len </code> is manually configured to a non-default, very large value. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32762) Integer to heap buffer overflow issue in <code> redis-cli </code> and <code> redis-sentinel </code> parsing large multi-bulk replies on some older and less common platforms. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32761) An integer overflow bug in Redis version 2.2 or newer can be exploited using the <code> BITFIELD </code> command to corrupt the heap and potentially result with remote code execution. (Redis 6.2.5) </p> </li> <li> <p> (CVE-2021-32687) Integer to heap buffer overflow with intsets, when <code> set-max-intset-entries </code> is manually configured to a non-default, very large value. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32675) Denial Of Service when processing RESP request payloads with a large number of elements on many connections. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32672) Random heap reading issue with Lua Debugger. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32628) Integer to heap buffer overflow handling ziplist-encoded data types, when configuring a large, non-default value for <code> hash-max-ziplist-entries </code> , <code> hash-max-ziplist-value </code> , <code> zset-max-ziplist-entries </code> or <code> zset-max-ziplist-value </code> . (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32627) Integer to heap buffer overflow issue with streams, when configuring a non-default, large value for <code> proto-max-bulk-len </code> and <code> client-query-buffer-limit </code> . (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32626) Specially crafted Lua scripts may result with Heap buffer overflow. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32625) An integer overflow bug in Redis version 6.0 or newer can be exploited using the STRALGO LCS command to corrupt the heap and potentially result with remote code execution. This is a result of an incomplete fix by CVE-2021-29477. (Redis 6.2.4) </p> </li> <li> <p> (CVE-2021-29478) An integer overflow bug in Redis 6.2 could be exploited to corrupt the heap and potentially result with remote code execution. The vulnerability involves changing the default set-max-intset-entries configuration value, creating a large set key that consists of integer values and using the COPY command to duplicate it. The integer overflow bug exists in all versions of Redis starting with 2.6, where it could result with a corrupted RDB or DUMP payload, but not exploited through COPY (which did not exist before 6.2). (Redis 6.2.3) </p> </li> <li> <p> (CVE-2021-29477) An integer overflow bug in Redis version 6.0 or newer could be exploited using the STRALGO LCS command to corrupt the heap and potentially result in remote code execution. The integer overflow bug exists in all versions of Redis starting with 6.0. (Redis 6.2.3) </p> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/release-notes/rs-7-8-releases/rs-7-8-2-34/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/reference/internals/.html
<section class="prose w-full py-12 max-w-none"> <h1> Redis internals </h1> <p class="text-lg -mt-5 mb-10"> Documents describing internals in early Redis implementations </p> <p> <strong> The following Redis documents were written by the creator of Redis, Salvatore Sanfilippo, early in the development of Redis (c. 2010), and do not necessarily reflect the latest Redis implementation. </strong> </p> <nav> <a href="/docs/latest/operate/oss_and_stack/reference/internals/internals-rediseventlib/"> Event library </a> <p> What's an event library, and how was the original Redis event library implemented? </p> <a href="/docs/latest/operate/oss_and_stack/reference/internals/internals-sds/"> String internals </a> <p> Guide to the original implementation of Redis strings </p> <a href="/docs/latest/operate/oss_and_stack/reference/internals/internals-vm/"> Virtual memory (deprecated) </a> <p> A description of the Redis virtual memory system that was deprecated in 2.6. This document exists for historical interest. </p> <a href="/docs/latest/operate/oss_and_stack/reference/internals/rdd/"> Redis design draft #2 (historical) </a> <p> A design for the RDB format written in the early days of Redis </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/reference/internals/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/resume_traffic/.html
<section class="prose w-full py-12 max-w-none"> <h1> Resume database traffic requests </h1> <p class="text-lg -mt-5 mb-10"> REST API requests to resume traffic for a database </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#post-bdbs-actions-resume-traffic"> POST </a> </td> <td> <code> /v1/bdbs/{uid}/actions/resume_traffic </code> </td> <td> Resume database traffic </td> </tr> </tbody> </table> <h2 id="post-bdbs-actions-resume-traffic"> Resume database traffic </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span>/actions/resume_traffic </span></span></code></pre> </div> <p> Resume traffic handling for the database. </p> <p> Use this action to resume read and write traffic on a database, where traffic was previously paused using the <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/stop_traffic/"> <code> stop_traffic </code> </a> action. </p> <h4 id="required-permissions"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_bdb_with_action"> update_bdb_with_action </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="post-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /bdbs/1/actions/resume_traffic </span></span></code></pre> </div> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database. </td> </tr> </tbody> </table> <h3 id="post-response"> Response </h3> <p> Returns a JSON object with an <code> action_uid </code> . You can track the action's progress with a <a href="/docs/latest/operate/rs/references/rest-api/requests/actions/#get-action"> <code> GET /v1/actions/&lt;action_uid&gt; </code> </a> request. </p> <h4 id="post-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-200-ok"> 200 OK </a> </td> <td> The request is accepted and is being processed. The database state will be <code> active-change-pending </code> until the request has been fully processed. </td> </tr> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-404-not-found"> 404 Not Found </a> </td> <td> Attempting to perform an action on a nonexistent database. </td> </tr> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-409-conflict"> 409 Conflict </a> </td> <td> Attempting to change a database while it is busy with another configuration change. This is a temporary condition, and the request should be reattempted later. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/resume_traffic/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/databases/auto-tiering/quickstart/.html
<section class="prose w-full py-12 max-w-none"> <h1> Auto Tiering quick start </h1> <p class="text-lg -mt-5 mb-10"> Get started with Auto Tiering quickly, creating a cluster and database using flash storage. </p> <p> This page guides you through a quick setup of <a href="/docs/latest/operate/rs/databases/auto-tiering/"> Auto Tiering </a> with a single node for testing and demo purposes. </p> <p> For production environments, you can find more detailed installation instructions in the <a href="/docs/latest/operate/rs/installing-upgrading/"> install and setup </a> section. </p> <p> The steps to set up a Redis Enterprise Software cluster using Auto Tiering with a single node are: </p> <ol> <li> Install Redis Enterprise Software or run it in a Docker container. </li> <li> Set up a Redis Enterprise Software cluster withΒ Auto Tiering. </li> <li> Create a new database with Auto Tiering enabled. </li> <li> Connect to your newΒ database. </li> </ol> <h2 id="install-redis-enterprise-software"> Install Redis Enterprise Software </h2> <h3 id="bare-metal-vm-cloud-instance"> Bare metal, VM, Cloud instance </h3> <p> To install on bare metal, a virtual machine, or an instance: </p> <ol> <li> <p> Download the binaries from the <a href="https://cloud.redis.io/#/sign-up/software?direct=true"> Redis Enterprise download center </a> . </p> </li> <li> <p> Upload the binaries to a Linux-based operating system. </p> </li> <li> <p> Extract the image: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">tar -vxf &lt;downloaded tar file name&gt; </span></span></code></pre> </div> </li> <li> <p> After the <code> tar </code> command completes, you can find a new <code> install.sh </code> script in the current directory: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">sudo ./install.sh -y </span></span></code></pre> </div> </li> </ol> <h3 id="dockerbased-installation"> Docker-based installation </h3> <p> For testing purposes, you can run a Redis Enterprise Software Docker container on Windows, MacOS, and Linux. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">docker run -d --cap-add sys_resource --name rp -p 8443:8443 -p 12000:12000 redislabs/redis:latest </span></span></code></pre> </div> <h2 id="prepare-and-format-flash-memory"> Prepare and format flash memory </h2> <p> After you <a href="#install-redis-enterprise-software"> install Redis Enterprise Software </a> , use the <code> prepare_flash </code> script to prepare and format flash memory: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">sudo /opt/redislabs/sbin/prepare_flash.sh </span></span></code></pre> </div> <p> This script finds unformatted disks and mounts them as RAID partitions in <code> /var/opt/redislabs/flash </code> . </p> <p> To verify the disk configuration, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">sudo lsblk </span></span></code></pre> </div> <h2 id="set-up-a-clusterand-enable-auto-tiering"> Set up a clusterΒ and enable Auto Tiering </h2> <ol> <li> <p> Direct your browser to <code> https://localhost:8443 </code> on the host machine to see the Redis Enterprise Software Cluster Manager UI. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Depending on your browser, you may see a certificate error. Choose "continue to the website" to go to the setup screen. </div> </div> </li> <li> <p> Select <strong> Create new cluster </strong> . </p> </li> <li> <p> Set up account credentials for a cluster administrator, then select <strong> Next </strong> to proceed to cluster setup. </p> </li> <li> <p> Enter your cluster license key if you have one. Otherwise, the cluster uses the trial version. </p> </li> <li> <p> Provide a cluster FQDN such as <code> mycluster.local </code> , then select <strong> Next </strong> . </p> </li> <li> <p> In the <strong> Storage configuration </strong> section, turn on the <strong> Enable flash storage </strong> toggle. </p> </li> <li> <p> Select <strong> Create cluster </strong> . </p> </li> <li> <p> Select <strong> OK </strong> to confirm that you are aware of the replacement of the HTTPS TLS certificate on the node, and proceed through the browser warning. </p> </li> </ol> <h2 id="create-a-database"> Create a database </h2> <p> On the <strong> Databases </strong> screen: </p> <ol> <li> <p> Select <strong> Quick database </strong> . </p> </li> <li> <p> Verify <strong> Flash </strong> is selected for <strong> Runs on </strong> . </p> <a href="/docs/latest/images/rs/screenshots/databases/quick-db-flash-7-8-2.png" sdata-lightbox="/images/rs/screenshots/databases/quick-db-flash-7-8-2.png"> <img alt="Create a quick database with Runs on Flash selected." src="/docs/latest/images/rs/screenshots/databases/quick-db-flash-7-8-2.png"/> </a> </li> <li> <p> Enter <code> 12000 </code> for the endpoint <strong> Port </strong> number. </p> </li> <li> <p> <em> (Optional) </em> Select <strong> Full options </strong> to see available alerts. </p> </li> <li> <p> Select <strong> Create </strong> . </p> </li> </ol> <p> You now have a database with Auto Tiering enabled! </p> <h2 id="connect-to-your-database"> Connect to your database </h2> <p> After you create the database, you can connect to it and store data. See <a href="/docs/latest/operate/rs/databases/connect/test-client-connectivity/"> Test client connection </a> for connection options and examples. </p> <h2 id="next-steps"> Next steps </h2> <p> To see the true performance and scaleΒ of Auto Tiering, you must tune your I/O path and set the flash path to the mounted path of SSD or NVMe flash memory as that is what it is designed to run on. For more information, see <a href="/docs/latest/operate/rs/databases/auto-tiering/"> Auto Tiering </a> . </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/databases/auto-tiering/quickstart/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/databases/delete-database/.html
<section class="prose w-full py-12 max-w-none"> <h1> Delete database </h1> <p> To delete a database, use the <strong> Delete </strong> button located in the <strong> Danger zone </strong> section of the database's <strong> Configuration </strong> tab. </p> <p> Deleting a database requires the Account Owner role. </p> <p> Deleted databases cannot be recovered. We recommend <a href="/docs/latest/operate/rc/databases/back-up-data/"> making a backup </a> , just in case. </p> <ol> <li> <p> Sign in to the <a href="https://cloud.redis.io/"> Redis Cloud console </a> . </p> </li> <li> <p> Select the database from the list. The <strong> Configuration </strong> tab is selected by default. </p> <a href="/docs/latest/images/rc/database-details-configuration-tab-general-flexible.png" sdata-lightbox="/images/rc/database-details-configuration-tab-general-flexible.png"> <img alt="The Configuration tab of the Database details screen." src="/docs/latest/images/rc/database-details-configuration-tab-general-flexible.png"/> </a> </li> <li> <p> Scroll to the <strong> Danger zone </strong> . </p> <a href="/docs/latest/images/rc/database-details-configuration-tab-danger-flexible.png" sdata-lightbox="/images/rc/database-details-configuration-tab-danger-flexible.png"> <img alt="The Danger Zone of the Database details screen." src="/docs/latest/images/rc/database-details-configuration-tab-danger-flexible.png" width="75%"/> </a> </li> <li> <p> Select the <strong> Delete </strong> button. </p> <a href="/docs/latest/images/rc/button-danger-zone-delete.png" sdata-lightbox="/images/rc/button-danger-zone-delete.png"> <img alt="The Delete button is located in the Danger zone section of the database Configuration tab." src="/docs/latest/images/rc/button-danger-zone-delete.png"/> </a> </li> <li> <p> The <strong> Delete database </strong> confirmation dialog appears. If this database is the only one in the subscription, you can also delete the subscription at this time. </p> <ul> <li> <p> Select <strong> Delete my subscription as well </strong> to delete both the database and the subscription. </p> </li> <li> <p> Clear <strong> Delete my subscription as well </strong> to delete the database but keep the subscription. </p> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> You will continue to be charged for your subscription until you delete it, even if there are no databases in your subscription. </div> </div> <a href="/docs/latest/images/rc/database-delete-last-dialog.png" sdata-lightbox="/images/rc/database-delete-last-dialog.png"> <img alt="A different delete database confirmation dialog asks you to consider deleting the subscription as well." src="/docs/latest/images/rc/database-delete-last-dialog.png"/> </a> </li> <li> <p> To confirm your choice, use the <strong> Delete database </strong> button or the <strong> Delete both </strong> button if the delete subscription checkbox is selected. </p> <p> <a href="/docs/latest/images/rc/button-database-delete.png" sdata-lightbox="/images/rc/button-database-delete.png"> <img alt="The Delete database button is located in the Danger zone section of the database Configuration tab." src="/docs/latest/images/rc/button-database-delete.png"/> </a> <a href="/docs/latest/images/rc/button-both-delete.png" sdata-lightbox="/images/rc/button-both-delete.png"> <img alt="The Delete both button is located in the Danger zone section of the database Configuration tab." src="/docs/latest/images/rc/button-both-delete.png"/> </a> </p> </li> </ol> <p> When the operation completes, the database and its data are deleted. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/databases/delete-database/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/security/access-control/saml-sso/saml-integration-okta-org2org/.html
<section class="prose w-full py-12 max-w-none"> <h1> Okta SAML integration guide (Org2Org) </h1> <p class="text-lg -mt-5 mb-10"> This integration guide shows how to set up Okta as a SAML single sign on provider for your Redis Cloud account. </p> <p> This guide shows how to configure <a href="https://help.okta.com/en-us/Content/Topics/Security/Identity_Providers.htm"> Okta </a> as a SAML single sign-on identity provider (IdP) for your Redis Cloud account. </p> <p> This guide shows how to use the Org2Org application template. You can also use the <a href="/docs/latest/operate/rc/security/access-control/saml-sso/saml-integration-okta-generic/"> Generic </a> application template. </p> <p> To learn more about Redis Cloud support for SAML, see <a href="/docs/latest/operate/rc/security/access-control/saml-sso/"> SAML single sign-on </a> . </p> <p> Before completing this guide, you must <a href="/docs/latest/operate/rc/security/access-control/saml-sso/#verify-domain"> verify ownership of any domains </a> you want to associate with your SAML setup. </p> <h2 id="step-1-set-up-your-identity-provider"> Step 1: Set up your identity provider </h2> <h3 id="create-the-okta-saml-integration-application"> Create the Okta SAML integration application </h3> <p> Create an Okta "Org2Org" SAML integration appliction. </p> <ol> <li> <p> Sign in to the Okta admin console. </p> </li> <li> <p> From the left menu, select <strong> Applications </strong> . </p> </li> <li> <p> Select <strong> Browse App Catalog </strong> . </p> </li> <li> <p> Locate and select <strong> Okta Org2Org </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_1.png" sdata-lightbox="/images/rc/saml/okta_saml_1.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_1.png"/> </a> </li> <li> <p> Once you have found the application, click "Add". </p> <a href="/docs/latest/images/rc/saml/okta_saml_2.png" sdata-lightbox="/images/rc/saml/okta_saml_2.png"> <img alt="Data transformaiton Pipeline" src="/docs/latest/images/rc/saml/okta_saml_2.png"/> </a> </li> <li> <p> Enter this field for the <strong> Org2Org </strong> application <strong> General Settings </strong> section and select <strong> Next </strong> : </p> <ul> <li> <strong> Application label </strong> : <code> Redis Cloud </code> </li> </ul> <a href="/docs/latest/images/rc/saml/okta_saml_3.png" sdata-lightbox="/images/rc/saml/okta_saml_3.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_3.png"/> </a> </li> <li> <p> Enter the following fields in the <strong> Sign-On Options &gt; Attributes </strong> section: </p> <ul> <li> <strong> Name </strong> : <code> redisAccountMapping </code> </li> <li> <strong> Name Format </strong> : <code> Basic </code> </li> <li> <strong> Value </strong> : <code> appuser.redisAccountMapping </code> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> To ensure the role mapping will not take effect, don't skip entering <code> appuser.redisAccountMapping </code> in the <strong> Value </strong> field. </div> </div> <a href="/docs/latest/images/rc/saml/okta_saml_4.png" sdata-lightbox="/images/rc/saml/okta_saml_4.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_4.png"/> </a> </li> <li> <p> Next, select <strong> View Setup Instructions </strong> . A new browser window opens, providing the information needed to configure the IdP in Redis Cloud. </p> <a href="/docs/latest/images/rc/saml/okta_saml_5.png" sdata-lightbox="/images/rc/saml/okta_saml_5.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_5.png"/> </a> </li> <li> <p> Scroll down to section 6 in the page, and note the following information: </p> <ul> <li> <strong> IdP Issuer URI </strong> </li> <li> <strong> IdP Single Sign-On Url </strong> </li> <li> <strong> IdP Signature Certificate </strong> : Click the link and download the certificate to your hard drive </li> </ul> <a href="/docs/latest/images/rc/saml/okta_saml_6.png" sdata-lightbox="/images/rc/saml/okta_saml_6.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_6.png"/> </a> <p> Once you capture the information, close the window, return to the Okta admin console, and select <strong> Done </strong> . </p> </li> </ol> <h3 id="modify-the-application-user-profile"> Modify the application user profile </h3> <ol> <li> <p> In the left menu, select <strong> Directory &gt; Profile Editor </strong> , then select <strong> Redis Cloud User </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_7_customer.png" sdata-lightbox="/images/rc/saml/okta_saml_7_customer.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_7_customer.png"/> </a> </li> <li> <p> Select <strong> Add Attribute </strong> to add a custom attribute to the user profile and specify the Redis Cloud role. </p> <a href="/docs/latest/images/rc/saml/okta_saml_7_5_customer.png" sdata-lightbox="/images/rc/saml/okta_saml_7_5_customer.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_7_5_customer.png"/> </a> </li> <li> <p> Add this information for the new custom attribute: </p> <ul> <li> <strong> Data type </strong> : <code> string array </code> </li> <li> <strong> Display name </strong> : <code> redisAccountMapping </code> </li> <li> <strong> Variable nam </strong> : <code> redisAccountMapping </code> </li> <li> <strong> Description </strong> : <code> redisAccountMapping </code> </li> <li> <strong> Attribute required </strong> : <code> Yes </code> </li> <li> <strong> Group priority </strong> : <code> Combine values across groups </code> </li> </ul> <a href="/docs/latest/images/rc/saml/okta_saml_app_int_11.png" sdata-lightbox="/images/rc/saml/okta_saml_app_int_11.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_app_int_11.png"/> </a> </li> <li> <p> Once you add the attribute, it appears in the list of profile attributes. </p> <a href="/docs/latest/images/rc/saml/okta_saml_9.png" sdata-lightbox="/images/rc/saml/okta_saml_9.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_9.png"/> </a> </li> <li> <p> Add a Redis Cloud icon to the application because it's easier for users to identify the application. Select the pencil icon on the application logo and upload a Redis image using these steps: </p> <a href="/docs/latest/images/rc/saml/okta_saml_10_customer.png" sdata-lightbox="/images/rc/saml/okta_saml_10_customer.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_10_customer.png"/> </a> <a href="/docs/latest/images/rc/saml/okta_saml_11_customer.png" sdata-lightbox="/images/rc/saml/okta_saml_11_customer.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_11_customer.png"/> </a> </li> </ol> <h2 id="createtestuser"> Step 2: Create a group and assign the application </h2> <p> Now that our SAML IdP is configured, create an Okta group and assign the Redis Cloud application. </p> <h3 id="create-the-group"> Create the group </h3> <ol> <li> <p> In the left menu, select <strong> Directory &gt; Groups </strong> , then select <strong> Add group </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_1.png" sdata-lightbox="/images/rc/saml/okta_saml_group_1.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_1.png"/> </a> </li> <li> <p> Enter <strong> Name </strong> and <strong> Description </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_2.png" sdata-lightbox="/images/rc/saml/okta_saml_group_2.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_2.png"/> </a> <a href="/docs/latest/images/rc/saml/okta_saml_group_3.png" sdata-lightbox="/images/rc/saml/okta_saml_group_3.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_3.png"/> </a> </li> </ol> <h3 id="assign-users-to-the-group"> Assign users to the group </h3> <ol> <li> <p> Select the group, then select <strong> Assign people </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_4.png" sdata-lightbox="/images/rc/saml/okta_saml_group_4.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_4.png"/> </a> </li> <li> <p> For each user you want to add to the group, highlight the user in the table and select <strong> + </strong> . You can also add all users by selecting <strong> Add all </strong> . After you add all the users to your group, select <strong> Save </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_5.png" sdata-lightbox="/images/rc/saml/okta_saml_group_5.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_5.png"/> </a> </li> </ol> <h3 id="assign-application-to-the-group"> Assign application to the group </h3> <p> Now that your group is populated with its users, assign the SAML integration application to your group. </p> <ol> <li> <p> From the menu, select <strong> Applications &gt; Applications &gt; Redis Cloud </strong> . Then, select <strong> Assign to groups </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_6.png" sdata-lightbox="/images/rc/saml/okta_saml_group_6.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_6.png"/> </a> </li> <li> <p> In the <strong> Redis Cloud User Group </strong> , select <strong> Assign </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_7.png" sdata-lightbox="/images/rc/saml/okta_saml_group_7.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_7.png"/> </a> </li> <li> <p> Now, define the Redis account mapping string default for this group and select <strong> Save and go back </strong> . The key-value pair consists of the lowercase role name (owner, member, manager, billing_admin, or viewer) and your <strong> Redis Cloud Account ID </strong> found in the <a href="/docs/latest/operate/rc/accounts/account-settings/"> account settings </a> . Select <strong> "Done" </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_8.png" sdata-lightbox="/images/rc/saml/okta_saml_group_8.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_8.png"/> </a> <p> The mapping field is now defined as a default for each member of the group. </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_9.png" sdata-lightbox="/images/rc/saml/okta_saml_group_9.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_9.png"/> </a> </li> </ol> <h3 id="editing-the-mapping-field-for-the-group"> Editing the mapping field for the group </h3> <p> To modify the Redis mapping field, select the pencil icon of the Redis Cloud group in the "Redis Cloud" application screen. </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_10.png" sdata-lightbox="/images/rc/saml/okta_saml_group_10.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_10.png"/> </a> <p> You can modify the mapping field for the whole group on the edit screen that appears. </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_11.png" sdata-lightbox="/images/rc/saml/okta_saml_group_11.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_11.png"/> </a> <h3 id="editing-the-mapping-field-for-a-specific-user"> Editing the mapping field for a specific user </h3> <p> To override the Redis mapping field at an individual user level, select the <strong> People </strong> menu, then select the pencil icon of the person whos field you want to modify. </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_12.png" sdata-lightbox="/images/rc/saml/okta_saml_group_12.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_12.png"/> </a> <p> Set the user's <strong> Assignment master </strong> to <code> Administrator </code> to enable group policy overrides. Select <strong> Save </strong> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_13.png" sdata-lightbox="/images/rc/saml/okta_saml_group_13.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_13.png"/> </a> <p> The user's <strong> Type </strong> is set to <code> Individual </code> . </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_14.png" sdata-lightbox="/images/rc/saml/okta_saml_group_14.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_14.png"/> </a> <p> On the screen that appears, select the pencil icon of the user to modify the Redis mapping field. </p> <a href="/docs/latest/images/rc/saml/okta_saml_group_15.png" sdata-lightbox="/images/rc/saml/okta_saml_group_15.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_15.png"/> </a> <a href="/docs/latest/images/rc/saml/okta_saml_group_16.png" sdata-lightbox="/images/rc/saml/okta_saml_group_16.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/okta_saml_group_16.png"/> </a> <h2 id="step-3-configure-saml-support-in-redis-cloud"> Step 3: Configure SAML support in Redis Cloud </h2> <p> Now that you have a test IdP server and your user group ready, configure support for SAML in Redis Cloud. </p> <h3 id="sign-in-to-redis-cloud"> Sign in to Redis Cloud </h3> <p> Sign in to your account on the <a href="https://cloud.redis.io/#/login"> Redis Cloud console </a> . </p> <h3 id="activate-saml-in-access-management"> Activate SAML in access management </h3> <p> To activate SAML, you must have a local user (or social sign-on user) with the <strong> owner </strong> role. If you have the correct permissions, the <strong> Single Sign-On </strong> tab is enabled. </p> <ol> <li> <p> Add the information you saved previously in the <strong> setup </strong> form (step 1), including: </p> <ul> <li> <strong> Issuer (IdP Entity ID) </strong> : IdP Issuer URI </li> <li> <strong> IdP server URL </strong> : IdP Single Sign-On Url </li> <li> <strong> Assertion signing certificate </strong> : Drag and drop the file you downloaded to disk in the form text area. </li> </ul> <a href="/docs/latest/images/rc/saml/sm_saml_1.png" sdata-lightbox="/images/rc/saml/sm_saml_1.png"> <img alt="Use the Okta admin console to locate the Org2Org application template." src="/docs/latest/images/rc/saml/sm_saml_1.png"/> </a> </li> <li> <p> Select <strong> Enable </strong> and wait a few seconds for the status to change. Then, download the service provider (SP) metadata. Save the file to your local hard disk. </p> <a href="/docs/latest/images/rc/saml/sm_saml_3.png" sdata-lightbox="/images/rc/saml/sm_saml_3.png"> <img src="/docs/latest/images/rc/saml/sm_saml_3.png"/> </a> </li> <li> <p> Open the file in any text editor. Save the following text from the metadata: </p> <ul> <li> <strong> EntityID </strong> : Unique name of the service provider (SP) </li> </ul> <a href="/docs/latest/images/rc/saml/sm_saml_4.png" sdata-lightbox="/images/rc/saml/sm_saml_4.png"> <img src="/docs/latest/images/rc/saml/sm_saml_4.png"/> </a> <ul> <li> <strong> Location </strong> : Location of the assertion consumer service </li> </ul> <a href="/docs/latest/images/rc/saml/sm_saml_5.png" sdata-lightbox="/images/rc/saml/sm_saml_5.png"> <img src="/docs/latest/images/rc/saml/sm_saml_5.png"/> </a> </li> <li> <p> Return to Okta, select <strong> Applications &gt; Redis Cloud &gt; General </strong> , then select <strong> Edit </strong> . </p> <a href="/docs/latest/images/rc/saml/sm_saml_6.png" sdata-lightbox="/images/rc/saml/sm_saml_6.png"> <img src="/docs/latest/images/rc/saml/sm_saml_6.png"/> </a> </li> <li> <p> Update this information in <strong> Advanced Sign-on Settings </strong> . </p> <ul> <li> <strong> Hub ACS URL </strong> : Use the information that you copied for <strong> Location </strong> . </li> <li> <strong> Audience URI </strong> : Use the information that you copied for <strong> EntityID </strong> . </li> </ul> <a href="/docs/latest/images/rc/saml/sm_saml_7.png" sdata-lightbox="/images/rc/saml/sm_saml_7.png"> <img src="/docs/latest/images/rc/saml/sm_saml_7.png"/> </a> </li> </ol> <p> Select <strong> Save </strong> . </p> <h3 id="idp-initiated-sso"> IdP-initiated SSO </h3> <p> To use IdP-initiated SSO with identity providers, set the RelayState parameter to URL <code> https://cloud.redis.io/#/login/?idpId=&lt;ID&gt; </code> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Replace <code> &lt;ID&gt; </code> so it matches the AssertionConsumerService Location URL ID (the content after the last forward slash "/"). To learn more about configuring service provider applications, see your identity provider's documentation. </div> </div> <h3 id="return-to-redis-cloud-console"> Return to Redis Cloud console </h3> <ol> <li> <p> Return to Redis Cloud console and select <strong> Activate </strong> . </p> <a href="/docs/latest/images/rc/saml/sm_saml_8.png" sdata-lightbox="/images/rc/saml/sm_saml_8.png"> <img src="/docs/latest/images/rc/saml/sm_saml_8.png"/> </a> <p> A popup appears, explaining that, to test the SAML connection, you need to log in with Okta credentials of the user defined in the Redis Cloud group. This user is part of the group to which you assigned the Redis Cloud application. </p> <a href="/docs/latest/images/rc/saml/sm_saml_9.png" sdata-lightbox="/images/rc/saml/sm_saml_9.png"> <img src="/docs/latest/images/rc/saml/sm_saml_9.png"/> </a> </li> <li> <p> The Okta log-in screen appears. Enter the credentials and select <strong> Sign In </strong> . </p> <a href="/docs/latest/images/rc/saml/sm_saml_10.png" sdata-lightbox="/images/rc/saml/sm_saml_10.png"> <img src="/docs/latest/images/rc/saml/sm_saml_10.png"/> </a> </li> <li> <p> If the test succeeds, the next screen appears. Your local account is now considered a SAML account. Going forward, to log in to Redis Cloud console, select <strong> Sign in with SSO </strong> . </p> <a href="/docs/latest/images/rc/saml/sm_saml_11.png" sdata-lightbox="/images/rc/saml/sm_saml_11.png"> <img src="/docs/latest/images/rc/saml/sm_saml_11.png"/> </a> </li> <li> <p> Enter your SAML email and select <strong> Login </strong> </p> <a href="/docs/latest/images/rc/saml/sm_saml_12.png" sdata-lightbox="/images/rc/saml/sm_saml_12.png"> <img src="/docs/latest/images/rc/saml/sm_saml_12.png"/> </a> </li> </ol> <p> You have successfully configured SAML as an identity provider. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/security/access-control/saml-sso/saml-integration-okta-org2org/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/hgetall/.html
<section class="prose w-full py-12"> <h1 class="command-name"> HGETALL </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">HGETALL key</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 2.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the size of the hash. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @read </code> <span class="mr-1 last:hidden"> , </span> <code> @hash </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Returns all fields and values of the hash stored at <code> key </code> . In the returned value, every field name is followed by its value, so the length of the reply is twice the size of the hash. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; HSET myhash field1 "Hello" (integer) 1 redis&gt; HSET myhash field2 "World" (integer) 1 redis&gt; HGETALL myhash 1) "field1" 2) "Hello" 3) "field2" 4) "World" </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="resp2-reply"> RESP2 Reply </h2> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : a list of fields and their values stored in the hash, or an empty list when key does not exist. <h2 id="resp3-reply"> RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#maps"> Map reply </a> : a map of fields and their values stored in the hash, or an empty list when key does not exist. <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/hgetall/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/tdigest.byrevrank/.html
<section class="prose w-full py-12"> <h1 class="command-name"> TDIGEST.BYREVRANK </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">TDIGEST.BYREVRANK key reverse_rank [reverse_rank ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 2.4.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the number of reverse ranks specified. </dd> </dl> <p> Returns, for each input reverse rank, an estimation of the value (floating-point) with that reverse rank. </p> <p> Multiple estimations can be retrieved in a signle call. </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> is key name for an existing t-digest sketch. </details> <details open=""> <summary> <code> revrank </code> </summary> <p> Reverse rank, for which the value should be retrieved. </p> <p> 0 is the reverse rank of the value of the largest observation. </p> <p> <em> n </em> -1 is the reverse rank of the value of the smallest observation; <em> n </em> denotes the number of observations added to the sketch. </p> </details> <h2 id="return-value"> Return value </h2> <p> <a href="/docs/latest/develop/reference/protocol-spec/#arrays"> Array reply </a> - an array of floating-points populated with value_1, value_2, ..., value_R: </p> <ul> <li> Return an accurate result when <code> revrank </code> is 0 (the value of the largest observation) </li> <li> Return an accurate result when <code> revrank </code> is <em> n </em> -1 (the value of the smallest observation), where <em> n </em> denotes the number of observations added to the sketch. </li> <li> Return '-inf' when <code> revrank </code> is equal to <em> n </em> or larger than <em> n </em> </li> </ul> <p> All values are 'nan' if the sketch is empty. </p> <h2 id="examples"> Examples </h2> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; TDIGEST.CREATE t COMPRESSION <span class="m">1000</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; TDIGEST.ADD t <span class="m">1</span> <span class="m">2</span> <span class="m">2</span> <span class="m">3</span> <span class="m">3</span> <span class="m">3</span> <span class="m">4</span> <span class="m">4</span> <span class="m">4</span> <span class="m">4</span> <span class="m">5</span> <span class="m">5</span> <span class="m">5</span> <span class="m">5</span> <span class="m">5</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; TDIGEST.BYREVRANK t <span class="m">0</span> <span class="m">1</span> <span class="m">2</span> <span class="m">3</span> <span class="m">4</span> <span class="m">5</span> <span class="m">6</span> <span class="m">7</span> <span class="m">8</span> <span class="m">9</span> <span class="m">10</span> <span class="m">11</span> <span class="m">12</span> <span class="m">13</span> <span class="m">14</span> <span class="m">15</span> </span></span><span class="line"><span class="cl"> 1<span class="o">)</span> <span class="s2">"5"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"5"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"5"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"5"</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="s2">"5"</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"4"</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> <span class="s2">"4"</span> </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="s2">"4"</span> </span></span><span class="line"><span class="cl"> 9<span class="o">)</span> <span class="s2">"4"</span> </span></span><span class="line"><span class="cl">10<span class="o">)</span> <span class="s2">"3"</span> </span></span><span class="line"><span class="cl">11<span class="o">)</span> <span class="s2">"3"</span> </span></span><span class="line"><span class="cl">12<span class="o">)</span> <span class="s2">"3"</span> </span></span><span class="line"><span class="cl">13<span class="o">)</span> <span class="s2">"2"</span> </span></span><span class="line"><span class="cl">14<span class="o">)</span> <span class="s2">"2"</span> </span></span><span class="line"><span class="cl">15<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl">16<span class="o">)</span> <span class="s2">"-inf"</span></span></span></code></pre> </div> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/tdigest.byrevrank/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/suffix/.html
<section class="prose w-full py-12 max-w-none"> <h1> Suffix object </h1> <p class="text-lg -mt-5 mb-10"> An object that represents a DNS suffix </p> <p> An API object that represents a DNS suffix in the cluster. </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> default </td> <td> boolean </td> <td> Suffix is the default suffix for the cluster (read-only) </td> </tr> <tr> <td> internal </td> <td> boolean </td> <td> Does the suffix point to internal IP addresses (read-only) </td> </tr> <tr> <td> mdns </td> <td> boolean </td> <td> Support for multicast DNS (read-only) </td> </tr> <tr> <td> name </td> <td> string </td> <td> Unique suffix name that represents its zone (read-only) </td> </tr> <tr> <td> slaves </td> <td> array of strings </td> <td> Frontend DNS servers to be updated by this suffix </td> </tr> <tr> <td> use_aaaa_ns </td> <td> boolean </td> <td> Suffix uses AAAA NS entries (read-only) </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/suffix/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/kubernetes/upgrade/openshift-cli/.html
<section class="prose w-full py-12 max-w-none"> <h1> Upgrade Redis Enterprise with OpenShift CLI </h1> <p class="text-lg -mt-5 mb-10"> This task describes how to upgrade a Redis Enterprise cluster via OpenShift CLI. </p> <p> Redis implements rolling updates for software upgrades in Kubernetes deployments. The upgrade process includes updating three components: </p> <ol> <li> <a href="#upgrade-the-operator"> Upgrade the Redis Enterprise operator </a> </li> <li> <a href="#upgrade-the-redisenterprisecluster-rec"> Upgrade the Redis Enterprise cluster (REC) </a> </li> <li> <a href="#upgrade-databases"> Upgrade Redis Enterprise databases (REDB) </a> </li> </ol> <h2 id="before-upgrading"> Before upgrading </h2> <ol> <li> <p> Check <a href="/docs/latest/operate/kubernetes/reference/supported_k8s_distributions/"> Supported Kubernetes distributions </a> to make sure your Kubernetes distribution is supported. </p> </li> <li> <p> Use <code> oc get rec </code> and verify the <code> LICENSE STATE </code> is valid on your REC before you start the upgrade process. </p> </li> <li> <p> Verify you are upgrading from Redis Enterprise operator version 6.2.10-45 or later. If you are not, you must upgrade to 6.2.10-45 before upgrading to versions 6.2.18 or later. </p> </li> <li> <p> When upgrading existing clusters running on RHEL7-based images, make sure to select a RHEL7-based image for the new version. See <a href="/docs/latest/operate/kubernetes/release-notes/"> release notes </a> for more info. </p> </li> <li> <p> If you want to migrate from RHEL7-based images to RHEL8-based images, you'll need to upgrade to version 7.2.4-2 with a RHEL7-based image, then you'll be able to migrate to a RHEL8-based image when upgrading to 7.2.4- <strong> TBD </strong> . </p> </li> </ol> <h2 id="upgrade-the-operator"> Upgrade the operator </h2> <h3 id="download-the-bundle"> Download the bundle </h3> <p> Make sure you pull the correct version of the bundle. You can find the version tags by checking the <a href="https://github.com/RedisLabs/redis-enterprise-k8s-docs/releases"> operator releases on GitHub </a> or by <a href="https://docs.github.com/en/rest/reference/repos#releases"> using the GitHub API </a> . </p> <p> For OpenShift environments, the name of the bundle is <code> openshift.bundle.yaml </code> , and so the <code> curl </code> command to run is: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">curl --silent -O https://raw.githubusercontent.com/RedisLabs/redis-enterprise-k8s-docs/<span class="nv">$VERSION</span>/openshift.bundle.yaml </span></span></code></pre> </div> <p> If you need a different release, replace <code> VERSION </code> in the above with a specific release tag. </p> <h3 id="apply-the-bundle"> Apply the bundle </h3> <p> Apply the bundle to deploy the new operator binary. This will also apply any changes in the new release to custom resource definitions, roles, role binding, or operator service accounts. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> If you are not pulling images from Docker Hub, update the operator image spec to point to your private repository. If you have made changes to the role, role binding, RBAC, or custom resource definition (CRD) in the previous version, merge them with the updated declarations in the new version files. </div> </div> <p> If you are using OpenShift, run this instead: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc apply -f openshift.bundle.yaml </span></span></code></pre> </div> <p> After running this command, you should see a result similar to this: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">role.rbac.authorization.k8s.io/redis-enterprise-operator configured </span></span><span class="line"><span class="cl">serviceaccount/redis-enterprise-operator configured </span></span><span class="line"><span class="cl">rolebinding.rbac.authorization.k8s.io/redis-enterprise-operator configured </span></span><span class="line"><span class="cl">customresourcedefinition.apiextensions.k8s.io/redisenterpriseclusters.app.redislabs.com configured </span></span><span class="line"><span class="cl">customresourcedefinition.apiextensions.k8s.io/redisenterprisedatabases.app.redislabs.com configured </span></span><span class="line"><span class="cl">deployment.apps/redis-enterprise-operator configured </span></span></code></pre> </div> <h3 id="reapply-webhook"> Reapply the admission controller webhook </h3> <p> If you have the admission controller enabled, you need to manually reapply the <code> ValidatingWebhookConfiguration </code> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> <p> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/"> Versions 6.4.2 and later </a> uses a new <code> ValidatingWebhookConfiguration </code> resource to replace <code> redb-admission </code> . To use newer releases, delete the old webhook resource and apply the new file. </p> <ol> <li> <p> Delete the existing <code> ValidatingWebhookConfiguration </code> on the Kubernetes cluster (named <code> redb-admission </code> ). </p> <pre><code> ```sh kubectl delete ValidatingWebhookConfiguration redb-admission ``` </code></pre> </li> <li> <p> Apply the resource from the new file. </p> <pre><code> ```sh kubectl apply -f deploy/admission/webhook.yaml ``` </code></pre> </li> </ol> </div> </div> <ol> <li> <p> Verify the <code> admission-tls </code> secret exists. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl get secret admission-tls </span></span></code></pre> </div> <p> The output should look similar to </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">NAME TYPE DATA AGE </span></span><span class="line"><span class="cl">admission-tls Opaque <span class="m">2</span> 2m43s </span></span></code></pre> </div> </li> <li> <p> Save the certificate to a local environment variable. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl"><span class="nv">CERT</span><span class="o">=</span><span class="sb">`</span>kubectl get secret admission-tls -o <span class="nv">jsonpath</span><span class="o">=</span><span class="s1">'{.data.cert}'</span><span class="sb">`</span> </span></span></code></pre> </div> </li> <li> <p> Create a Kubernetes validating webhook, replacing <code> &lt;namespace&gt; </code> with the namespace where the REC was installed. </p> <p> The <code> webhook.yaml </code> template can be found in <a href="https://github.com/RedisLabs/redis-enterprise-k8s-docs/tree/master/admission"> redis-enterprise-k8s-docs/admission </a> </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">sed <span class="s1">'s/OPERATOR_NAMESPACE/&lt;namespace&gt;/g'</span> webhook.yaml <span class="p">|</span> kubectl create -f - </span></span></code></pre> </div> </li> <li> <p> Create a patch file for the Kubernetes validating webhook. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">cat &gt; modified-webhook.yaml <span class="s">&lt;&lt;EOF </span></span></span><span class="line"><span class="cl"><span class="s">webhooks: </span></span></span><span class="line"><span class="cl"><span class="s">- name: redisenterprise.admission.redislabs </span></span></span><span class="line"><span class="cl"><span class="s"> clientConfig: </span></span></span><span class="line"><span class="cl"><span class="s"> caBundle: $CERT </span></span></span><span class="line"><span class="cl"><span class="s">EOF</span> </span></span></code></pre> </div> </li> <li> <p> Patch the webhook with the certificate. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">kubectl patch ValidatingWebhookConfiguration <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> redis-enterprise-admission --patch <span class="s2">"</span><span class="k">$(</span>cat modified-webhook.yaml<span class="k">)</span><span class="s2">"</span> </span></span></code></pre> </div> </li> </ol> <h3 id="verify-the-operator-is-running"> Verify the operator is running </h3> <p> You can check your deployment to verify the operator is running in your namespace. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc get deployment/redis-enterprise-operator </span></span></code></pre> </div> <p> You should see a result similar to this: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">NAME READY UP-TO-DATE AVAILABLE AGE </span></span><span class="line"><span class="cl">redis-enterprise-operator 1/1 <span class="m">1</span> <span class="m">1</span> 0m36s </span></span></code></pre> </div> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> We recommend upgrading the REC as soon as possible after updating the operator. After the operator upgrade completes, the operator suspends the management of the REC and its associated REDBs, until the REC upgrade completes. </div> </div> <h3 id="reapply-the-scc"> Reapply the SCC </h3> <p> If you are using OpenShift, you will also need to manually reapply the <a href="https://docs.openshift.com/container-platform/4.8/authentication/managing-security-context-constraints.html"> security context constraints </a> file ( <a href="/docs/latest/operate/kubernetes/deployment/openshift/openshift-cli/#deploy-the-operator"> <code> scc.yaml </code> </a> ) and bind it to your service account. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc apply -f openshift/scc.yaml </span></span></code></pre> </div> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc adm policy add-scc-to-user redis-enterprise-scc-v2 <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> system:serviceaccount:&lt;my-project&gt;:&lt;rec-name&gt; </span></span></code></pre> </div> <p> If you are upgrading from operator version 6.4.2-6 or before, see the <a href="#after-upgrading"> "after upgrading" </a> section to delete the old SCC and role binding after all clusters are running 6.4.2-6 or later. </p> <h2 id="upgrade-the-redisenterprisecluster-rec"> Upgrade the RedisEnterpriseCluster (REC) </h2> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> <p> Verify your license is valid before upgrading. Invalid licenses will cause the upgrade to fail. </p> <p> Use <code> oc get rec </code> and verify the <code> LICENSE STATE </code> is valid on your REC before you start the upgrade process. </p> </div> </div> <p> The Redis Enterprise cluster (REC) can be updated automatically or manually. To trigger automatic upgrade of the REC after the operator upgrade completes, specify <code> autoUpgradeRedisEnterprise: true </code> in your REC spec. If you don't have automatic upgrade enabled, follow the below steps for the manual upgrade. </p> <p> Before beginning the upgrade of the Redis Enterprise cluster, check the K8s operator release notes to find the Redis Enterprise image tag. For example, in Redis Enterprise K8s operator release <a href="https://github.com/RedisLabs/redis-enterprise-k8s-docs/releases/tag/v6.0.12-5"> 6.0.12-5 </a> , the <code> Images </code> section shows the Redis Enterprise tag is <code> 6.0.12-57 </code> . </p> <p> After the operator upgrade is complete, you can upgrade Redis Enterprise cluster (REC). </p> <h3 id="edit-redisenterpriseimagespec-in-the-rec-spec"> Edit <code> redisEnterpriseImageSpec </code> in the REC spec </h3> <ol> <li> <p> Edit the REC custom resource YAML file. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc edit rec &lt;your-rec.yaml&gt; </span></span></code></pre> </div> </li> <li> <p> Replace the <code> versionTag: </code> declaration under <code> redisEnterpriseImageSpec </code> with the new version tag. </p> <div class="highlight"> <pre class="chroma"><code class="language-YAML" data-lang="YAML"><span class="line"><span class="cl"><span class="nt">spec</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">redisEnterpriseImageSpec</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">imagePullPolicy</span><span class="p">:</span><span class="w"> </span><span class="l">IfNotPresent</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">repository</span><span class="p">:</span><span class="w"> </span><span class="l">redislabs/redis</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">versionTag</span><span class="p">:</span><span class="w"> </span><span class="l">&lt;new-version-tag&gt;</span><span class="w"> </span></span></span></code></pre> </div> </li> <li> <p> Save the changes to apply. </p> </li> </ol> <h3 id="reapply-roles-and-role-bindings"> Reapply roles and role bindings </h3> <p> If your operator is monitoring multiple namespaces, you'll need to <a href="/docs/latest/operate/kubernetes/re-clusters/multi-namespace/#create-role-and-role-binding-for-managed-namespaces"> reapply your role and role bindings </a> for each managed namespace. See <a href="/docs/latest/operate/kubernetes/re-clusters/multi-namespace/"> Manage databases in multiple namespaces </a> for more details. </p> <h3 id="monitor-the-upgrade"> Monitor the upgrade </h3> <p> You can view the state of the REC with <code> oc get rec </code> . </p> <p> During the upgrade, the state should be <code> Upgrade </code> . When the upgrade is complete and the cluster is ready to use, the state will change to <code> Running </code> . If the state is <code> InvalidUpgrade </code> , there is an error (usually relating to configuration) in the upgrade. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ oc get rec </span></span><span class="line"><span class="cl">NAME NODES VERSION STATE SPEC STATUS LICENSE STATE SHARDS LIMIT LICENSE EXPIRATION DATE AGE </span></span><span class="line"><span class="cl">rec <span class="m">3</span> 6.2.10-107 Upgrade Valid Valid <span class="m">4</span> 2022-07-16T13:59:00Z 92m </span></span></code></pre> </div> <p> To see the status of the current rolling upgrade, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc rollout status sts &lt;REC_name&gt; </span></span></code></pre> </div> <h2 id="after-upgrading"> After upgrading </h2> <p> For OpenShift users, operator version 6.4.2-6 introduced a new SCC ( <code> redis-enterprise-scc-v2 </code> ). If any of your OpenShift RedisEnterpriseClusters are running versions earlier than 6.2.4-6, you need to keep both the new and old versions of the SCC. </p> <p> If all of your clusters have been upgraded to operator version 6.4.2-6 or later, you can delete the old version of the SCC ( <code> redis-enterprise-scc </code> ) and remove the binding to your service account. </p> <ol> <li> <p> Delete the old version of the SCC </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc delete scc redis-enterprise-scc </span></span></code></pre> </div> <p> The output should look similar to the following: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">securitycontextconstraints.security.openshift.io <span class="s2">"redis-enterprise-scc"</span> deleted </span></span></code></pre> </div> </li> <li> <p> Remove the binding to your service account. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">oc adm policy remove-scc-from-user redis-enterprise-scc system:serviceaccount:&lt;my-project&gt;:&lt;rec-name&gt; </span></span></code></pre> </div> </li> </ol> <h2 id="upgrade-databases"> Upgrade databases </h2> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> In version 7.2.4, old module versions and manually uploaded modules are not persisted. If databases are not upgraded after cluster upgrade, and require cluster recovery afterwards, you'll need to contact Redis support. This issue will be fixed in the next maintenance release by moving the stored location of the modules. </div> </div> <p> After the cluster is upgraded, you can upgrade your databases. The process for upgrading databases is the same for both Kubernetes and non-Kubernetes deployments. For more details on how to <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/upgrade-database/"> upgrade a database </a> , see the <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/"> Upgrade an existing Redis Enterprise Software deployment </a> documentation. </p> <p> Note that if your cluster <a href="/docs/latest/operate/kubernetes/reference/redis_enterprise_cluster_api/#redisupgradepolicy"> <code> redisUpgradePolicy </code> </a> or your database <a href="/docs/latest/operate/kubernetes/reference/redis_enterprise_database_api/#redisversion"> <code> redisVersion </code> </a> are set to <code> major </code> , you won't be able to upgrade those databases to minor versions. See <a href="/docs/latest/operate/rs/installing-upgrading/upgrading/#redis-upgrade-policy"> Redis upgrade policy </a> for more details. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/kubernetes/upgrade/openshift-cli/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/data-pipelines/transform-examples/redis-set-example/.html
<section class="prose w-full py-12 max-w-none"> <h1> Write to a Redis set </h1> <p> In the example below, data is captured from the source table named <code> invoice </code> and is written to a Redis set. The <code> connection </code> is an optional parameter that refers to the corresponding connection name defined in <code> config.yaml </code> . When you specify the <code> data_type </code> parameter for the job, it overrides the system-wide setting <code> target_data_type </code> defined in <code> config.yaml </code> . </p> <p> When writing to a set, you must supply an extra argument, <code> member </code> , which specifies the field that will be written. In this case, the result will be a Redis set with key names based on the key expression (for example, <code> invoices:Germany </code> , <code> invoices:USA </code> ) and with an expiration of 100 seconds. If you don't supply an <code> expire </code> parameter, the keys will never expire. </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">source</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">server_name</span><span class="p">:</span><span class="w"> </span><span class="l">chinook</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">schema</span><span class="p">:</span><span class="w"> </span><span class="l">public</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">table</span><span class="p">:</span><span class="w"> </span><span class="l">invoice</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">output</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span>- <span class="nt">uses</span><span class="p">:</span><span class="w"> </span><span class="l">redis.write</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">with</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">connection</span><span class="p">:</span><span class="w"> </span><span class="l">target</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">data_type</span><span class="p">:</span><span class="w"> </span><span class="l">set</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">key</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">expression</span><span class="p">:</span><span class="w"> </span><span class="l">concat(['invoices:', BillingCountry])</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">language</span><span class="p">:</span><span class="w"> </span><span class="l">jmespath</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">args</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">member</span><span class="p">:</span><span class="w"> </span><span class="l">InvoiceId</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">expire</span><span class="p">:</span><span class="w"> </span><span class="m">100</span><span class="w"> </span></span></span></code></pre> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/data-pipelines/transform-examples/redis-set-example/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/reference/data-transformation/map/.html
<section class="prose w-full py-12 max-w-none"> <h1> map </h1> <p class="text-lg -mt-5 mb-10"> Map a record into a new output based on expressions </p> <p> Map a record into a new output based on expressions </p> <p> <strong> Properties </strong> </p> <table> <thead> <tr> <th> Name </th> <th> Type </th> <th> Description </th> <th> Required </th> </tr> </thead> <tbody> <tr> <td> <a href="#expression"> <strong> expression </strong> </a> </td> <td> <code> object </code> , <code> string </code> </td> <td> Expression <br/> </td> <td> yes </td> </tr> <tr> <td> <strong> language </strong> </td> <td> <code> string </code> </td> <td> Language <br/> Enum: <code> "jmespath" </code> , <code> "sql" </code> <br/> </td> <td> yes </td> </tr> </tbody> </table> <p> <strong> Additional Properties: </strong> not allowed </p> <p> <strong> Example </strong> </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">source</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">server_name</span><span class="p">:</span><span class="w"> </span><span class="l">redislabs</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">schema</span><span class="p">:</span><span class="w"> </span><span class="l">dbo</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">table</span><span class="p">:</span><span class="w"> </span><span class="l">emp</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">transform</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span>- <span class="nt">uses</span><span class="p">:</span><span class="w"> </span><span class="l">map</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">with</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">expression</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">first_name</span><span class="p">:</span><span class="w"> </span><span class="l">first_name</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">last_name</span><span class="p">:</span><span class="w"> </span><span class="l">last_name</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">greeting</span><span class="p">:</span><span class="w"> </span><span class="p">&gt;-</span><span class="sd"> </span></span></span><span class="line"><span class="cl"><span class="sd"> 'Hello ' || CASE WHEN gender = 'F' THEN 'Ms.' WHEN gender = 'M' THEN 'Mr.' </span></span></span><span class="line"><span class="cl"><span class="sd"> ELSE 'N/A' END || ' ' || full_name</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">country</span><span class="p">:</span><span class="w"> </span><span class="l">country</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">full_name</span><span class="p">:</span><span class="w"> </span><span class="l">full_name</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">language</span><span class="p">:</span><span class="w"> </span><span class="l">sql</span><span class="w"> </span></span></span></code></pre> </div> <p> <strong> Example </strong> </p> <div class="highlight"> <pre class="chroma"><code class="language-yaml" data-lang="yaml"><span class="line"><span class="cl"><span class="nt">source</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">table</span><span class="p">:</span><span class="w"> </span><span class="l">customer</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"></span><span class="nt">transform</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span>- <span class="nt">uses</span><span class="p">:</span><span class="w"> </span><span class="l">map</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">with</span><span class="p">:</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">expression</span><span class="p">:</span><span class="w"> </span><span class="p">|</span><span class="sd"> </span></span></span><span class="line"><span class="cl"><span class="sd"> { </span></span></span><span class="line"><span class="cl"><span class="sd"> "CustomerId": customer_id, </span></span></span><span class="line"><span class="cl"><span class="sd"> "FirstName": first_name, </span></span></span><span class="line"><span class="cl"><span class="sd"> "LastName": last_name, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Company": company, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Location": </span></span></span><span class="line"><span class="cl"><span class="sd"> { </span></span></span><span class="line"><span class="cl"><span class="sd"> "Street": address, </span></span></span><span class="line"><span class="cl"><span class="sd"> "City": city, </span></span></span><span class="line"><span class="cl"><span class="sd"> "State": state, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Country": country, </span></span></span><span class="line"><span class="cl"><span class="sd"> "PostalCode": postal_code </span></span></span><span class="line"><span class="cl"><span class="sd"> }, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Phone": phone, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Fax": fax, </span></span></span><span class="line"><span class="cl"><span class="sd"> "Email": email </span></span></span><span class="line"><span class="cl"><span class="sd"> }</span><span class="w"> </span></span></span><span class="line"><span class="cl"><span class="w"> </span><span class="nt">language</span><span class="p">:</span><span class="w"> </span><span class="l">jmespath</span><span class="w"> </span></span></span></code></pre> </div> <p> <a name="expression"> </a> </p> <h2 id="expression-object"> expression: object </h2> <p> Expression </p> <p> <strong> No properties. </strong> </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/reference/data-transformation/map/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/develop/clients/dotnet/.html
<section class="prose w-full py-12 max-w-none"> <h1> NRedisStack guide (C#/.NET) </h1> <p class="text-lg -mt-5 mb-10"> Connect your .NET application to a Redis database </p> <p> <a href="https://github.com/redis/NRedisStack"> NRedisStack </a> is the .NET client for Redis. The sections below explain how to install <code> NRedisStack </code> and connect your application to a Redis database. </p> <p> <code> NRedisStack </code> requires a running Redis or <a href="/docs/latest/operate/oss_and_stack/install/install-stack/"> Redis Stack </a> server. See <a href="/docs/latest/operate/oss_and_stack/install/"> Getting started </a> for Redis installation instructions. </p> <p> You can also access Redis with an object-mapping client interface. See <a href="/docs/latest/integrate/redisom-for-net/"> Redis OM for .NET </a> for more information. </p> <h2 id="install"> Install </h2> <p> Using the <code> dotnet </code> CLI, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">dotnet add package NRedisStack </span></span></code></pre> </div> <h2 id="connect-and-test"> Connect and test </h2> <p> Connect to localhost on port 6379. </p> <div class="highlight"> <pre class="chroma"><code class="language-csharp" data-lang="csharp"><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">NRedisStack</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">NRedisStack.RedisStackCommands</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">StackExchange.Redis</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="c1">//...</span> </span></span><span class="line"><span class="cl"><span class="n">ConnectionMultiplexer</span> <span class="n">redis</span> <span class="p">=</span> <span class="n">ConnectionMultiplexer</span><span class="p">.</span><span class="n">Connect</span><span class="p">(</span><span class="s">"localhost"</span><span class="p">);</span> </span></span><span class="line"><span class="cl"><span class="n">IDatabase</span> <span class="n">db</span> <span class="p">=</span> <span class="n">redis</span><span class="p">.</span><span class="n">GetDatabase</span><span class="p">();</span> </span></span></code></pre> </div> <p> You can test the connection by storing and retrieving a simple string. </p> <div class="highlight"> <pre class="chroma"><code class="language-csharp" data-lang="csharp"><span class="line"><span class="cl"><span class="n">db</span><span class="p">.</span><span class="n">StringSet</span><span class="p">(</span><span class="s">"foo"</span><span class="p">,</span> <span class="s">"bar"</span><span class="p">);</span> </span></span><span class="line"><span class="cl"><span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="n">db</span><span class="p">.</span><span class="n">StringGet</span><span class="p">(</span><span class="s">"foo"</span><span class="p">));</span> <span class="c1">// prints bar</span> </span></span></code></pre> </div> <p> Store and retrieve a HashMap. </p> <div class="highlight"> <pre class="chroma"><code class="language-csharp" data-lang="csharp"><span class="line"><span class="cl"><span class="kt">var</span> <span class="n">hash</span> <span class="p">=</span> <span class="k">new</span> <span class="n">HashEntry</span><span class="p">[]</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="k">new</span> <span class="n">HashEntry</span><span class="p">(</span><span class="s">"name"</span><span class="p">,</span> <span class="s">"John"</span><span class="p">),</span> </span></span><span class="line"><span class="cl"> <span class="k">new</span> <span class="n">HashEntry</span><span class="p">(</span><span class="s">"surname"</span><span class="p">,</span> <span class="s">"Smith"</span><span class="p">),</span> </span></span><span class="line"><span class="cl"> <span class="k">new</span> <span class="n">HashEntry</span><span class="p">(</span><span class="s">"company"</span><span class="p">,</span> <span class="s">"Redis"</span><span class="p">),</span> </span></span><span class="line"><span class="cl"> <span class="k">new</span> <span class="n">HashEntry</span><span class="p">(</span><span class="s">"age"</span><span class="p">,</span> <span class="s">"29"</span><span class="p">),</span> </span></span><span class="line"><span class="cl"> <span class="p">};</span> </span></span><span class="line"><span class="cl"><span class="n">db</span><span class="p">.</span><span class="n">HashSet</span><span class="p">(</span><span class="s">"user-session:123"</span><span class="p">,</span> <span class="n">hash</span><span class="p">);</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kt">var</span> <span class="n">hashFields</span> <span class="p">=</span> <span class="n">db</span><span class="p">.</span><span class="n">HashGetAll</span><span class="p">(</span><span class="s">"user-session:123"</span><span class="p">);</span> </span></span><span class="line"><span class="cl"><span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="n">String</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">"; "</span><span class="p">,</span> <span class="n">hashFields</span><span class="p">));</span> </span></span><span class="line"><span class="cl"><span class="c1">// Prints: </span> </span></span><span class="line"><span class="cl"><span class="c1">// name: John; surname: Smith; company: Redis; age: 29</span> </span></span></code></pre> </div> <h2 id="redis-stack-modules"> Redis Stack modules </h2> <p> To access Redis Stack capabilities, use the appropriate interface like this: </p> <pre tabindex="0"><code>IBloomCommands bf = db.BF(); ICuckooCommands cf = db.CF(); ICmsCommands cms = db.CMS(); IGraphCommands graph = db.GRAPH(); ITopKCommands topk = db.TOPK(); ITdigestCommands tdigest = db.TDIGEST(); ISearchCommands ft = db.FT(); IJsonCommands json = db.JSON(); ITimeSeriesCommands ts = db.TS(); </code></pre> <h2 id="more-information"> More information </h2> <p> See the other pages in this section for more information and examples. </p> <nav> <a href="/docs/latest/develop/clients/dotnet/connect/"> Connect to the server </a> <p> Connect your .NET application to a Redis database </p> <a href="/docs/latest/develop/clients/dotnet/queryjson/"> Example - Index and query JSON documents </a> <p> Learn how to use the Redis query engine with JSON </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/clients/dotnet/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/deprecated-features/triggers-and-functions/known_limitations/.html
<section class="prose w-full py-12 max-w-none"> <h1> Known limitations </h1> <p class="text-lg -mt-5 mb-10"> Overview of the known limitations </p> <div class="banner-article rounded-md"> <p> The Redis Stack triggers and functions feature preview has ended and it will not be promoted to GA. </p> </div> <h2 id="limited-write-options"> Limited write options </h2> <p> JavaScript remote functions are limited to <strong> read operations </strong> only. Any attempt to perform a write operation of the following functions on a shard different than the one executing the function will result in an error. </p> <ul> <li> <code> async_client.runOnShards </code> runs the remote function on all the shards </li> <li> <code> async_client.runOnKey </code> runs the remote function on the shard responsible for a given key </li> </ul> <p> In addition, keyspace modification performed by JavaScript functions that are registered using any of the methods available should perform write operations locally: </p> <ul> <li> If the function is registered with <code> registerFunction </code> or <code> registerAsyncFunction </code> , it can insert, modify or delete keys that are in the same shard where the function is executed. </li> <li> If the function is registered with <code> registerKeySpaceTrigger </code> or <code> registerStreamTrigger </code> , keyspace modification must be local to the shard that originated the events. </li> </ul> <p> It is also recommended to co-locate the keys to be modified in the same hash slot as the key or Stream that originated the event. As an example, if the user profile stored in the Hash <code> myserv:user:1234 </code> is subject to changes and we'd like to count them in an external counter, we would name the counter using hash tags: <code> {myserv:user:1234}:cnt </code> . </p> <h2 id="exclusive-access-to-the-keyspace"> Exclusive access to the keyspace </h2> <p> By design, asynchronous functions guarantee exclusive single-threaded access to the keyspace, the distinctive feature of Redis. In asynchronous programming with JavaScript functions, access to the keyspace in read or write mode must be blocking, while if not accessing the keyspace, the execution may be non-blocking. This implementation maintains the same level of data consistency as Redis standard commands or Lua scripts and functions but takes advantage of asynchronous execution, a feature of the JavaScript engine. </p> <h2 id="javascript-variables"> JavaScript variables </h2> <p> Not all the JavaScript global variables are made available by the JavaScript engine loaded by Redis (e.g. <code> console </code> , <code> document </code> ). The <code> redis </code> global variable can be used to manage functions registration, logging etc. </p> <h2 id="sandboxed"> Sandboxed </h2> <p> This feature is sandboxed, meaning, from within a function, it’s not possible to make calls to external services, including other Redis databases, or APIs. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/deprecated-features/triggers-and-functions/known_limitations/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/develop/connect/clients/go/.html
<section class="prose w-full py-12 max-w-none"> <h1> go-redis guide (Go) </h1> <p class="text-lg -mt-5 mb-10"> Connect your Go application to a Redis database </p> <p> <a href="https://github.com/redis/go-redis"> <code> go-redis </code> </a> is the <a href="https://go.dev/"> Go </a> client for Redis. The sections below explain how to install <code> go-redis </code> and connect your application to a Redis database. </p> <p> <code> go-redis </code> requires a running Redis or <a href="/docs/latest/operate/oss_and_stack/install/install-stack/"> Redis Stack </a> server. See <a href="/docs/latest/operate/oss_and_stack/install/"> Getting started </a> for Redis installation instructions. </p> <h2 id="install"> Install </h2> <p> <code> go-redis </code> supports the last two Go versions. You can only use it from within a Go module, so you must initialize a Go module before you start, or add your code to an existing module: </p> <pre tabindex="0"><code>go mod init github.com/my/repo </code></pre> <p> Use the <code> go get </code> command to install <code> go-redis/v9 </code> : </p> <pre tabindex="0"><code>go get github.com/redis/go-redis/v9 </code></pre> <h2 id="connect"> Connect </h2> <p> The following example shows the simplest way to connect to a Redis server: </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="kn">import</span> <span class="p">(</span> </span></span><span class="line"><span class="cl"> <span class="s">"context"</span> </span></span><span class="line"><span class="cl"> <span class="s">"fmt"</span> </span></span><span class="line"><span class="cl"> <span class="s">"github.com/redis/go-redis/v9"</span> </span></span><span class="line"><span class="cl"><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">func</span> <span class="nf">main</span><span class="p">()</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nx">client</span> <span class="o">:=</span> <span class="nx">redis</span><span class="p">.</span><span class="nf">NewClient</span><span class="p">(</span><span class="o">&amp;</span><span class="nx">redis</span><span class="p">.</span><span class="nx">Options</span><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nx">Addr</span><span class="p">:</span> <span class="s">"localhost:6379"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nx">Password</span><span class="p">:</span> <span class="s">""</span><span class="p">,</span> <span class="c1">// No password set </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="nx">DB</span><span class="p">:</span> <span class="mi">0</span><span class="p">,</span> <span class="c1">// Use default DB </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="nx">Protocol</span><span class="p">:</span> <span class="mi">2</span><span class="p">,</span> <span class="c1">// Connection protocol </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="p">})</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> You can also connect using a connection string: </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="nx">opt</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">redis</span><span class="p">.</span><span class="nf">ParseURL</span><span class="p">(</span><span class="s">"redis://&lt;user&gt;:&lt;pass&gt;@localhost:6379/&lt;db&gt;"</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">client</span> <span class="o">:=</span> <span class="nx">redis</span><span class="p">.</span><span class="nf">NewClient</span><span class="p">(</span><span class="nx">opt</span><span class="p">)</span> </span></span></code></pre> </div> <p> After connecting, you can test the connection by storing and retrieving a simple <a href="/docs/latest/develop/data-types/strings/"> string </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="nx">ctx</span> <span class="o">:=</span> <span class="nx">context</span><span class="p">.</span><span class="nf">Background</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">err</span> <span class="o">:=</span> <span class="nx">client</span><span class="p">.</span><span class="nf">Set</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"foo"</span><span class="p">,</span> <span class="s">"bar"</span><span class="p">,</span> <span class="mi">0</span><span class="p">).</span><span class="nf">Err</span><span class="p">()</span> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">val</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">client</span><span class="p">.</span><span class="nf">Get</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"foo"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="s">"foo"</span><span class="p">,</span> <span class="nx">val</span><span class="p">)</span> </span></span></code></pre> </div> <p> You can also easily store and retrieve a <a href="/docs/latest/develop/data-types/hashes/"> hash </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="nx">hashFields</span> <span class="o">:=</span> <span class="p">[]</span><span class="kt">string</span><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="s">"model"</span><span class="p">,</span> <span class="s">"Deimos"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s">"brand"</span><span class="p">,</span> <span class="s">"Ergonom"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s">"type"</span><span class="p">,</span> <span class="s">"Enduro bikes"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s">"price"</span><span class="p">,</span> <span class="s">"4972"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">res1</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">HSet</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bike:1"</span><span class="p">,</span> <span class="nx">hashFields</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res1</span><span class="p">)</span> <span class="c1">// &gt;&gt;&gt; 4 </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="nx">res2</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">HGet</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bike:1"</span><span class="p">,</span> <span class="s">"model"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res2</span><span class="p">)</span> <span class="c1">// &gt;&gt;&gt; Deimos </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="nx">res3</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">HGet</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bike:1"</span><span class="p">,</span> <span class="s">"price"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res3</span><span class="p">)</span> <span class="c1">// &gt;&gt;&gt; 4972 </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="nx">res4</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">HGetAll</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bike:1"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res4</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="c1">// &gt;&gt;&gt; map[brand:Ergonom model:Deimos price:4972 type:Enduro bikes] </span></span></span></code></pre> </div> <p> Use <a href="https://stackoverflow.com/questions/10858787/what-are-the-uses-for-struct-tags-in-go"> struct tags </a> of the form <code> redis:"&lt;field-name&gt;" </code> with the <code> Scan() </code> method to parse fields from a hash directly into corresponding struct fields: </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="kd">type</span> <span class="nx">BikeInfo</span> <span class="kd">struct</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nx">Model</span> <span class="kt">string</span> <span class="s">`redis:"model"`</span> </span></span><span class="line"><span class="cl"> <span class="nx">Brand</span> <span class="kt">string</span> <span class="s">`redis:"brand"`</span> </span></span><span class="line"><span class="cl"> <span class="nx">Type</span> <span class="kt">string</span> <span class="s">`redis:"type"`</span> </span></span><span class="line"><span class="cl"> <span class="nx">Price</span> <span class="kt">int</span> <span class="s">`redis:"price"`</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">var</span> <span class="nx">res4a</span> <span class="nx">BikeInfo</span> </span></span><span class="line"><span class="cl"><span class="nx">err</span> <span class="p">=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">HGetAll</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bike:1"</span><span class="p">).</span><span class="nf">Scan</span><span class="p">(</span><span class="o">&amp;</span><span class="nx">res4a</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">fmt</span><span class="p">.</span><span class="nf">Printf</span><span class="p">(</span><span class="s">"Model: %v, Brand: %v, Type: %v, Price: $%v\n"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nx">res4a</span><span class="p">.</span><span class="nx">Model</span><span class="p">,</span> <span class="nx">res4a</span><span class="p">.</span><span class="nx">Brand</span><span class="p">,</span> <span class="nx">res4a</span><span class="p">.</span><span class="nx">Type</span><span class="p">,</span> <span class="nx">res4a</span><span class="p">.</span><span class="nx">Price</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="c1">// &gt;&gt;&gt; Model: Deimos, Brand: Ergonom, Type: Enduro bikes, Price: $4972 </span></span></span></code></pre> </div> <h2 id="observability"> Observability </h2> <p> <code> go-redis </code> supports <a href="https://opentelemetry.io/"> OpenTelemetry </a> instrumentation. to monitor performance and trace the execution of Redis commands. For example, the following code instruments Redis commands to collect traces, logs, and metrics: </p> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="kn">import</span> <span class="p">(</span> </span></span><span class="line"><span class="cl"> <span class="s">"github.com/redis/go-redis/v9"</span> </span></span><span class="line"><span class="cl"> <span class="s">"github.com/redis/go-redis/extra/redisotel/v9"</span> </span></span><span class="line"><span class="cl"><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nx">rdb</span> <span class="o">:=</span> <span class="nx">redis</span><span class="p">.</span><span class="nf">NewClient</span><span class="p">(</span><span class="o">&amp;</span><span class="nx">redis</span><span class="p">.</span><span class="nx">Options</span><span class="p">{</span><span class="o">...</span><span class="p">})</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="c1">// Enable tracing instrumentation. </span></span></span><span class="line"><span class="cl"><span class="c1"></span><span class="k">if</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">redisotel</span><span class="p">.</span><span class="nf">InstrumentTracing</span><span class="p">(</span><span class="nx">rdb</span><span class="p">);</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="c1">// Enable metrics instrumentation. </span></span></span><span class="line"><span class="cl"><span class="c1"></span><span class="k">if</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">redisotel</span><span class="p">.</span><span class="nf">InstrumentMetrics</span><span class="p">(</span><span class="nx">rdb</span><span class="p">);</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> See the <code> go-redis </code> <a href="https://github.com/redis/go-redis/blob/master/example/otel/README.md"> GitHub repo </a> . for more OpenTelemetry examples. </p> <h2 id="more-information"> More information </h2> <p> See the other pages in this section for more information and examples. Further examples are available at the <a href="https://redis.uptrace.dev/guide/"> <code> go-redis </code> </a> website and the <a href="https://github.com/redis/go-redis"> GitHub repository </a> . </p> <nav> <a href="/docs/latest/develop/clients/go/connect/"> Connect to the server </a> <p> Connect your Go application to a Redis database </p> <a href="/docs/latest/develop/clients/go/queryjson/"> Example - Index and query JSON documents </a> <p> Learn how to use the Redis query engine with JSON </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/clients/go/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/databases/active-active/get-started/.html
<section class="prose w-full py-12 max-w-none"> <h1> Get started with Redis Enterprise Active-Active databases </h1> <p class="text-lg -mt-5 mb-10"> Quick start guide to create an Active-Active database for test and development. </p> <p> To get started, this article will help you set up an Active-Active database, formerly known as CRDB (conflict-free replicated database), spanning across two Redis Enterprise Software clusters for test and development environments. Here are the steps: </p> <ol> <li> <p> Run two Redis Enterprise Software Docker containers. </p> </li> <li> <p> Set up each container as a cluster. </p> </li> <li> <p> Create a new Redis Enterprise Active-Active database. </p> </li> <li> <p> Test connectivity to the Active-Active database. </p> </li> </ol> <p> To run an Active-Active database on installations from the <a href="/docs/latest/operate/rs/installing-upgrading/quickstarts/redis-enterprise-software-quickstart/"> Redis Enterprise Software download package </a> , set up two Redis Enterprise Software installations and continue from Step 2. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> This getting started guide is for development or demonstration environments. For production environments, see <a href="/docs/latest/operate/rs/databases/active-active/create/"> Create an Active-Active geo-replicated database </a> for instructions. </div> </div> <h2 id="run-two-containers"> Run two containers </h2> <p> To spin up two Redis Enterprise Software containers, run these commands: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">docker run -d --cap-add sys_resource -h rs1_node1 --name rs1_node1 -p 8443:8443 -p 9443:9443 -p 12000:12000 redislabs/redis </span></span></code></pre> </div> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">docker run -d --cap-add sys_resource -h rs2_node1 --name rs2_node1 -p 8445:8443 -p 9445:9443 -p 12002:12000 redislabs/redis </span></span></code></pre> </div> <p> The <strong> -p </strong> options map the Cluster Manager UI port (8443), REST API port (9443), and database access port differently for each container to make sure that all containers can be accessed from the host OS that is running the containers. </p> <h2 id="set-up-two-clusters"> Set up two clusters </h2> <ol> <li> <p> For cluster 1, go to <code> https://localhost:8443 </code> in a browser on the host machine to access the Redis Enterprise Software Cluster Manager UI. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Depending on your browser, you may see a certificate error. Continue to the website. </div> </div> </li> <li> <p> Click <strong> Create new cluster </strong> : </p> <a href="/docs/latest/images/rs/screenshots/cluster/setup/create-cluster.png" sdata-lightbox="/images/rs/screenshots/cluster/setup/create-cluster.png"> <img alt="When you first install Redis Enterprise Software, you need to set up a cluster." src="/docs/latest/images/rs/screenshots/cluster/setup/create-cluster.png"/> </a> </li> <li> <p> Enter an email and password for the administrator account, then click <strong> Next </strong> to proceed to cluster setup: </p> <a href="/docs/latest/images/rs/screenshots/cluster/setup/admin-credentials.png" sdata-lightbox="/images/rs/screenshots/cluster/setup/admin-credentials.png"> <img alt="Set the credentials for your admin user." src="/docs/latest/images/rs/screenshots/cluster/setup/admin-credentials.png"/> </a> </li> <li> <p> Enter your cluster license key if you have one. Otherwise, a trial version is installed. </p> <a href="/docs/latest/images/rs/screenshots/cluster/setup/cluster-license-key.png" sdata-lightbox="/images/rs/screenshots/cluster/setup/cluster-license-key.png"> <img alt="Enter your cluster license key if you have one." src="/docs/latest/images/rs/screenshots/cluster/setup/cluster-license-key.png"/> </a> </li> <li> <p> In the <strong> Configuration </strong> section of the <strong> Cluster </strong> settings page, enter a cluster FQDN, for example <code> cluster1.local </code> : </p> <a href="/docs/latest/images/rs/screenshots/cluster/setup/config-cluster1.png" sdata-lightbox="/images/rs/screenshots/cluster/setup/config-cluster1.png"> <img alt="Configure the cluster FQDN." src="/docs/latest/images/rs/screenshots/cluster/setup/config-cluster1.png"/> </a> </li> <li> <p> On the node setup screen, keep the default settings and click <strong> Create cluster </strong> : </p> <a href="/docs/latest/images/rs/screenshots/cluster/setup/node-settings.png" sdata-lightbox="/images/rs/screenshots/cluster/setup/node-settings.png"> <img alt="Configure the node specific settings." src="/docs/latest/images/rs/screenshots/cluster/setup/node-settings.png"/> </a> </li> <li> <p> Click <strong> OK </strong> to confirm that you are aware of the replacement of the HTTPS SSL/TLS certificate on the node, and proceed through the browser warning. </p> </li> <li> <p> Repeat the previous steps for cluster 2 with these differences: </p> <ul> <li> <p> In your web browser, go to <code> https://localhost:8445 </code> to set up the cluster 2. </p> </li> <li> <p> For the <strong> Cluster name (FQDN) </strong> , enter a different name, such as <code> cluster2.local </code> . </p> </li> </ul> </li> </ol> <p> Now you have two Redis Enterprise Software clusters with FQDNs <code> cluster1.local </code> and <code> cluster2.local </code> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Each Active-Active instance must have a unique fully-qualified domain name (FQDN). </div> </div> <h2 id="create-an-active-active-database"> Create an Active-Active database </h2> <ol> <li> <p> Sign in to cluster1.local's Cluster Manager UI at <code> https://localhost:8443 </code> </p> </li> <li> <p> Open the <strong> Create database </strong> menu with one of the following methods: </p> <ul> <li> <p> Click the <strong> + </strong> button next to <strong> Databases </strong> in the navigation menu: </p> <a href="/docs/latest/images/rs/screenshots/databases/create-db-plus-drop-down.png" sdata-lightbox="/images/rs/screenshots/databases/create-db-plus-drop-down.png"> <img alt="Create database menu has two options: Single Region and Active-Active database." src="/docs/latest/images/rs/screenshots/databases/create-db-plus-drop-down.png" width="350px"/> </a> </li> <li> <p> Go to the <strong> Databases </strong> screen and select <strong> Create database </strong> : </p> <a href="/docs/latest/images/rs/screenshots/databases/create-db-button-drop-down.png" sdata-lightbox="/images/rs/screenshots/databases/create-db-button-drop-down.png"> <img alt="Create database menu has two options: Single Region and Active-Active database." src="/docs/latest/images/rs/screenshots/databases/create-db-button-drop-down.png" width="350px"/> </a> </li> </ul> </li> <li> <p> Select <strong> Active-Active database </strong> . </p> </li> <li> <p> Enter the cluster's local admin credentials, then click <strong> Save </strong> : </p> <a href="/docs/latest/images/rs/screenshots/databases/active-active-databases/enter-local-admin-credentials-cluster1.png" sdata-lightbox="/images/rs/screenshots/databases/active-active-databases/enter-local-admin-credentials-cluster1.png"> <img alt="Enter the cluster's admin username and password." src="/docs/latest/images/rs/screenshots/databases/active-active-databases/enter-local-admin-credentials-cluster1.png"/> </a> </li> <li> <p> Add participating clusters that will host instances of the Active-Active database: </p> <ol> <li> <p> In the <strong> Participating clusters </strong> section, go to <strong> Other participating clusters </strong> and click <strong> + Add cluster </strong> . </p> </li> <li> <p> In the <strong> Add cluster </strong> configuration panel, enter the new cluster's URL, port number, and the admin username and password for the new participating cluster: </p> <p> In the <strong> Other participating clusters </strong> list, add the address and admin credentials for the other cluster: <code> https://cluster2.local:9443 </code> </p> <a href="/docs/latest/images/rs/screenshots/databases/active-active-databases/participating-clusters-add-cluster2.png" sdata-lightbox="/images/rs/screenshots/databases/active-active-databases/participating-clusters-add-cluster2.png"> <img alt="Add cluster panel." src="/docs/latest/images/rs/screenshots/databases/active-active-databases/participating-clusters-add-cluster2.png"/> </a> </li> <li> <p> Click <strong> Join cluster </strong> to add the cluster to the list of participating clusters. </p> </li> </ol> </li> <li> <p> Enter <code> database1 </code> for <strong> Database name </strong> and <code> 12000 </code> for <strong> Port </strong> : </p> <a href="/docs/latest/images/rs/screenshots/databases/active-active-databases/quickstart-db-name-port.png" sdata-lightbox="/images/rs/screenshots/databases/active-active-databases/quickstart-db-name-port.png"> <img alt="Database name and port text boxes." src="/docs/latest/images/rs/screenshots/databases/active-active-databases/quickstart-db-name-port.png"/> </a> </li> <li> <p> Configure additional settings: </p> <ol> <li> <p> In the <strong> High availability </strong> section, turn off <strong> Replication </strong> since each cluster has only one node in this setup: </p> <a href="/docs/latest/images/rs/screenshots/databases/active-active-databases/quickstart-ha-turn-off-replication-7-8-2.png" sdata-lightbox="/images/rs/screenshots/databases/active-active-databases/quickstart-ha-turn-off-replication-7-8-2.png"> <img alt="Turn off replication in the High availability section." src="/docs/latest/images/rs/screenshots/databases/active-active-databases/quickstart-ha-turn-off-replication-7-8-2.png"/> </a> </li> <li> <p> In the <strong> Clustering </strong> section, either: </p> <ul> <li> <p> Make sure that <strong> Sharding </strong> is enabled and select the number of shards you want to have in the database. When database clustering is enabled, databases are subject to limitations on <a href="/docs/latest/operate/rs/databases/durability-ha/clustering/"> Multi-key commands </a> . You can increase the number of shards in the database at any time. </p> </li> <li> <p> Turn off <strong> Sharding </strong> to use only one shard and avoid <a href="/docs/latest/operate/rs/databases/durability-ha/clustering/"> Multi-key command </a> limitations. </p> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> You cannot enable or turn off database clustering after the Active-Active database is created. </div> </div> </li> </ol> </li> <li> <p> Click <strong> Create </strong> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> If you cannot activate the database because of a memory limitation, make sure that Docker has at least 4 GB of memory allocated in the <strong> Advanced </strong> section of Docker <strong> Settings </strong> . </div> </div> </li> <li> <p> After the Active-Active database is created, sign in to the Cluster Manager UIs for cluster 1 at <code> https://localhost:8443 </code> and cluster 2 at <code> https://localhost:8445 </code> . </p> </li> <li> <p> Make sure each cluster has an Active-Active database member database with the name <code> database1 </code> . </p> <p> In a real-world deployment, cluster 1 and cluster 2 would most likely be in separate data centers in different regions. However, for local testing we created the scale-minimized deployment using two local clusters running on the same host. </p> </li> </ol> <!-- Also in getting-started-crdbs.md --> <h2 id="test-connection"> Test connection </h2> <p> With the Redis database created, you are ready to connect to your database. See <a href="/docs/latest/operate/rs/databases/active-active/connect/"> Connect to Active-Active databases </a> for tutorials and examples of multiple connection methods. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/databases/active-active/get-started/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/users/authorize/.html
<section class="prose w-full py-12 max-w-none"> <h1> Authorize user requests </h1> <p class="text-lg -mt-5 mb-10"> Users authorization requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#post-authorize"> POST </a> </td> <td> <code> /v1/users/authorize </code> </td> <td> Authorize a user </td> </tr> </tbody> </table> <h2 id="post-authorize"> Authorize user </h2> <pre><code>POST /v1/users/authorize </code></pre> <p> Generate a JSON Web Token (JWT) for a user to use as authorization to access the REST API. </p> <h3 id="post-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <pre><code>POST /users/authorize </code></pre> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"username"</span><span class="p">:</span> <span class="s2">"user@redislabs.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password"</span><span class="p">:</span> <span class="s2">"my_password"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="request-headers"> Request headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="request-body"> Request body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/jwt_authorize/"> JWT authorize object </a> with a valid username and password in the request body. </p> <h3 id="post-response"> Response </h3> <p> Returns a JSON object that contains the generated access token. </p> <h4 id="example-json-body-1"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"access_token"</span><span class="p">:</span> <span class="s2">"eyJ5bGciOiKIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXViOjE0NjU0NzU0ODYsInVpZFI1IjEiLCJleHAiOjE0NjU0Nz30OTZ9.2xYXumd1rDoE0edFzcLElMOHsshaqQk2HUNgdsUKxMU"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="post-error-codes"> Error codes </h3> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> fields that provide additional information. The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password_expired </td> <td> The password has expired and must be changed. </td> </tr> </tbody> </table> <h3 id="post-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The user is authorized. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1"> 400 Bad Request </a> </td> <td> The request could not be understood by the server due to malformed syntax. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.2"> 401 Unauthorized </a> </td> <td> The user is unauthorized. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/users/authorize/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/databases/migrate-shards/.html
<section class="prose w-full py-12 max-w-none"> <h1> Migrate database shards </h1> <p class="text-lg -mt-5 mb-10"> How to migrate database shards to other nodes in a Redis Software cluster. </p> <p> To migrate database shards to other nodes in the cluster, you can use the <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/"> <code> rladmin migrate </code> </a> command or <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/migrate/"> REST API requests </a> . </p> <h2 id="use-cases-for-shard-migration"> Use cases for shard migration </h2> <p> Migrate database shards to a different node in the following scenarios: </p> <ul> <li> <p> Before node removal. </p> </li> <li> <p> To balance the database manually in case of latency issues or uneven load distribution across nodes. </p> </li> <li> <p> To manage node resources, such as memory usage. </p> </li> </ul> <h2 id="considerations-for-shard-migration"> Considerations for shard migration </h2> <p> For databases with replication: </p> <ul> <li> <p> Migrating a shard will not cause disruptions since a primary shard will still be available. </p> </li> <li> <p> If you try to migrate a primary shard, it will be demoted to a replica shard and a replica shard will be promoted to primary before the migration. If you set <code> "preserve_roles": true </code> in the request, a second failover will occur after the migration finishes to change the migrated shard's role back to primary. </p> </li> </ul> <p> For databases without replication, the migrated shard will not be available until the migration is done. </p> <p> Connected clients shouldn't be disconnected in either case. </p> <p> If too many primary shards are placed on the same node, it can impact database performance. </p> <h2 id="migrate-specific-shard"> Migrate specific shard </h2> <p> To migrate a specific database shard, use one of the following methods: </p> <ul> <li> <p> <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/#migrate-shard"> <code> rladmin migrate shard </code> </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate shard &lt;shard_id&gt; target_node &lt;node_id&gt; </span></span></code></pre> </div> </li> <li> <p> <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/migrate/#post-shard"> Migrate shard </a> REST API request: </p> <p> Specify the ID of the shard to migrate in the request path and the destination node's ID as the <code> target_node_uid </code> in the request body. See the <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/migrate/#post-request-body"> request reference </a> for more options. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/shards/&lt;shard_id&gt;/actions/migrate </span></span><span class="line"><span class="cl"><span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="s2">"target_node_uid"</span>: &lt;node_id&gt; </span></span><span class="line"><span class="cl"><span class="o">}</span> </span></span></code></pre> </div> <p> Example JSON response body: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"action_uid"</span><span class="p">:</span> <span class="s2">"&lt;action_id&gt;"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"description"</span><span class="p">:</span> <span class="s2">"Migrate was triggered"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> You can track the action's progress with a <a href="/docs/latest/operate/rs/references/rest-api/requests/actions/#get-action"> <code> GET /v1/actions/&lt;action_uid&gt; </code> </a> request. </p> </li> </ul> <h2 id="migrate-multiple-shards"> Migrate multiple shards </h2> <p> To migrate multiple database shards, use one of the following methods: </p> <ul> <li> <p> <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/#migrate-shard"> <code> rladmin migrate shard </code> </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate shard &lt;shard_id1&gt; &lt;shard_id2&gt; &lt;shard_id3&gt; target_node &lt;node_id&gt; </span></span></code></pre> </div> </li> <li> <p> <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/migrate/#post-multi-shards"> Migrate multiple shards </a> REST API request: </p> <p> Specify the IDs of the shards to migrate in the <code> shard_uids </code> list and the destination node's ID as the <code> target_node_uid </code> in the request body. See the <a href="/docs/latest/operate/rs/references/rest-api/requests/shards/actions/migrate/#post-multi-request-body"> request reference </a> for more options. </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/shards/actions/migrate </span></span><span class="line"><span class="cl"><span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="s2">"shard_uids"</span>: <span class="o">[</span><span class="s2">"&lt;shard_id1&gt;"</span>,<span class="s2">"&lt;shard_id2&gt;"</span>,<span class="s2">"&lt;shard_id3&gt;"</span><span class="o">]</span>, </span></span><span class="line"><span class="cl"> <span class="s2">"target_node_uid"</span>: &lt;node_id&gt; </span></span><span class="line"><span class="cl"><span class="o">}</span> </span></span></code></pre> </div> <p> Example JSON response body: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"action_uid"</span><span class="p">:</span> <span class="s2">"&lt;action_id&gt;"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"description"</span><span class="p">:</span> <span class="s2">"Migrate was triggered"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> You can track the action's progress with a <a href="/docs/latest/operate/rs/references/rest-api/requests/actions/#get-action"> <code> GET /v1/actions/&lt;action_uid&gt; </code> </a> request. </p> </li> </ul> <h2 id="migrate-all-shards-from-a-node"> Migrate all shards from a node </h2> <p> To migrate all shards from a specific node to another node, run <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/#migrate-all_shards"> <code> rladmin migrate all_shards </code> </a> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate node &lt;origin_node_id&gt; all_shards target_node &lt;node_id&gt; </span></span></code></pre> </div> <h2 id="migrate-primary-shards"> Migrate primary shards </h2> <p> You can use the <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/#migrate-all_master_shards"> <code> rladmin migrate all_master_shards </code> </a> command to migrate all primary shards for a specific database or node to another node in the cluster. </p> <p> To migrate a specific database's primary shards: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate db db:&lt;id&gt; all_master_shards target_node &lt;node_id&gt; </span></span></code></pre> </div> <p> To migrate all primary shards from a specific node: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate node &lt;origin_node_id&gt; all_master_shards target_node &lt;node_id&gt; </span></span></code></pre> </div> <h2 id="migrate-replica-shards"> Migrate replica shards </h2> <p> You can use the <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/migrate/#migrate-all_slave_shards"> <code> rladmin migrate all_slave_shards </code> </a> command to migrate all replica shards for a specific database or node to another node in the cluster. </p> <p> To migrate a specific database's replica shards: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate db db:&lt;id&gt; all_slave_shards target_node &lt;node_id&gt; </span></span></code></pre> </div> <p> To migrate all replica shards from a specific node: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin migrate node &lt;origin_node_id&gt; all_slave_shards target_node &lt;node_id&gt; </span></span></code></pre> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/databases/migrate-shards/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/references/rest-api/requests/bdbs/passwords/.html
<section class="prose w-full py-12 max-w-none"> <h1> Database passwords requests </h1> <p class="text-lg -mt-5 mb-10"> Database password requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#put-bdbs-password"> PUT </a> </td> <td> <code> /v1/bdbs/{uid}/passwords </code> </td> <td> Update database password </td> </tr> <tr> <td> <a href="#post-bdbs-password"> POST </a> </td> <td> <code> /v1/bdbs/{uid}/passwords </code> </td> <td> Add database password </td> </tr> <tr> <td> <a href="#delete-bdbs-password"> DELETE </a> </td> <td> <code> /v1/bdbs/{uid}/passwords </code> </td> <td> Delete database password </td> </tr> </tbody> </table> <h2 id="put-bdbs-password"> Update database password </h2> <pre><code>PUT /v1/bdbs/{int: uid}/passwords </code></pre> <p> Set a single password for the bdb's default user (i.e., for <code> AUTH </code> <code> &lt;password&gt; </code> authentications). </p> <h4 id="required-permissions"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/7.4/references/rest-api/permissions/#update_bdb"> update_bdb </a> </td> </tr> </tbody> </table> <h3 id="put-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <pre><code>PUT /bdbs/1/passwords </code></pre> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password"</span><span class="p">:</span> <span class="s2">"new password"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request resets the password of the bdb to β€˜new password’. </p> <h4 id="request-headers"> Request headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database to update the password. </td> </tr> </tbody> </table> <h4 id="request-body"> Request body </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password </td> <td> string </td> <td> New password </td> </tr> </tbody> </table> <h3 id="put-response"> Response </h3> <p> Returns a status code that indicates password update success or failure. </p> <h3 id="put-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The password was changed. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> A nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> Invalid configuration parameters provided. </td> </tr> </tbody> </table> <h2 id="post-bdbs-password"> Add database password </h2> <pre><code>POST /v1/bdbs/{int: uid}/passwords </code></pre> <p> Add a password to the bdb's default user (i.e., for <code> AUTH </code> <code> &lt;password&gt; </code> authentications). </p> <h4 id="required-permissions-1"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/7.4/references/rest-api/permissions/#update_bdb"> update_bdb </a> </td> </tr> </tbody> </table> <h3 id="post-request"> Request </h3> <h4 id="example-http-request-1"> Example HTTP request </h4> <pre><code>POST /bdbs/1/passwords </code></pre> <h4 id="example-json-body-1"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password"</span><span class="p">:</span> <span class="s2">"password to add"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request adds a password to the bdb. </p> <h4 id="request-headers-1"> Request headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters-1"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database to add password. </td> </tr> </tbody> </table> <h4 id="request-body-1"> Request body </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password </td> <td> string </td> <td> Password to add </td> </tr> </tbody> </table> <h3 id="post-response"> Response </h3> <p> Returns a status code that indicates password creation success or failure. </p> <h3 id="post-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The password was added. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> A nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> Invalid configuration parameters provided. </td> </tr> </tbody> </table> <h2 id="delete-bdbs-password"> Delete database password </h2> <pre><code>DELETE /v1/bdbs/{int: uid}/passwords </code></pre> <p> Delete a password from the bdb's default user (i.e., for <code> AUTH </code> <code> &lt;password&gt; </code> authentications). </p> <h4 id="required-permissions-2"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/7.4/references/rest-api/permissions/#update_bdb"> update_bdb </a> </td> </tr> </tbody> </table> <h3 id="delete-request"> Request </h3> <h4 id="example-http-request-2"> Example HTTP request </h4> <pre><code>DELETE /bdbs/1/passwords </code></pre> <h4 id="example-json-body-2"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password"</span><span class="p">:</span> <span class="s2">"password to delete"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request deletes a password from the bdb. </p> <h4 id="request-headers-2"> Request headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters-2"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database to delete password. </td> </tr> </tbody> </table> <h4 id="request-body-2"> Request body </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password </td> <td> string </td> <td> Password to delete </td> </tr> </tbody> </table> <h3 id="delete-response"> Response </h3> <p> Returns a status code that indicates password deletion success or failure. </p> <h3 id="delete-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The password was deleted. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> A nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> Invalid configuration parameters provided. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/references/rest-api/requests/bdbs/passwords/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/databases/active-active/.html
<section class="prose w-full py-12 max-w-none"> <h1> Active-Active geo-distributed Redis </h1> <p class="text-lg -mt-5 mb-10"> Overview of the Active-Active database in Redis Enterprise Software </p> <p> In Redis Enterprise, Active-Active geo-distribution is based on <a href="https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type"> CRDT technology </a> . The Redis Enterprise implementation of CRDT is called an Active-Active database (formerly known as CRDB). With Active-Active databases, applications can read and write to the same data set from different geographical locations seamlessly and with latency less than one millisecond (ms), without changing the way the application connects to the database. </p> <p> Active-Active databases also provide disaster recovery and accelerated data read-access for geographically distributed users. </p> <h2 id="high-availability"> High availability </h2> <p> The <a href="/docs/latest/operate/rs/databases/durability-ha/"> high availability </a> that Active-Active replication provides is built upon a number of Redis Enterprise Software features (such as <a href="/docs/latest/operate/rs/databases/durability-ha/clustering/"> clustering </a> , <a href="/docs/latest/operate/rs/databases/durability-ha/replication/"> replication </a> , and <a href="/docs/latest/operate/rs/databases/configure/replica-ha/"> replica HA </a> ) as well as some features unique to Active-Active ( <a href="#multi-primary-replication/"> multi-primary replication </a> , <a href="#conflict-resolution/"> automatic conflict resolution </a> , and <a href="#strong-eventual-consistency/"> strong eventual consistency </a> ). </p> <p> Clustering and replication are used together in Active-Active databases to distribute multiple copies of the dataset across multiple nodes and multiple clusters. As a result, a node or cluster is less likely to become a single point of failure. If a primary node or primary shard fails, a replica is automatically promoted to primary. To avoid having one node hold all copies of certain data, the <a href="/docs/latest/operate/rs/databases/configure/replica-ha/"> replica HA </a> feature (enabled by default) automatically migrates replica shards to available nodes. </p> <h2 id="multi-primary-replication"> Multi-primary replication </h2> <p> In Redis Enterprise Software, replication copies data from primary shards to replica shards. Active-Active geo-distributed replication also copies both primary and replica shards to other clusters. Each Active-Active database needs to span at least two clusters; these are called participating clusters. </p> <p> Each participating cluster hosts an instance of your database, and each instance has its own primary node. Having multiple primary nodes means you can connect to the proxy in any of your participating clusters. Connecting to the closest cluster geographically enables near-local latency. Multi-primary replication (previously referred to as multi-master replication) also means that your users still have access to the database if one of the participating clusters fails. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Active-Active databases do not replicate the entire database, only the data. Database configurations, LUA scripts, and other support info are not replicated. </div> </div> <h2 id="syncer"> Syncer </h2> <p> Keeping multiple copies of the dataset consistent across multiple clusters is no small task. To achieve consistency between participating clusters, Redis Active-Active replication uses a process called the <a href="/docs/latest/operate/rs/databases/active-active/syncer/"> syncer </a> . </p> <p> The syncer keeps a <a href="/docs/latest/operate/rs/databases/active-active/manage/#replication-backlog/"> replication backlog </a> , which stores changes to the dataset that the syncer sends to other participating clusters. The syncer uses partial syncs to keep replicas up to date with changes, or a full sync in the event a replica or primary is lost. </p> <h2 id="conflict-resolution"> Conflict resolution </h2> <p> Because you can connect to any participating cluster to perform a write operation, concurrent and conflicting writes are always possible. Conflict resolution is an important part of the Active-Active technology. Active-Active databases only use <a href="https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type"> conflict-free replicated data types (CRDTs) </a> . These data types provide a predictable conflict resolution and don't require any additional work from the application or client side. </p> <p> When developing with CRDTs for Active-Active databases, you need to consider some important differences. See <a href="/docs/latest/operate/rs/databases/active-active/develop/"> Develop applications with Active-Active databases </a> for related information. </p> <h2 id="strong-eventual-consistency"> Strong eventual consistency </h2> <p> Maintaining strong consistency for replicated databases comes with tradeoffs in scalability and availability. Redis Active-Active databases use a strong eventual consistency model, which means that local values may differ across replicas for short periods of time, but they all eventually converge to one consistent state. Redis uses vector clocks and the CRDT conflict resolution to strengthen consistency between replicas. You can also enable the causal consistency feature to preserve the order of operations as they are synchronized among replicas. </p> <p> Other Redis Enterprise Software features can also be used to enhance the performance, scalability, or durability of your Active-Active database. These include <a href="/docs/latest/operate/rs/databases/configure/database-persistence/"> data persistence </a> , <a href="/docs/latest/operate/rs/databases/configure/proxy-policy/"> multiple active proxies </a> , <a href="/docs/latest/operate/rs/databases/active-active/synchronization-mode/"> distributed synchronization </a> , <a href="/docs/latest/operate/rs/databases/configure/oss-cluster-api/"> OSS Cluster API </a> , and <a href="/docs/latest/operate/rs/clusters/configure/rack-zone-awareness/"> rack-zone awareness </a> . </p> <h2 id="next-steps"> Next steps </h2> <ul> <li> <a href="/docs/latest/operate/rs/databases/active-active/planning/"> Plan your Active-Active deployment </a> </li> <li> <a href="/docs/latest/operate/rs/databases/active-active/get-started/"> Get started with Active-Active </a> </li> <li> <a href="/docs/latest/operate/rs/databases/active-active/create/"> Create an Active-Active database </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/databases/active-active/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/bitop/.html
<section class="prose w-full py-12"> <h1 class="command-name"> BITOP </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">BITOP &lt;AND | OR | XOR | NOT&gt; destkey key [key ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 2.6.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @write </code> <span class="mr-1 last:hidden"> , </span> <code> @bitmap </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Perform a bitwise operation between multiple keys (containing string values) and store the result in the destination key. </p> <p> The <code> BITOP </code> command supports four bitwise operations: <strong> AND </strong> , <strong> OR </strong> , <strong> XOR </strong> and <strong> NOT </strong> , thus the valid forms to call the command are: </p> <ul> <li> <code> BITOP AND destkey srckey1 srckey2 srckey3 ... srckeyN </code> </li> <li> <code> BITOP OR destkey srckey1 srckey2 srckey3 ... srckeyN </code> </li> <li> <code> BITOP XOR destkey srckey1 srckey2 srckey3 ... srckeyN </code> </li> <li> <code> BITOP NOT destkey srckey </code> </li> </ul> <p> As you can see <strong> NOT </strong> is special as it only takes an input key, because it performs inversion of bits so it only makes sense as a unary operator. </p> <p> The result of the operation is always stored at <code> destkey </code> . </p> <h2 id="handling-of-strings-with-different-lengths"> Handling of strings with different lengths </h2> <p> When an operation is performed between strings having different lengths, all the strings shorter than the longest string in the set are treated as if they were zero-padded up to the length of the longest string. </p> <p> The same holds true for non-existent keys, that are considered as a stream of zero bytes up to the length of the longest string. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; SET key1 "foobar" "OK" redis&gt; SET key2 "abcdef" "OK" redis&gt; BITOP AND dest key1 key2 (integer) 6 redis&gt; GET dest "`bc`ab" </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="pattern-real-time-metrics-using-bitmaps"> Pattern: real time metrics using bitmaps </h2> <p> <code> BITOP </code> is a good complement to the pattern documented in the <a href="/docs/latest/commands/bitcount/"> <code> BITCOUNT </code> </a> command documentation. Different bitmaps can be combined in order to obtain a target bitmap where the population counting operation is performed. </p> <p> See the article called " <a href="http://blog.getspool.com/2011/11/29/fast-easy-realtime-metrics-using-redis-bitmaps"> Fast easy realtime metrics using Redis bitmaps </a> " for an interesting use cases. </p> <h2 id="performance-considerations"> Performance considerations </h2> <p> <code> BITOP </code> is a potentially slow command as it runs in O(N) time. Care should be taken when running it against long input strings. </p> <p> For real-time metrics and statistics involving large inputs a good approach is to use a replica (with replica-read-only option enabled) where the bit-wise operations are performed to avoid blocking the master instance. </p> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#integers"> Integer reply </a> : the size of the string stored in the destination key is equal to the size of the longest input string. <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/bitop/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/json.mset.html
<section class="prose w-full py-12"> <h1 class="command-name"> JSON.MSET </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">JSON.MSET key path value [key path value ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/json"> JSON 2.6.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(K*(M+N)) where k is the number of keys in the command, when path is evaluated to a single value where M is the size of the original value (if it exists) and N is the size of the new value, or O(K*(M+N)) when path is evaluated to multiple values where M is the size of the key and N is the size of the new value * the number of original values in the key </dd> </dl> <p> Set or update one or more JSON values according to the specified <code> key </code> - <code> path </code> - <code> value </code> triplets </p> <p> <code> JSON.MSET </code> is atomic, hence, all given additions or updates are either applied or not. It is not possible for clients to see that some of the keys were updated while others are unchanged. </p> <p> A JSON value is a hierarchical structure. If you change a value in a specific path - nested values are affected. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> When cluster mode is enabled, all specified keys must reside on the same <a href="https://redis.io/docs/latest/operate/oss_and_stack/reference/cluster-spec/#key-distribution-model"> hash slot </a> . </div> </div> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key to modify. </p> </details> <details open=""> <summary> <code> path </code> </summary> <p> is JSONPath to specify. For new Redis keys the <code> path </code> must be the root. For existing keys, when the entire <code> path </code> exists, the value that it contains is replaced with the <code> json </code> value. For existing keys, when the <code> path </code> exists, except for the last element, a new child is added with the <code> json </code> value. </p> </details> <details open=""> <summary> <code> value </code> </summary> <p> is value to set at the specified path </p> </details> <h2 id="return-value"> Return value </h2> <p> JSET.MSET returns a simple string reply: <code> OK </code> if executed correctly or <code> error </code> if fails to set the new values </p> <p> For more information about replies, see <a href="/docs/latest/develop/reference/protocol-spec/"> Redis serialization protocol specification </a> . </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Add a new values in multiple keys </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.MSET doc1 $ <span class="s1">'{"a":1}'</span> doc2 $ <span class="s1">'{"f":{"a":2}}'</span> doc3 $ <span class="s1">'{"f1":{"a":0},"f2":{"a":0}}'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.MSET doc1 $ <span class="s1">'{"a":2}'</span> doc2 $.f.a <span class="s1">'3'</span> doc3 $ <span class="s1">'{"f1":{"a":1},"f2":{"a":2}}'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc1 $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"a\":2}]"</span> </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc2 $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"f\":{\"a\":3}}]"</span> </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc3 </span></span><span class="line"><span class="cl"><span class="s2">"{\"f1\":{\"a\":1},\"f2\":{\"a\":2}}"</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/json.set/"> <code> JSON.SET </code> </a> | <a href="/docs/latest/commands/json.mget/"> <code> JSON.MGET </code> </a> | <a href="/docs/latest/commands/json.get/"> <code> JSON.GET </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <ul> <li> <a href="/docs/latest/develop/data-types/json/"> RedisJSON </a> </li> <li> <a href="/docs/latest/develop/interact/search-and-query/indexing/"> Index and search JSON documents </a> </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/json.mset/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/kubernetes/recommendations/.html
<section class="prose w-full py-12 max-w-none"> <h1> Configuration recommendations </h1> <p class="text-lg -mt-5 mb-10"> Settings and configuration recommendations for your Redis Enterprise deployment. </p> <p> This section contains recommended settings and configuration for your Redis Enterprise for Kubernetes deployment. </p> <nav> <a href="/docs/latest/operate/kubernetes/recommendations/node-resources/"> Manage node resources </a> <p> Recommendations on managing node resources and setting eviction thresholds with Redis Enterprise for Kubernetes. </p> <a href="/docs/latest/operate/kubernetes/recommendations/persistent-volumes/"> Use persistent volumes in Redis Enterprise clusters </a> <p> This section covers details about how persistent volumes are sized and specified for Redis Enterprise cluster deployments. </p> <a href="/docs/latest/operate/kubernetes/recommendations/sizing-on-kubernetes/"> Size and scale a Redis Enterprise cluster deployment on Kubernetes </a> <p> This section provides information about sizing and scaling Redis Enterprise in a Kubernetes deployment. </p> <a href="/docs/latest/operate/kubernetes/recommendations/node-selection/"> Control node selection </a> <p> This section provides information about how Redis Enterprise cluster pods can be scheduled to only be placed on specific nodes or node pools. </p> <a href="/docs/latest/operate/kubernetes/recommendations/pod-stability/"> Manage pod stability </a> <p> This section provides information about how you can use quality of service, priority class, eviction thresholds and resource monitoring to maintain cluster node pod stability. </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/kubernetes/recommendations/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/security/encryption/tls/.html
<section class="prose w-full py-12 max-w-none"> <h1> Transport Layer Security (TLS) </h1> <p class="text-lg -mt-5 mb-10"> An overview of Transport Layer Security (TLS). </p> <p> <a href="https://en.wikipedia.org/wiki/Transport_Layer_Security"> Transport Layer Security (TLS) </a> , a successor to SSL, ensures the privacy of data sent between applications and Redis databases. TLS also secures connections between Redis Enterprise Software nodes. </p> <p> You can <a href="/docs/latest/operate/rs/security/encryption/tls/enable-tls/"> use TLS authentication </a> for the following types of communication: </p> <ul> <li> Communication from clients (applications) to your database </li> <li> Communication from your database to other clusters for replication using <a href="/docs/latest/operate/rs/databases/import-export/replica-of/"> Replica Of </a> </li> <li> Communication to and from your database to other clusters for synchronization using <a href="/docs/latest/operate/rs/databases/active-active/"> Active-Active </a> </li> </ul> <h2 id="protocols-and-ciphers"> Protocols and ciphers </h2> <p> TLS protocols and ciphers define the overall suite of algorithms that clients are able to connect to the servers with. </p> <p> You can change the <a href="/docs/latest/operate/rs/security/encryption/tls/tls-protocols/"> TLS protocols </a> and <a href="/docs/latest/operate/rs/security/encryption/tls/ciphers/"> ciphers </a> to improve the security of your Redis Enterprise cluster and databases. The default settings are in line with industry best practices, but you can customize them to match the security policy of your organization. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/security/encryption/tls/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/security/access-control/.html
<section class="prose w-full py-12 max-w-none"> <h1> Access control </h1> <p class="text-lg -mt-5 mb-10"> An overview of access control in Redis Enterprise Software. </p> <p> Redis Enterprise Software lets you use role-based access control (RBAC) to manage users' access privileges. RBAC requires you to do the following: </p> <ol> <li> <p> Create roles and define each role's access privileges. </p> </li> <li> <p> Create users and assign roles to them. The assigned role determines the user's access privileges. </p> </li> </ol> <h2 id="cluster-access-versus-database-access"> Cluster access versus database access </h2> <p> Redis Enterprise allows two separate paths of access: </p> <ul> <li> <p> <strong> Cluster access </strong> allows performing management-related actions, such as creating databases and viewing statistics. </p> </li> <li> <p> <strong> Database access </strong> allows performing data-related actions, like reading and writing data in a database. </p> </li> </ul> <p> You can grant cluster access, database access, or both to each role. These roles let you differentiate between users who can access databases and users who can access cluster management, according to your organization's security needs. </p> <p> The following diagram shows three different options for roles and users: </p> <a href="/docs/latest/images/rs/rbac-diagram.png" sdata-lightbox="/images/rs/rbac-diagram.png"> <img alt="Role-based access control diagram." src="/docs/latest/images/rs/rbac-diagram.png"/> </a> <ul> <li> <p> Role A was created with permission to access the cluster and perform management-related actions. Because user A was assigned role A, they can access the cluster but cannot access databases. </p> </li> <li> <p> Role B was created with permission to access one or more databases and perform data-related actions. Because user B was assigned role B, they cannot access the cluster but can access databases. </p> </li> <li> <p> Role C was created with cluster access and database access permissions. Because user C was assigned role C, they can access the cluster and databases. </p> </li> </ul> <h2 id="default-database-access"> Default database access </h2> <p> When you create a database, <a href="/docs/latest/operate/rs/7.4/security/access-control/manage-users/default-user/"> default user access </a> is enabled automatically. </p> <p> If you set up role-based access controls for your database and don't require compatibility with versions earlier than Redis 6, you can <a href="/docs/latest/operate/rs/7.4/security/access-control/manage-users/default-user/"> deactivate the default user </a> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> Before you <a href="/docs/latest/operate/rs/7.4/security/access-control/manage-users/default-user/#deactivate-default-user"> deactivate default user access </a> , make sure the role associated with the database is <a href="/docs/latest/operate/rs/7.4/security/access-control/create-users/#assign-roles-to-users"> assigned to a user </a> . Otherwise, the database will be inaccessible. </div> </div> <h2 id="more-info"> More info </h2> <nav> <a href="/docs/latest/operate/rs/7.4/security/access-control/create-users/"> Create users </a> <p> Create users and assign access control roles. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/create-cluster-roles/"> Create roles with cluster access only </a> <p> Create roles with cluster access only. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/create-db-roles/"> Create roles with database access only </a> <p> Create roles with database access only. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/create-combined-roles/"> Create roles with combined access </a> <p> Create roles with both cluster and database access. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/redis-acl-overview/"> Overview of Redis ACLs in Redis Enterprise Software </a> <p> An overview of Redis ACLs, syntax, and ACL command support in Redis Enterprise Software. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/manage-users/"> Manage user security </a> <p> Manage user account security settings. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/manage-passwords/"> Set password policies </a> <p> Set password policies. </p> <a href="/docs/latest/operate/rs/7.4/security/access-control/ldap/"> LDAP authentication </a> <p> Describes how Redis Enterprise Software integrates LDAP authentication and authorization. Also describes how to enable LDAP for your deployment of Redis Enterprise Software. </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/security/access-control/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/evalsha/.html
<section class="prose w-full py-12"> <h1 class="command-name"> EVALSHA </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">EVALSHA sha1 numkeys [key [key ...]] [arg [arg ...]]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 2.6.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> Depends on the script that is executed. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> <code> @scripting </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Evaluate a script from the server's cache by its SHA1 digest. </p> <p> The server caches scripts by using the <a href="/docs/latest/commands/script-load/"> <code> SCRIPT LOAD </code> </a> command. The command is otherwise identical to <a href="/docs/latest/commands/eval/"> <code> EVAL </code> </a> . </p> <p> Please refer to the <a href="/docs/latest/develop/interact/programmability/"> Redis Programmability </a> and <a href="/docs/latest/develop/interact/programmability/eval-intro/"> Introduction to Eval Scripts </a> for more information about Lua scripts. </p> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> The return value depends on the script that was executed. <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/evalsha/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/amazon-bedrock/set-up-redis/.html
<section class="prose w-full py-12 max-w-none"> <h1> Set up Redis for Bedrock </h1> <p class="text-lg -mt-5 mb-10"> Shows how to set up your Redis database for Amazon Bedrock. </p> <p> You need to set up your Redis Cloud database before you can set it as the vector database in Amazon Bedrock. To do this, you need to: </p> <ol> <li> <a href="#sign-up-create-subscription"> Sign up for Redis Cloud and create a database </a> </li> <li> <a href="#get-certs"> Enable Transport Layer Security (TLS) for the database and save the certificates </a> </li> <li> <a href="#store-secret"> Store database credentials in AWS secrets manager </a> </li> <li> <a href="#create-vector-index"> Create a vector index in your database </a> for Bedrock to use </li> </ol> <p> After you set up the database, you can use the database information to set it as your knowledge base database when you <a href="/docs/latest/integrate/amazon-bedrock/create-knowledge-base/"> create a knowledge base </a> . </p> <h2 id="sign-up-create-subscription"> Sign up and create a database </h2> <p> To set up a Redis Cloud instance for Bedrock, you need to: </p> <ol> <li> <a href="#sign-up"> Sign up for Redis Cloud </a> if you do not already have an account. </li> <li> <a href="#create-sub"> Create a database </a> to use for your Bedrock knowledge base. </li> </ol> <h3 id="sign-up"> Sign up for Redis Cloud using AWS Marketplace </h3> <ol> <li> <p> Select the <a href="https://aws.amazon.com/marketplace/pp/prodview-mwscixe4ujhkq?sr=0-1&amp;ref_=beagle&amp;applicationId=AWSMPContessa"> Redis Cloud </a> AWS marketplace link from Bedrock to be taken to the Redis Cloud plan listing. </p> <a href="/docs/latest/images/rc/aws-marketplace-rc-flexible-plan.png" sdata-lightbox="/images/rc/aws-marketplace-rc-flexible-plan.png"> <img alt="The Redis Cloud listing on AWS Marketplace" src="/docs/latest/images/rc/aws-marketplace-rc-flexible-plan.png"/> </a> </li> <li> <p> Subscribe to Redis Cloud listing, locate the <strong> Set Up Your Account </strong> button, and then select it to begin mapping your Redis Cloud account with your AWS Marketplace account. </p> <a href="/docs/latest/images/rc/aws-marketplace-account-setup-button.png" sdata-lightbox="/images/rc/aws-marketplace-account-setup-button.png"> <img alt="Use the Set Up Your Account button after subscribing to Redis Cloud with your AWS Marketplace account." src="/docs/latest/images/rc/aws-marketplace-account-setup-button.png" width="50%"/> </a> </li> <li> <p> Sign in to the <a href="https://cloud.redis.io"> Redis Cloud console </a> . </p> </li> <li> <p> Select the Redis account to be mapped to your AWS Marketplace account and confirm that your payment method will change and that the connection cannot be undone. </p> <a href="/docs/latest/images/rc/aws-marketplace-map-account-dialog.png" sdata-lightbox="/images/rc/aws-marketplace-map-account-dialog.png"> <img alt="Use the AWS Marketplace dialog to map your Redis Cloud account to your AWS Marketplace account." src="/docs/latest/images/rc/aws-marketplace-map-account-dialog.png" width="80%"/> </a> </li> <li> <p> Use the <strong> Map account </strong> button to confirm your choice. </p> </li> <li> <p> Once your Redis account is mapped to your AWS Marketplace account, a message appears in the upper, left corner of the account panel. </p> <a href="/docs/latest/images/rc/aws-marketplace-billing-badge.png" sdata-lightbox="/images/rc/aws-marketplace-billing-badge.png"> <img alt="The AWS Marketplace badge appears when your Redis Cloud account is mapped to an AWS Marketplace account." src="/docs/latest/images/rc/aws-marketplace-billing-badge.png" width="150px"/> </a> <p> In addition, AWS Marketplace is reported as the selected payment method. </p> </li> </ol> <h3 id="create-sub"> Create a database </h3> <ol> <li> <p> In the <a href="https://cloud.redis.io/"> Redis Cloud console </a> , select <strong> New database </strong> . </p> <a href="/docs/latest/images/rc/button-database-new.png" sdata-lightbox="/images/rc/button-database-new.png"> <img alt="The New Database button creates a new database." src="/docs/latest/images/rc/button-database-new.png" width="120px"/> </a> </li> <li> <p> When the <strong> New database </strong> page appears, select <strong> Vector search </strong> from the use case panel. </p> <a href="/docs/latest/images/rc/create-database-redis-use-cases.png" sdata-lightbox="/images/rc/create-database-redis-use-cases.png"> <img alt="The Redis Use case panel" src="/docs/latest/images/rc/create-database-redis-use-cases.png"/> </a> </li> <li> <p> Select <strong> Pro </strong> to create a Pro plan. </p> <a href="/docs/latest/images/rc/create-database-subscription-pro-new.png" sdata-lightbox="/images/rc/create-database-subscription-pro-new.png"> <img alt="The Subscription selection panel with Pro selected." src="/docs/latest/images/rc/create-database-subscription-pro-new.png"/> </a> </li> <li> <p> Select <strong> Amazon Web Services </strong> as the cloud vendor, select a region, and enter a name for your subscription. </p> <a href="/docs/latest/images/rc/subscription-new-flexible-setup-general.png" sdata-lightbox="/images/rc/subscription-new-flexible-setup-general.png"> <img alt="The General settings of the Setup tab." src="/docs/latest/images/rc/subscription-new-flexible-setup-general.png" width="75%"/> </a> </li> <li> <p> In the <strong> Version </strong> section, select <strong> Redis 7.2 </strong> or <strong> Redis 7.4 </strong> . </p> <a href="/docs/latest/images/rc/subscription-new-flexible-version-section.png" sdata-lightbox="/images/rc/subscription-new-flexible-version-section.png"> <img alt="Version selection between Redis 6.2, 7.2, and 7.4" src="/docs/latest/images/rc/subscription-new-flexible-version-section.png"/> </a> </li> <li> <p> In the <strong> Advanced options </strong> section, select Multi-AZ to ensure <a href="/docs/latest/operate/rc/databases/configuration/high-availability/"> high-availability </a> . </p> <a href="/docs/latest/images/rc/subscription-new-flexible-advanced-multi-az.png" sdata-lightbox="/images/rc/subscription-new-flexible-advanced-multi-az.png"> <img alt="The Multi-AZ toggle set to on." src="/docs/latest/images/rc/subscription-new-flexible-advanced-multi-az.png" width="75%"/> </a> </li> <li> <p> When finished, select <strong> Continue </strong> . </p> <a href="/docs/latest/images/rc/button-subscription-continue.png" sdata-lightbox="/images/rc/button-subscription-continue.png"> <img alt="Select the Continue button to continue to the next step." src="/docs/latest/images/rc/button-subscription-continue.png" width="100px"/> </a> </li> <li> <p> The <strong> Sizing </strong> tab helps you specify the database requirements for your subscription. </p> <a href="/docs/latest/images/rc/subscription-new-flexible-sizing-tab.png" sdata-lightbox="/images/rc/subscription-new-flexible-sizing-tab.png"> <img alt="The Sizing tab when creating a new Flexible subscription." src="/docs/latest/images/rc/subscription-new-flexible-sizing-tab.png" width="75%"/> </a> <p> Select the <strong> Add </strong> button to create a database. </p> <a href="/docs/latest/images/rc/icon-add-database.png" sdata-lightbox="/images/rc/icon-add-database.png"> <img alt="Use the Add button to define a new database for your subscription." src="/docs/latest/images/rc/icon-add-database.png" width="30px"/> </a> </li> <li> <p> In the <strong> New Database </strong> dialog, name your database. </p> <a href="/docs/latest/images/rc/flexible-add-database-basic.png" sdata-lightbox="/images/rc/flexible-add-database-basic.png"> <img alt="The New Database dialog with basic settings." src="/docs/latest/images/rc/flexible-add-database-basic.png" width="75%"/> </a> <p> We selected <strong> Search and query </strong> and <strong> JSON </strong> for you already. <strong> Search and query </strong> enables vector database features for your database. You can remove <strong> JSON </strong> if you want. </p> </li> <li> <p> Set the Memory limit of your database based on the amount of data that Bedrock will pull from your Simple Storage Service (S3) <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/creating-buckets-s3.html"> bucket </a> . See <a href="https://aws.amazon.com/blogs/storage/find-out-the-size-of-your-amazon-s3-buckets/"> Find out the size of your S3 buckets </a> to find out how much knowledge base data is stored in your S3 bucket and pick the closest size, rounded up, from the table below. </p> <table> <thead> <tr> <th> Total Size of Documents in S3 </th> <th> Database size without replication </th> <th> Database size with replication </th> </tr> </thead> <tbody> <tr> <td> 10,000 kb </td> <td> 135 Mb </td> <td> 270 Mb </td> </tr> <tr> <td> 100,000 kb </td> <td> 1.35 Gb </td> <td> 2.7 Gb </td> </tr> <tr> <td> 1,000,000 kb </td> <td> 13.5 Gb </td> <td> 27 Gb </td> </tr> <tr> <td> 10,000,000 kb </td> <td> 135 Gb </td> <td> 270 Gb </td> </tr> </tbody> </table> <p> For more information on sizing, see the <a href="https://redis.io/blog/amazon-bedrock-integration-with-redis-enterprise/#right-size-your-database-for-amazon-bedrock"> Bedrock integration blog post </a> . </p> </li> <li> <p> When finished, select <strong> Save database </strong> to create your database. </p> <a href="/docs/latest/images/rc/button-database-save.png" sdata-lightbox="/images/rc/button-database-save.png"> <img alt="Select the Save Database button to define your new database." src="/docs/latest/images/rc/button-database-save.png" width="140px"/> </a> </li> <li> <p> Select <strong> Continue </strong> to move to the <strong> Review and Create </strong> tab. </p> </li> <li> <p> Review your subscription. You will not need to enter a payment method, as it's automatically assigned to your AWS Marketplace account. </p> </li> <li> <p> Select <strong> Confirm &amp; pay </strong> to create your new database. </p> <a href="/docs/latest/images/rc/button-create-db-confirm-pay.png" sdata-lightbox="/images/rc/button-create-db-confirm-pay.png"> <img alt="Select Confirm &amp; pay to create your new database." src="/docs/latest/images/rc/button-create-db-confirm-pay.png" width="140px"/> </a> <p> Note that databases are created in the background. While they are provisioning, you aren't allowed to make changes. (The process generally takes 10-15 minutes.) </p> <p> Use the <strong> Databases list </strong> to check the status of your subscription. You will also receive an email when your database is ready to use. </p> </li> </ol> <h2 id="get-certs"> Enable TLS and get certificates </h2> <p> For your database to be fully secure, you must enable <a href="/docs/latest/operate/rc/security/database-security/tls-ssl/#enable-tls"> Transport Layer Security (TLS) </a> for your database with client authentication. </p> <ol> <li> <p> Select <strong> Databases </strong> from the <a href="https://cloud.redis.io/"> Redis Cloud console </a> menu and then select your database from the list. </p> </li> <li> <p> From the database's <strong> Configuration </strong> screen, select the <strong> Edit database </strong> button: </p> <a href="/docs/latest/images/rc/button-database-edit.png" sdata-lightbox="/images/rc/button-database-edit.png"> <img alt="The Edit database button lets you change selected database properties." src="/docs/latest/images/rc/button-database-edit.png" width="140px"/> </a> </li> <li> <p> In the <strong> Security </strong> section, use the <strong> Transport layer security (TLS) </strong> toggle to enable TLS: </p> <a href="/docs/latest/images/rc/database-details-configuration-tab-security-tls-toggle.png" sdata-lightbox="/images/rc/database-details-configuration-tab-security-tls-toggle.png"> <img alt="Use the Transport Layer Security toggle to enable TLS." src="/docs/latest/images/rc/database-details-configuration-tab-security-tls-toggle.png" width="200px"/> </a> </li> <li> <p> Select <strong> Download server certificate </strong> to download the Redis Cloud certificate bundle <code> redis_ca.pem </code> : </p> <a href="/docs/latest/images/rc/button-database-config-security-server-ca-download.png" sdata-lightbox="/images/rc/button-database-config-security-server-ca-download.png"> <img alt="Use the Download server certificate button to download the Redis Cloud CA certificates." src="/docs/latest/images/rc/button-database-config-security-server-ca-download.png" width="250px"/> </a> </li> <li> <p> Select the <strong> Mutual TLS (require client authentication) </strong> checkbox to require client authentication. </p> </li> <li> <p> Select <strong> Add client certificate </strong> to add a certificate. </p> <a href="/docs/latest/images/rc/mtls-add-client-certificate.png" sdata-lightbox="/images/rc/mtls-add-client-certificate.png"> <img alt="The Add client certificate button." src="/docs/latest/images/rc/mtls-add-client-certificate.png" width="200px"/> </a> </li> <li> <p> Either provide an <a href="https://en.wikipedia.org/wiki/X.509"> X.509 client certificate </a> or chain in PEM format for your client or select <strong> Generate </strong> to create one: </p> <a href="/docs/latest/images/rc/database-details-configuration-tab-security-tls-client-auth-certificate.png" sdata-lightbox="/images/rc/database-details-configuration-tab-security-tls-client-auth-certificate.png"> <img alt="Provide or generate a certificate for Mutual TLS." src="/docs/latest/images/rc/database-details-configuration-tab-security-tls-client-auth-certificate.png"/> </a> <ul> <li> <p> If you generate your certificate from the Redis Cloud console, a <strong> Download certificate </strong> button will appear after it is generated. Select it to download the certificate. </p> <a href="/docs/latest/images/rc/mtls-download-certificate.png" sdata-lightbox="/images/rc/mtls-download-certificate.png"> <img alt="The Download certificate button." src="/docs/latest/images/rc/mtls-download-certificate.png"/> </a> <p> The download contains: </p> <ul> <li> <p> <code> redis-db-&lt;database_id&gt;.crt </code> – the certificate's public key. </p> </li> <li> <p> <code> redis-db-&lt;database_id&gt;.key </code> – the certificate's private key. </p> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> You must download the certificate using the button at this point. After your changes have been applied, the full bundle of public and private keys will no longer be available for download. </div> </div> </li> <li> <p> If you provide a client certificate, you will see the certificate details before you save your changes. </p> <a href="/docs/latest/images/rc/mtls-certificate-details.png" sdata-lightbox="/images/rc/mtls-certificate-details.png"> <img alt="The Download certificate button." src="/docs/latest/images/rc/mtls-certificate-details.png"/> </a> </li> </ul> </li> <li> <p> To apply your changes and enable TLS, select the <strong> Save database </strong> button: </p> <a href="/docs/latest/images/rc/button-database-save.png" sdata-lightbox="/images/rc/button-database-save.png"> <img alt="Use the Save database button to save database changes." src="/docs/latest/images/rc/button-database-save.png" width="140px"/> </a> </li> </ol> <h2 id="store-secret"> Store database credentials in AWS secrets manager </h2> <p> In the <a href="https://console.aws.amazon.com/"> AWS Management Console </a> , use the <strong> Services </strong> menu to locate and select <strong> Security, Identity, and Compliance </strong> &gt; <strong> Secrets Manager </strong> . <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/create_secret.html"> Create a secret </a> of type <strong> Other type of secret </strong> with the following key/value fields: </p> <ul> <li> <code> username </code> : Database username </li> <li> <code> password </code> : Database password </li> <li> <code> serverCertificate </code> : Contents of the <a href="/docs/latest/operate/rc/security/database-security/tls-ssl/#download-certificates"> server certificate </a> ( <code> redis_ca.pem </code> ) </li> <li> <code> clientCertificate </code> : Contents of the client certificate ( <code> redis_user.crt </code> ) </li> <li> <code> clientPrivateKey </code> : Contents of the client private key ( <code> redis_user_private.key </code> ) </li> </ul> <p> After you store this secret, you can view and copy the <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/reference_iam-permissions.html#iam-resources"> Amazon Resource Name (ARN) </a> of your secret on the secret details page. </p> <h2 id="create-vector-index"> Create a vector index in your database </h2> <p> After your Redis Cloud database is set up, create a search index with a vector field using <a href="/docs/latest/commands/ft.create"> FT.CREATE </a> as your knowledge base for Amazon Bedrock. You can accomplish this using <strong> Redis Insight </strong> or <code> redis-cli </code> . </p> <h3 id="redis-insight"> Redis Insight </h3> <p> <a href="/docs/latest/develop/tools/insight/"> Redis Insight </a> is a free Redis GUI that allows you to visualize and optimize your data in Redis. </p> <p> To create your vector index in Redis Insight: </p> <ol> <li> <p> <a href="https://redis.io/insight/"> Download and install Redis Insight </a> if you don't have it already. </p> </li> <li> <p> In the <a href="https://cloud.redis.io/"> Redis Cloud console </a> , in your database's <strong> Configuration </strong> tab, select the <strong> Connect </strong> button next to your database to open the connection wizard. </p> <a href="/docs/latest/images/rc/connection-wizard-button.png#no-click" sdata-lightbox="/images/rc/connection-wizard-button.png#no-click"> <img alt="Connect button." src="/docs/latest/images/rc/connection-wizard-button.png#no-click"/> </a> </li> <li> <p> In the connection wizard, under <strong> Redis Insight Desktop </strong> , select <strong> Public Endpoint </strong> . Select <strong> Open with Redis Insight </strong> to connect to the database with Redis Insight. </p> </li> <li> <p> Select <strong> Use TLS </strong> . In the <strong> CA Certificate </strong> section, select <strong> Add new CA certificate </strong> . Give the certificate a name in the <strong> Name </strong> field, and enter the contents of <code> redis_ca.pem </code> into the <strong> Certificate </strong> field. </p> <a href="/docs/latest/images/rc/ri-bedrock-add-ca-cert.png" sdata-lightbox="/images/rc/ri-bedrock-add-ca-cert.png"> <img alt="The Redis Insight Add CA Certificate section." src="/docs/latest/images/rc/ri-bedrock-add-ca-cert.png" width="80%"/> </a> </li> <li> <p> Select <strong> Requires TLS Client Authentication </strong> . In the <strong> Client Certificate </strong> section, select <strong> Add new certificate </strong> . Give the certificate a name in the <strong> Name </strong> field. Enter the contents of <code> redis_user.crt </code> into the <strong> Certificate </strong> field, and the contents of <code> redis_user_private.key </code> into the <strong> Private Key </strong> field. </p> <a href="/docs/latest/images/rc/ri-bedrock-add-client-cert.png" sdata-lightbox="/images/rc/ri-bedrock-add-client-cert.png"> <img alt="The Redis Insight Add Client Certificate section." src="/docs/latest/images/rc/ri-bedrock-add-client-cert.png" width="80%"/> </a> </li> <li> <p> Select <strong> Add Redis Database </strong> to connect to the database. </p> </li> <li> <p> Select your database alias to connect to your database. Select the <strong> Workbench </strong> icon to go to the workbench. </p> <a href="/docs/latest/images/rc/ri-bedrock-workbench.png" sdata-lightbox="/images/rc/ri-bedrock-workbench.png"> <img alt="The Redis Insight workbench icon." src="/docs/latest/images/rc/ri-bedrock-workbench.png" width="50px"/> </a> </li> <li> <p> Enter the <a href="/docs/latest/commands/ft.create"> FT.CREATE </a> command to create an index. </p> <div class="highlight"> <pre class="chroma"><code class="language-text" data-lang="text"><span class="line"><span class="cl">FT.CREATE &lt;index_name&gt; </span></span><span class="line"><span class="cl"> ON HASH </span></span><span class="line"><span class="cl"> SCHEMA </span></span><span class="line"><span class="cl"> "&lt;text_field&gt;" TEXT </span></span><span class="line"><span class="cl"> "&lt;metadata_field&gt;" TEXT </span></span><span class="line"><span class="cl"> "&lt;vector_field&gt;" VECTOR FLAT </span></span><span class="line"><span class="cl"> 6 </span></span><span class="line"><span class="cl"> "TYPE" "FLOAT32" </span></span><span class="line"><span class="cl"> "DIM" 1536 </span></span><span class="line"><span class="cl"> "DISTANCE_METRIC" "COSINE" </span></span></code></pre> </div> <p> Replace the following fields: </p> <ul> <li> <code> &lt;index_name&gt; </code> with the vector index name </li> <li> <code> &lt;text_field&gt; </code> with the text field name </li> <li> <code> &lt;metadata_field&gt; </code> with the metadata field name </li> <li> <code> &lt;vector_field&gt; </code> with the vector field name </li> </ul> </li> <li> <p> Select <strong> Run </strong> to create the index. </p> <a href="/docs/latest/images/rc/ri-bedrock-run-button.png" sdata-lightbox="/images/rc/ri-bedrock-run-button.png"> <img alt="The Redis Insight run button." src="/docs/latest/images/rc/ri-bedrock-run-button.png" width="50px"/> </a> </li> </ol> <h3 id="redis-cli"> <code> redis-cli </code> </h3> <p> The <a href="/docs/latest/develop/tools/cli/"> <code> redis-cli </code> </a> command-line utility lets you connect and run Redis commands directly from the command line. To use <code> redis-cli </code> , you can <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/install/"> install Redis </a> . </p> <p> Public endpoint and port details are available from the <strong> Databases </strong> list or the database's <strong> Configuration </strong> screen. Select <strong> Connect </strong> to view how to connect to your database with <code> redis-cli </code> . </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">redis-cli -h &lt;endpoint&gt; -p &lt;port&gt; --tls --cacert redis_ca.pem <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> --cert redis_user.crt --key redis_user_private.key </span></span></code></pre> </div> <p> After you are connected with <code> redis-cli </code> , create an index using <a href="/docs/latest/commands/ft.create"> FT.CREATE </a> . </p> <div class="highlight"> <pre class="chroma"><code class="language-text" data-lang="text"><span class="line"><span class="cl">FT.CREATE &lt;index_name&gt; </span></span><span class="line"><span class="cl"> ON HASH </span></span><span class="line"><span class="cl"> SCHEMA </span></span><span class="line"><span class="cl"> "&lt;text_field&gt;" TEXT </span></span><span class="line"><span class="cl"> "&lt;metadata_field&gt;" TEXT </span></span><span class="line"><span class="cl"> "&lt;vector_field&gt;" VECTOR FLAT </span></span><span class="line"><span class="cl"> 6 </span></span><span class="line"><span class="cl"> "TYPE" "FLOAT32" </span></span><span class="line"><span class="cl"> "DIM" 1536 </span></span><span class="line"><span class="cl"> "DISTANCE_METRIC" "COSINE" </span></span></code></pre> </div> <p> Replace the following fields: </p> <ul> <li> <code> &lt;index_name&gt; </code> with the vector index name </li> <li> <code> &lt;text_field&gt; </code> with the text field name </li> <li> <code> &lt;metadata_field&gt; </code> with the metadata field name </li> <li> <code> &lt;vector_field&gt; </code> with the vector field name </li> </ul> <h2 id="next-steps"> Next steps </h2> <p> After your Redis database is set up, you can use it to <a href="/docs/latest/integrate/amazon-bedrock/create-knowledge-base/"> create a knowledge base </a> in Amazon Bedrock. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/amazon-bedrock/set-up-redis/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/crdb/database_config/.html
<section class="prose w-full py-12 max-w-none"> <h1> CRDB database config object </h1> <p class="text-lg -mt-5 mb-10"> An object that represents the database configuration </p> <p> An object that represents the database configuration. </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> aof_policy </td> <td> string </td> <td> Policy for Append-Only File data persistence </td> </tr> <tr> <td> authentication_admin_pass </td> <td> string </td> <td> Administrative databases access token </td> </tr> <tr> <td> authentication_redis_pass </td> <td> string </td> <td> Redis AUTH password (deprecated as of Redis Enterprise v7.2, replaced with multiple passwords feature in version 6.0.X) </td> </tr> <tr> <td> bigstore </td> <td> boolean </td> <td> Database driver is Auto Tiering </td> </tr> <tr> <td> bigstore_ram_size </td> <td> integer </td> <td> Memory size of RAM size </td> </tr> <tr> <td> data_persistence </td> <td> string </td> <td> Database on-disk persistence </td> </tr> <tr> <td> enforce_client_authentication </td> <td> <strong> 'enabled' </strong> <br/> 'disabled' </td> <td> Require authentication of client certificates for SSL connections to the database. If enabled, a certificate should be provided in either <span class="break-all"> <code> authentication_ssl_client_certs </code> </span> or <span class="break-all"> <code> authentication_ssl_crdt_certs </code> </span> </td> </tr> <tr> <td> max_aof_file_size </td> <td> integer </td> <td> Hint for maximum AOF file size </td> </tr> <tr> <td> max_aof_load_time </td> <td> integer </td> <td> Hint for maximum AOF reload time </td> </tr> <tr> <td> memory_size </td> <td> integer </td> <td> Database memory size limit, in bytes </td> </tr> <tr> <td> oss_cluster </td> <td> boolean </td> <td> Enables OSS Cluster mode </td> </tr> <tr> <td> oss_cluster_api_preferred_ip_type </td> <td> string </td> <td> Indicates preferred IP type in OSS cluster API: internal/external </td> </tr> <tr> <td> oss_sharding </td> <td> boolean </td> <td> An alternative to shard_key_regex for using the common case of the OSS shard hashing policy </td> </tr> <tr> <td> port </td> <td> integer </td> <td> TCP port for database access </td> </tr> <tr> <td> proxy_policy </td> <td> string </td> <td> The policy used for proxy binding to the endpoint </td> </tr> <tr> <td> rack_aware </td> <td> boolean </td> <td> Require the database to be always replicated across multiple racks </td> </tr> <tr> <td> replication </td> <td> boolean </td> <td> Database replication </td> </tr> <tr> <td> sharding </td> <td> boolean (default:Β false) </td> <td> Cluster mode (server-side sharding). When true, shard hashing rules must be provided by either <code> oss_sharding </code> or <code> shard_key_regex </code> </td> </tr> <tr> <td> shard_key_regex </td> <td> <code> [{ "regex": string }, ...] </code> </td> <td> Custom keyname-based sharding rules (required if sharding is enabled) <br/> <br/> To use the default rules you should set the value to: <br/> <code> [{ β€œregex”: β€œ.*\\{(?&lt; tag &gt;.*)\\}.*” }, { β€œregex”: β€œ(?&lt; tag &gt;.*)” }] </code> </td> </tr> <tr> <td> shards_count </td> <td> integer </td> <td> Number of database shards </td> </tr> <tr> <td> shards_placement </td> <td> string </td> <td> Control the density of shards: should they reside on as few or as many nodes as possible </td> </tr> <tr> <td> snapshot_policy </td> <td> array of <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/snapshot_policy/"> snapshot_policy </a> objects </td> <td> Policy for snapshot-based data persistence (required) </td> </tr> <tr> <td> tls_mode </td> <td> string </td> <td> Encrypt communication </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/crdb/database_config/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/references/compatibility/commands/connection/.html
<section class="prose w-full py-12 max-w-none"> <h1> Connection management commands compatibility </h1> <p class="text-lg -mt-5 mb-10"> Connection management commands compatibility. </p> <p> The following tables show which Redis Community Edition <a href="/docs/latest/commands/?group=connection"> connection management commands </a> are compatible with standard and Active-Active databases in Redis Enterprise Software and Redis Cloud. </p> <table> <thead> <tr> <th style="text-align:left"> Command </th> <th style="text-align:left"> Redis <br/> Enterprise </th> <th style="text-align:left"> Redis <br/> Cloud </th> <th style="text-align:left"> Notes </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/auth/"> AUTH </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-caching/"> CLIENT CACHING </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-getname/"> CLIENT GETNAME </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-getredir/"> CLIENT GETREDIR </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-id/"> CLIENT ID </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> Because Redis Enterprise clustering allows <a href="/docs/latest/operate/rs/7.4/databases/configure/proxy-policy/"> multiple active proxies </a> , <code> CLIENT ID </code> cannot guarantee incremental IDs between clients that connect to different nodes under multi proxy policies. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-info/"> CLIENT INFO </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-kill/"> CLIENT KILL </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-list/"> CLIENT LIST </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-no-evict/"> CLIENT NO-EVICT </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-no-touch/"> CLIENT <nobr> NO-TOUCH </nobr> </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-pause/"> CLIENT PAUSE </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-reply/"> CLIENT REPLY </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-setinfo/"> CLIENT SETINFO </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-setname/"> CLIENT SETNAME </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-tracking/"> CLIENT TRACKING </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-trackinginfo/"> CLIENT TRACKINGINFO </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-unblock/"> CLIENT UNBLOCK </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/client-unpause/"> CLIENT UNPAUSE </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/echo/"> ECHO </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/hello/"> HELLO </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/ping/"> PING </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/quit/"> QUIT </a> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… Standard </span> <br/> <span title="Supported"> <nobr> βœ… Active-Active </nobr> </span> </td> <td style="text-align:left"> Deprecated as of Redis v7.2.0. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/reset/"> RESET </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/commands/select/"> SELECT </a> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ Standard </span> <br/> <span title="Not supported"> <nobr> ❌ Active-Active </nobr> </span> </td> <td style="text-align:left"> Redis Enterprise does not support shared databases due to potential negative performance impacts and blocks any related commands. The <code> SELECT </code> command is supported solely for compatibility with Redis Community Edition but does not perform any operations in Redis Enterprise. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/references/compatibility/commands/connection/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/installing-upgrading/install/offline-installation/.html
<section class="prose w-full py-12 max-w-none"> <h1> Offline installation </h1> <p class="text-lg -mt-5 mb-10"> If you install Redis Enterprise Software on a machine with no internet connection, you need to perform two tasks manually. </p> <p> By default, the installation process requires an internet connection to enable installing dependency packages and for <a href="/docs/latest/operate/rs/clusters/configure/sync-clocks/"> synchronizing the operating system clock </a> against an NTP server. </p> <p> If you install Redis Enterprise Software on a machine without an internet connection, you need to perform two tasks manually. </p> <h2 id="install-required-dependency-packages"> Install required dependency packages </h2> <p> When you install Redis Enterprise Software on a machine that is not connected to the internet, the installation process fails and displays an error message informing you it failed to automatically install dependencies. Review the installation steps in the console to see which missing dependencies the process attempted to install. Install all these dependency packages and then run the installation again. </p> <h2 id="set-up-ntp-time-synchronization"> Set up NTP time synchronization </h2> <p> At the end of the installation, the process asks if you want to set up NTP time synchronization. If you choose <code> Yes </code> while you are not connected to the internet, the action fails and displays the appropriate error message, but the installation completes successfully. Despite the successful completion of the installation, you still have to configure all nodes for <a href="/docs/latest/operate/rs/clusters/configure/sync-clocks/"> NTP time synchronization </a> . </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/installing-upgrading/install/offline-installation/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/develop/data-types/probabilistic/top-k/.html
<section class="prose w-full py-12"> <h1> Top-K </h1> <p class="text-lg -mt-5 mb-10"> Top-K is a probabilistic data structure that allows you to find the most frequent items in a data stream. </p> <p> Top K is a probabilistic data structure in Redis Stack used to estimate the <code> K </code> highest-rank elements from a stream. </p> <p> "Highest-rank" in this case means "elements with a highest number or score attached to them", where the score can be a count of how many times the element has appeared in the stream - thus making the data structure perfect for finding the elements with the highest frequency in a stream. One very common application is detecting network anomalies and DDoS attacks where Top K can answer the question: Is there a sudden increase in the flux of requests to the same address or from the same IP? </p> <p> There is, indeed, some overlap with the functionality of Count-Min Sketch, but the two data structures have their differences and should be applied for different use cases. </p> <p> The Redis Stack implementation of Top-K is based on the <a href="https://www.usenix.org/conference/atc18/presentation/gong"> HeavyKeepers </a> algorithm presented by Junzhi Gong et al. It discards some older approaches like "count-all" and "admit-all-count-some" in favour of a " <strong> count-with-exponential-decay </strong> " strategy which is biased against mouse (small) flows and has a limited impact on elephant (large) flows. This implementation uses two data structures in tandem: a hash table that holds the probabilistic counts (much like the Count-Min Sketch), and a min heap that holds the <code> K </code> items with the highest counts. This ensures high accuracy with shorter execution times than previous probabilistic algorithms allowed, while keeping memory utilization to a fraction of what is typically required by a Sorted Set. It has the additional benefit of being able to get real time notifications when elements are added or removed from the Top K list. </p> <h2 id="use-case"> Use case </h2> <p> <strong> Trending hashtags (social media platforms, news distribution networks) </strong> </p> <p> This application answers these questions: </p> <ul> <li> What are the K hashtags people have mentioned the most in the last X hours? </li> <li> What are the K news with highest read/view count today? </li> </ul> <p> Data flow is the incoming social media posts from which you parse out the different hashtags. </p> <p> The <a href="/docs/latest/commands/topk.list/"> <code> TOPK.LIST </code> </a> command has a time complexity of <code> O(K*log(k)) </code> so if <code> K </code> is small, there is no need to keep a separate set or sorted set of all the hashtags. You can query directly from the Top K itself. </p> <h2 id="example"> Example </h2> <p> This example will show you how to track key words used "bike" when shopping online; e.g., "bike store" and "bike handlebars". Proceed as follows. ​ </p> <ul> <li> Use <a href="/docs/latest/commands/topk.reserve/"> <code> TOPK.RESERVE </code> </a> to initialize a top K sketch with specific parameters. Note: the <code> width </code> , <code> depth </code> , and <code> decay_constant </code> parameters can be omitted, as they will be set to the default values 7, 8, and 0.9, respectively, if not present. ​ </li> </ul> <pre tabindex="0"><code>&gt; TOPK.RESERVE key k width depth decay_constant </code></pre> <ul> <li> <p> Use <a href="/docs/latest/commands/topk.add/"> <code> TOPK.ADD </code> </a> to add items to the sketch. As you can see, multiple items can be added at the same time. If an item is returned when adding additional items, it means that item was demoted out of the min heap of the top items, below it will mean the returned item is no longer in the top 5, otherwise <code> nil </code> is returned. This allows dynamic heavy-hitter detection of items being entered or expelled from top K list. ​ In the example below, "pedals" displaces "handlebars", which is returned after "pedals" is added. Also note that the addition of both "store" and "seat" a second time don't return anything, as they're already in the top K. </p> </li> <li> <p> Use <a href="/docs/latest/commands/topk.list/"> <code> TOPK.LIST </code> </a> to list the items entered thus far. ​ </p> </li> <li> <p> Use <a href="/docs/latest/commands/topk.query/"> <code> TOPK.QUERY </code> </a> to see if an item is on the top K list. Just like <a href="/docs/latest/commands/topk.add/"> <code> TOPK.ADD </code> </a> multiple items can be queried at the same time. </p> <div class="codetabs cli group flex justify-start items-center flex-wrap box-border rounded-lg mt-0 mb-0 mx-auto bg-slate-900" id="topk_tutorial-steptopk"> <input checked="" class="radiotab w-0 h-0" data-lang="redis-cli" id="redis-cli_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="redis-cli_topk_tutorial-steptopk" title="Open example"> &gt;_ Redis CLI </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_redis-cli_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-plaintext" data-lang="plaintext"><span class="line hl"><span class="cl">&gt; TOPK.RESERVE bikes:keywords 5 2000 7 0.925 </span></span><span class="line hl"><span class="cl">OK </span></span><span class="line hl"><span class="cl">&gt; TOPK.ADD bikes:keywords store seat handlebars handles pedals tires store seat </span></span><span class="line hl"><span class="cl">1) (nil) </span></span><span class="line hl"><span class="cl">2) (nil) </span></span><span class="line hl"><span class="cl">3) (nil) </span></span><span class="line hl"><span class="cl">4) (nil) </span></span><span class="line hl"><span class="cl">5) (nil) </span></span><span class="line hl"><span class="cl">6) handlebars </span></span><span class="line hl"><span class="cl">7) (nil) </span></span><span class="line hl"><span class="cl">8) (nil) </span></span><span class="line hl"><span class="cl">&gt; TOPK.LIST bikes:keywords </span></span><span class="line hl"><span class="cl">1) store </span></span><span class="line hl"><span class="cl">2) seat </span></span><span class="line hl"><span class="cl">3) pedals </span></span><span class="line hl"><span class="cl">4) tires </span></span><span class="line hl"><span class="cl">5) handles </span></span><span class="line hl"><span class="cl">&gt; TOPK.QUERY bikes:keywords store handlebars </span></span><span class="line hl"><span class="cl">1) (integer) 1 </span></span><span class="line hl"><span class="cl">2) (integer) 0</span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_redis-cli_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <div class="flex-1 text-xs text-white overflow-ellipsis"> Are you tired of using redis-cli? Try Redis Insight - the developer GUI for Redis. </div> <div class="text-right"> <a class="rounded rounded-mx px-2 py-1 flex items-center text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.com/redis-enterprise/redis-insight/" tabindex="1" title="Get Redis Insight"> <svg class="w-4 h-4 mr-1" fill="none" height="14" viewbox="0 0 14 14" width="14" xmlns="http://www.w3.org/2000/svg"> <path d="M2.26236 5.66895L1.21732 6.07172L7.00018 8.65693V7.79842L2.26236 5.66895Z" fill="#fca5a5"> </path> <path d="M2.26236 8.02271L1.21732 8.42548L7.00018 11.0119V10.1516L2.26236 8.02271Z" fill="#fca5a5"> </path> <path d="M1.21732 3.7175L7.00018 6.30392V2.87805L8.66273 2.13423L7.00018 1.49512L1.21732 3.7175Z" fill="#fca5a5"> </path> <path d="M7.00018 2.8781V6.30366L1.21732 3.71724V5.20004L7.00018 7.79705V8.65526L1.21732 6.07217V7.55496L7.00018 10.1553V11.0135L1.21732 8.42376V9.90656H1.18878L7.00018 12.5051L8.66273 11.7613V2.13428L7.00018 2.8781Z" fill="#f87171"> </path> <path d="M9.07336 11.5777L10.7359 10.8338V4.01538L9.07336 4.7592V11.5777Z" fill="#f87171"> </path> <path d="M9.07336 4.75867L10.7359 4.01485L9.07336 3.37573V4.75867Z" fill="#fca5a5"> </path> <path d="M11.1481 10.6497L12.8112 9.90591V5.896L11.1487 6.63982L11.1481 10.6497Z" fill="#f87171"> </path> <path d="M11.1481 6.63954L12.8112 5.89572L11.1481 5.25781V6.63954Z" fill="#fca5a5"> </path> </svg> <span> Get Redis Insight </span> </a> </div> </div> </div> <input class="radiotab w-0 h-0" data-lang="python" id="Python_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="Python_topk_tutorial-steptopk" title="Open example"> Python </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_Python_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-python" data-lang="python"><span class="line"><span class="cl"><span class="s2">""" </span></span></span><span class="line"><span class="cl"><span class="s2">Code samples for Top-K pages: </span></span></span><span class="line"><span class="cl"><span class="s2"> https://redis.io/docs/latest/develop/data-types/probabilistic/top-k/ </span></span></span><span class="line"><span class="cl"><span class="s2">"""</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">redis</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">r</span> <span class="o">=</span> <span class="n">redis</span><span class="o">.</span><span class="n">Redis</span><span class="p">(</span><span class="n">decode_responses</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"><span class="n">res1</span> <span class="o">=</span> <span class="n">r</span><span class="o">.</span><span class="n">topk</span><span class="p">()</span><span class="o">.</span><span class="n">reserve</span><span class="p">(</span><span class="s2">"bikes:keywords"</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">2000</span><span class="p">,</span> <span class="mi">7</span><span class="p">,</span> <span class="mf">0.925</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">res1</span><span class="p">)</span> <span class="c1"># &gt;&gt;&gt; True</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"><span class="n">res2</span> <span class="o">=</span> <span class="n">r</span><span class="o">.</span><span class="n">topk</span><span class="p">()</span><span class="o">.</span><span class="n">add</span><span class="p">(</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"bikes:keywords"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"seat"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"handlebars"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"handles"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"pedals"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"tires"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s2">"seat"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"><span class="p">)</span> </span></span><span class="line hl"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">res2</span><span class="p">)</span> <span class="c1"># &gt;&gt;&gt; [None, None, None, None, None, 'handlebars', None, None]</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"><span class="n">res3</span> <span class="o">=</span> <span class="n">r</span><span class="o">.</span><span class="n">topk</span><span class="p">()</span><span class="o">.</span><span class="n">list</span><span class="p">(</span><span class="s2">"bikes:keywords"</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">res3</span><span class="p">)</span> <span class="c1"># &gt;&gt;&gt; ['store', 'seat', 'pedals', 'tires', 'handles']</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"><span class="n">res4</span> <span class="o">=</span> <span class="n">r</span><span class="o">.</span><span class="n">topk</span><span class="p">()</span><span class="o">.</span><span class="n">query</span><span class="p">(</span><span class="s2">"bikes:keywords"</span><span class="p">,</span> <span class="s2">"store"</span><span class="p">,</span> <span class="s2">"handlebars"</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">res4</span><span class="p">)</span> <span class="c1"># &gt;&gt;&gt; [1, 0]</span> </span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_Python_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <button aria-controls="panel_Python_topk_tutorial-steptopk" class="visibility-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-2 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="toggleVisibleLines(this)" tabindex="1" title="Toggle visibility"> <svg class="hidden" fill="currentColor" id="visibility-off" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="m31.45 27.05-2.2-2.2q1.3-3.55-1.35-5.9-2.65-2.35-5.75-1.2l-2.2-2.2q.85-.55 1.9-.8 1.05-.25 2.15-.25 3.55 0 6.025 2.475Q32.5 19.45 32.5 23q0 1.1-.275 2.175-.275 1.075-.775 1.875Zm6.45 6.45-2-2q2.45-1.8 4.275-4.025Q42 25.25 42.85 23q-2.5-5.55-7.5-8.775Q30.35 11 24.5 11q-2.1 0-4.3.4-2.2.4-3.45.95L14.45 10q1.75-.8 4.475-1.4Q21.65 8 24.25 8q7.15 0 13.075 4.075Q43.25 16.15 46 23q-1.3 3.2-3.35 5.85-2.05 2.65-4.75 4.65Zm2.9 11.3-8.4-8.25q-1.75.7-3.95 1.075T24 38q-7.3 0-13.25-4.075T2 23q1-2.6 2.775-5.075T9.1 13.2L2.8 6.9l2.1-2.15L42.75 42.6ZM11.15 15.3q-1.85 1.35-3.575 3.55Q5.85 21.05 5.1 23q2.55 5.55 7.675 8.775Q17.9 35 24.4 35q1.65 0 3.25-.2t2.4-.6l-3.2-3.2q-.55.25-1.35.375T24 31.5q-3.5 0-6-2.45T15.5 23q0-.75.125-1.5T16 20.15Zm15.25 7.1Zm-5.8 2.9Z"> </path> </svg> <svg fill="currentColor" id="visibility-on" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24 31.5q3.55 0 6.025-2.475Q32.5 26.55 32.5 23q0-3.55-2.475-6.025Q27.55 14.5 24 14.5q-3.55 0-6.025 2.475Q15.5 19.45 15.5 23q0 3.55 2.475 6.025Q20.45 31.5 24 31.5Zm0-2.9q-2.35 0-3.975-1.625T18.4 23q0-2.35 1.625-3.975T24 17.4q2.35 0 3.975 1.625T29.6 23q0 2.35-1.625 3.975T24 28.6Zm0 9.4q-7.3 0-13.2-4.15Q4.9 29.7 2 23q2.9-6.7 8.8-10.85Q16.7 8 24 8q7.3 0 13.2 4.15Q43.1 16.3 46 23q-2.9 6.7-8.8 10.85Q31.3 38 24 38Zm0-15Zm0 12q6.05 0 11.125-3.275T42.85 23q-2.65-5.45-7.725-8.725Q30.05 11 24 11t-11.125 3.275Q7.8 17.55 5.1 23q2.7 5.45 7.775 8.725Q17.95 35 24 35Z"> </path> </svg> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <a class="rounded rounded-mx px-3 py-1 text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.io/docs/latest/develop/connect/clients/python/redis-py/" tabindex="1" title="Quick-Start"> Python Quick-Start </a> <div class="w-1/2"> </div> <div class="flex-1 text-right"> <a class="button text-neutral-400 hover:text-slate-100 h-6 w-6 p-1" href="https://github.com/redis/redis-py/tree/master/doctests/dt_topk.py" tabindex="1" title="Improve this code example"> <svg fill="github" height="16" viewbox="0 0 18 16" width="18" xmlns="http://www.w3.org/2000/svg"> <path clip-rule="evenodd" d="M8.99953 1.43397e-06C7.09918 -0.000897921 5.26058 0.674713 3.81295 1.90585C2.36533 3.13699 1.40324 4.84324 1.09896 6.71907C0.794684 8.5949 1.1681 10.5178 2.15233 12.1434C3.13657 13.769 4.66734 14.9912 6.47053 15.591C6.87053 15.664 7.01653 15.417 7.01653 15.205C7.01653 15.015 7.00953 14.512 7.00553 13.845C4.78053 14.328 4.31053 12.772 4.31053 12.772C4.16325 12.2887 3.84837 11.8739 3.42253 11.602C2.69653 11.102 3.47753 11.116 3.47753 11.116C3.73043 11.1515 3.97191 11.2442 4.18365 11.3869C4.39539 11.5297 4.57182 11.7189 4.69953 11.94C4.80755 12.1377 4.95378 12.3119 5.12972 12.4526C5.30567 12.5933 5.50782 12.6976 5.72442 12.7595C5.94103 12.8214 6.16778 12.8396 6.39148 12.813C6.61519 12.7865 6.83139 12.7158 7.02753 12.605C7.06381 12.1992 7.24399 11.8197 7.53553 11.535C5.75953 11.335 3.89153 10.647 3.89153 7.581C3.88005 6.78603 4.17513 6.01716 4.71553 5.434C4.47318 4.74369 4.50322 3.98693 4.79953 3.318C4.79953 3.318 5.47053 3.103 6.99953 4.138C8.31074 3.77905 9.69432 3.77905 11.0055 4.138C12.5325 3.103 13.2055 3.318 13.2055 3.318C13.5012 3.9877 13.5294 4.74513 13.2845 5.435C13.8221 6.01928 14.114 6.78817 14.0995 7.582C14.0995 10.655 12.2285 11.332 10.4465 11.53C10.6375 11.724 10.7847 11.9566 10.8784 12.2123C10.972 12.4679 11.0099 12.7405 10.9895 13.012C10.9895 14.081 10.9795 14.944 10.9795 15.206C10.9795 15.42 11.1235 15.669 11.5295 15.591C13.3328 14.9911 14.8636 13.7689 15.8479 12.1432C16.8321 10.5175 17.2054 8.59447 16.901 6.71858C16.5966 4.84268 15.6343 3.13642 14.1865 1.90536C12.7387 0.674306 10.9 -0.0011359 8.99953 1.43397e-06Z" fill="white" fill-rule="evenodd"> </path> </svg> </a> </div> </div> </div> <input class="radiotab w-0 h-0" data-lang="javascript" id="Nodejs_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="Nodejs_topk_tutorial-steptopk" title="Open example"> Node.js </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_Nodejs_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-javascript" data-lang="javascript"><span class="line"><span class="cl"><span class="kr">import</span> <span class="nx">assert</span> <span class="nx">from</span> <span class="s1">'assert'</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="kr">import</span> <span class="p">{</span> <span class="nx">createClient</span> <span class="p">}</span> <span class="nx">from</span> <span class="s1">'redis'</span><span class="p">;</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kr">const</span> <span class="nx">client</span> <span class="o">=</span> <span class="nx">createClient</span><span class="p">();</span> </span></span><span class="line"><span class="cl"><span class="kr">await</span> <span class="nx">client</span><span class="p">.</span><span class="nx">connect</span><span class="p">();</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line hl"><span class="cl"><span class="kr">const</span> <span class="nx">res1</span> <span class="o">=</span> <span class="kr">await</span> <span class="nx">client</span><span class="p">.</span><span class="nx">topK</span><span class="p">.</span><span class="nx">reserve</span><span class="p">(</span><span class="s1">'bikes:keywords'</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="nx">width</span><span class="o">:</span> <span class="mi">2000</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="nx">depth</span><span class="o">:</span> <span class="mi">7</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="nx">decay</span><span class="o">:</span> <span class="mf">0.925</span> </span></span><span class="line hl"><span class="cl"><span class="p">});</span> </span></span><span class="line hl"><span class="cl"><span class="nx">console</span><span class="p">.</span><span class="nx">log</span><span class="p">(</span><span class="nx">res1</span><span class="p">);</span> <span class="c1">// &gt;&gt;&gt; OK </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"><span class="kr">const</span> <span class="nx">res2</span> <span class="o">=</span> <span class="kr">await</span> <span class="nx">client</span><span class="p">.</span><span class="nx">topK</span><span class="p">.</span><span class="nx">add</span><span class="p">(</span><span class="s1">'bikes:keywords'</span><span class="p">,</span> <span class="p">[</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'store'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'seat'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'handlebars'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'handles'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'pedals'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'tires'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'store'</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s1">'seat'</span> </span></span><span class="line hl"><span class="cl"><span class="p">]);</span> </span></span><span class="line hl"><span class="cl"><span class="nx">console</span><span class="p">.</span><span class="nx">log</span><span class="p">(</span><span class="nx">res2</span><span class="p">);</span> <span class="c1">// &gt;&gt;&gt; [null, null, null, null, null, 'handlebars', null, null] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"><span class="kr">const</span> <span class="nx">res3</span> <span class="o">=</span> <span class="kr">await</span> <span class="nx">client</span><span class="p">.</span><span class="nx">topK</span><span class="p">.</span><span class="nx">list</span><span class="p">(</span><span class="s1">'bikes:keywords'</span><span class="p">);</span> </span></span><span class="line hl"><span class="cl"><span class="nx">console</span><span class="p">.</span><span class="nx">log</span><span class="p">(</span><span class="nx">res3</span><span class="p">);</span> <span class="c1">// &gt;&gt;&gt; ['store', 'seat', 'pedals', 'tires', 'handles'] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"><span class="kr">const</span> <span class="nx">res4</span> <span class="o">=</span> <span class="kr">await</span> <span class="nx">client</span><span class="p">.</span><span class="nx">topK</span><span class="p">.</span><span class="nx">query</span><span class="p">(</span><span class="s1">'bikes:keywords'</span><span class="p">,</span> <span class="p">[</span><span class="s1">'store'</span><span class="p">,</span> <span class="s1">'handlebars'</span><span class="p">]);</span> </span></span><span class="line hl"><span class="cl"><span class="nx">console</span><span class="p">.</span><span class="nx">log</span><span class="p">(</span><span class="nx">res4</span><span class="p">);</span> <span class="c1">// &gt;&gt;&gt; [1, 0] </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"> </span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_Nodejs_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <button aria-controls="panel_Nodejs_topk_tutorial-steptopk" class="visibility-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-2 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="toggleVisibleLines(this)" tabindex="1" title="Toggle visibility"> <svg class="hidden" fill="currentColor" id="visibility-off" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="m31.45 27.05-2.2-2.2q1.3-3.55-1.35-5.9-2.65-2.35-5.75-1.2l-2.2-2.2q.85-.55 1.9-.8 1.05-.25 2.15-.25 3.55 0 6.025 2.475Q32.5 19.45 32.5 23q0 1.1-.275 2.175-.275 1.075-.775 1.875Zm6.45 6.45-2-2q2.45-1.8 4.275-4.025Q42 25.25 42.85 23q-2.5-5.55-7.5-8.775Q30.35 11 24.5 11q-2.1 0-4.3.4-2.2.4-3.45.95L14.45 10q1.75-.8 4.475-1.4Q21.65 8 24.25 8q7.15 0 13.075 4.075Q43.25 16.15 46 23q-1.3 3.2-3.35 5.85-2.05 2.65-4.75 4.65Zm2.9 11.3-8.4-8.25q-1.75.7-3.95 1.075T24 38q-7.3 0-13.25-4.075T2 23q1-2.6 2.775-5.075T9.1 13.2L2.8 6.9l2.1-2.15L42.75 42.6ZM11.15 15.3q-1.85 1.35-3.575 3.55Q5.85 21.05 5.1 23q2.55 5.55 7.675 8.775Q17.9 35 24.4 35q1.65 0 3.25-.2t2.4-.6l-3.2-3.2q-.55.25-1.35.375T24 31.5q-3.5 0-6-2.45T15.5 23q0-.75.125-1.5T16 20.15Zm15.25 7.1Zm-5.8 2.9Z"> </path> </svg> <svg fill="currentColor" id="visibility-on" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24 31.5q3.55 0 6.025-2.475Q32.5 26.55 32.5 23q0-3.55-2.475-6.025Q27.55 14.5 24 14.5q-3.55 0-6.025 2.475Q15.5 19.45 15.5 23q0 3.55 2.475 6.025Q20.45 31.5 24 31.5Zm0-2.9q-2.35 0-3.975-1.625T18.4 23q0-2.35 1.625-3.975T24 17.4q2.35 0 3.975 1.625T29.6 23q0 2.35-1.625 3.975T24 28.6Zm0 9.4q-7.3 0-13.2-4.15Q4.9 29.7 2 23q2.9-6.7 8.8-10.85Q16.7 8 24 8q7.3 0 13.2 4.15Q43.1 16.3 46 23q-2.9 6.7-8.8 10.85Q31.3 38 24 38Zm0-15Zm0 12q6.05 0 11.125-3.275T42.85 23q-2.65-5.45-7.725-8.725Q30.05 11 24 11t-11.125 3.275Q7.8 17.55 5.1 23q2.7 5.45 7.775 8.725Q17.95 35 24 35Z"> </path> </svg> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <a class="rounded rounded-mx px-3 py-1 text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.io/docs/latest/develop/connect/clients/nodejs/" tabindex="1" title="Quick-Start"> Node.js Quick-Start </a> <div class="w-1/2"> </div> <div class="flex-1 text-right"> <a class="button text-neutral-400 hover:text-slate-100 h-6 w-6 p-1" href="https://github.com/redis/node-redis/tree/emb-examples/doctests/dt-topk.js" tabindex="1" title="Improve this code example"> <svg fill="github" height="16" viewbox="0 0 18 16" width="18" xmlns="http://www.w3.org/2000/svg"> <path clip-rule="evenodd" d="M8.99953 1.43397e-06C7.09918 -0.000897921 5.26058 0.674713 3.81295 1.90585C2.36533 3.13699 1.40324 4.84324 1.09896 6.71907C0.794684 8.5949 1.1681 10.5178 2.15233 12.1434C3.13657 13.769 4.66734 14.9912 6.47053 15.591C6.87053 15.664 7.01653 15.417 7.01653 15.205C7.01653 15.015 7.00953 14.512 7.00553 13.845C4.78053 14.328 4.31053 12.772 4.31053 12.772C4.16325 12.2887 3.84837 11.8739 3.42253 11.602C2.69653 11.102 3.47753 11.116 3.47753 11.116C3.73043 11.1515 3.97191 11.2442 4.18365 11.3869C4.39539 11.5297 4.57182 11.7189 4.69953 11.94C4.80755 12.1377 4.95378 12.3119 5.12972 12.4526C5.30567 12.5933 5.50782 12.6976 5.72442 12.7595C5.94103 12.8214 6.16778 12.8396 6.39148 12.813C6.61519 12.7865 6.83139 12.7158 7.02753 12.605C7.06381 12.1992 7.24399 11.8197 7.53553 11.535C5.75953 11.335 3.89153 10.647 3.89153 7.581C3.88005 6.78603 4.17513 6.01716 4.71553 5.434C4.47318 4.74369 4.50322 3.98693 4.79953 3.318C4.79953 3.318 5.47053 3.103 6.99953 4.138C8.31074 3.77905 9.69432 3.77905 11.0055 4.138C12.5325 3.103 13.2055 3.318 13.2055 3.318C13.5012 3.9877 13.5294 4.74513 13.2845 5.435C13.8221 6.01928 14.114 6.78817 14.0995 7.582C14.0995 10.655 12.2285 11.332 10.4465 11.53C10.6375 11.724 10.7847 11.9566 10.8784 12.2123C10.972 12.4679 11.0099 12.7405 10.9895 13.012C10.9895 14.081 10.9795 14.944 10.9795 15.206C10.9795 15.42 11.1235 15.669 11.5295 15.591C13.3328 14.9911 14.8636 13.7689 15.8479 12.1432C16.8321 10.5175 17.2054 8.59447 16.901 6.71858C16.5966 4.84268 15.6343 3.13642 14.1865 1.90536C12.7387 0.674306 10.9 -0.0011359 8.99953 1.43397e-06Z" fill="white" fill-rule="evenodd"> </path> </svg> </a> </div> </div> </div> <input class="radiotab w-0 h-0" data-lang="java" id="Java_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="Java_topk_tutorial-steptopk" title="Open example"> Java </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_Java_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="kn">package</span> <span class="nn">io.redis.examples</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">public</span> <span class="kd">class</span> <span class="nc">TopKExample</span> <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="kd">public</span> <span class="kt">void</span> <span class="nf">run</span><span class="o">(){</span> </span></span><span class="line"><span class="cl"> <span class="n">UnifiedJedis</span> <span class="n">unifiedJedis</span> <span class="o">=</span> <span class="k">new</span> <span class="n">UnifiedJedis</span><span class="o">(</span><span class="s">"redis://127.0.0.1:6379"</span><span class="o">);</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="n">String</span> <span class="n">res1</span> <span class="o">=</span> <span class="n">unifiedJedis</span><span class="o">.</span><span class="na">topkReserve</span><span class="o">(</span><span class="s">"bikes:keywords"</span><span class="o">,</span> <span class="mi">5L</span><span class="o">,</span> <span class="mi">2000L</span><span class="o">,</span> <span class="mi">7L</span><span class="o">,</span> <span class="mf">0.925D</span><span class="o">);</span> </span></span><span class="line hl"><span class="cl"> <span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res1</span><span class="o">);</span> <span class="c1">// &gt;&gt;&gt; True </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="n">List</span><span class="o">&lt;</span><span class="n">String</span><span class="o">&gt;</span> <span class="n">res2</span> <span class="o">=</span> <span class="n">unifiedJedis</span><span class="o">.</span><span class="na">topkAdd</span><span class="o">(</span><span class="s">"bikes:keywords"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handlebars"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handles"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"pedals"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"tires"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="o">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span><span class="o">);</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res2</span><span class="o">);</span> <span class="c1">// &gt;&gt;&gt; [None, None, None, None, None, 'handlebars', None, None] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="n">List</span><span class="o">&lt;</span><span class="n">String</span><span class="o">&gt;</span> <span class="n">res3</span> <span class="o">=</span> <span class="n">unifiedJedis</span><span class="o">.</span><span class="na">topkList</span><span class="o">(</span><span class="s">"bikes:keywords"</span><span class="o">);</span> </span></span><span class="line hl"><span class="cl"> <span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res3</span><span class="o">);</span> <span class="c1">// &gt;&gt;&gt; ['store', 'seat', 'pedals', 'tires', 'handles'] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="n">List</span><span class="o">&lt;</span><span class="n">Boolean</span><span class="o">&gt;</span> <span class="n">res4</span> <span class="o">=</span> <span class="n">unifiedJedis</span><span class="o">.</span><span class="na">topkQuery</span><span class="o">(</span><span class="s">"bikes:keywords"</span><span class="o">,</span> <span class="s">"store"</span><span class="o">,</span> <span class="s">"handlebars"</span><span class="o">);</span> </span></span><span class="line hl"><span class="cl"> <span class="n">System</span><span class="o">.</span><span class="na">out</span><span class="o">.</span><span class="na">println</span><span class="o">(</span><span class="n">res4</span><span class="o">);</span> <span class="c1">// &gt;&gt;&gt; [1, 0] </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="o">}</span> </span></span><span class="line"><span class="cl"><span class="o">}</span> </span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_Java_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <button aria-controls="panel_Java_topk_tutorial-steptopk" class="visibility-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-2 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="toggleVisibleLines(this)" tabindex="1" title="Toggle visibility"> <svg class="hidden" fill="currentColor" id="visibility-off" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="m31.45 27.05-2.2-2.2q1.3-3.55-1.35-5.9-2.65-2.35-5.75-1.2l-2.2-2.2q.85-.55 1.9-.8 1.05-.25 2.15-.25 3.55 0 6.025 2.475Q32.5 19.45 32.5 23q0 1.1-.275 2.175-.275 1.075-.775 1.875Zm6.45 6.45-2-2q2.45-1.8 4.275-4.025Q42 25.25 42.85 23q-2.5-5.55-7.5-8.775Q30.35 11 24.5 11q-2.1 0-4.3.4-2.2.4-3.45.95L14.45 10q1.75-.8 4.475-1.4Q21.65 8 24.25 8q7.15 0 13.075 4.075Q43.25 16.15 46 23q-1.3 3.2-3.35 5.85-2.05 2.65-4.75 4.65Zm2.9 11.3-8.4-8.25q-1.75.7-3.95 1.075T24 38q-7.3 0-13.25-4.075T2 23q1-2.6 2.775-5.075T9.1 13.2L2.8 6.9l2.1-2.15L42.75 42.6ZM11.15 15.3q-1.85 1.35-3.575 3.55Q5.85 21.05 5.1 23q2.55 5.55 7.675 8.775Q17.9 35 24.4 35q1.65 0 3.25-.2t2.4-.6l-3.2-3.2q-.55.25-1.35.375T24 31.5q-3.5 0-6-2.45T15.5 23q0-.75.125-1.5T16 20.15Zm15.25 7.1Zm-5.8 2.9Z"> </path> </svg> <svg fill="currentColor" id="visibility-on" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24 31.5q3.55 0 6.025-2.475Q32.5 26.55 32.5 23q0-3.55-2.475-6.025Q27.55 14.5 24 14.5q-3.55 0-6.025 2.475Q15.5 19.45 15.5 23q0 3.55 2.475 6.025Q20.45 31.5 24 31.5Zm0-2.9q-2.35 0-3.975-1.625T18.4 23q0-2.35 1.625-3.975T24 17.4q2.35 0 3.975 1.625T29.6 23q0 2.35-1.625 3.975T24 28.6Zm0 9.4q-7.3 0-13.2-4.15Q4.9 29.7 2 23q2.9-6.7 8.8-10.85Q16.7 8 24 8q7.3 0 13.2 4.15Q43.1 16.3 46 23q-2.9 6.7-8.8 10.85Q31.3 38 24 38Zm0-15Zm0 12q6.05 0 11.125-3.275T42.85 23q-2.65-5.45-7.725-8.725Q30.05 11 24 11t-11.125 3.275Q7.8 17.55 5.1 23q2.7 5.45 7.775 8.725Q17.95 35 24 35Z"> </path> </svg> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <a class="rounded rounded-mx px-3 py-1 text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.io/docs/latest/develop/connect/clients/java/jedis/" tabindex="1" title="Quick-Start"> Java Quick-Start </a> <div class="w-1/2"> </div> <div class="flex-1 text-right"> <a class="button text-neutral-400 hover:text-slate-100 h-6 w-6 p-1" href="https://github.com/redis/jedis/tree/master/src/test/java/io/redis/examples/TopKExample.java" tabindex="1" title="Improve this code example"> <svg fill="github" height="16" viewbox="0 0 18 16" width="18" xmlns="http://www.w3.org/2000/svg"> <path clip-rule="evenodd" d="M8.99953 1.43397e-06C7.09918 -0.000897921 5.26058 0.674713 3.81295 1.90585C2.36533 3.13699 1.40324 4.84324 1.09896 6.71907C0.794684 8.5949 1.1681 10.5178 2.15233 12.1434C3.13657 13.769 4.66734 14.9912 6.47053 15.591C6.87053 15.664 7.01653 15.417 7.01653 15.205C7.01653 15.015 7.00953 14.512 7.00553 13.845C4.78053 14.328 4.31053 12.772 4.31053 12.772C4.16325 12.2887 3.84837 11.8739 3.42253 11.602C2.69653 11.102 3.47753 11.116 3.47753 11.116C3.73043 11.1515 3.97191 11.2442 4.18365 11.3869C4.39539 11.5297 4.57182 11.7189 4.69953 11.94C4.80755 12.1377 4.95378 12.3119 5.12972 12.4526C5.30567 12.5933 5.50782 12.6976 5.72442 12.7595C5.94103 12.8214 6.16778 12.8396 6.39148 12.813C6.61519 12.7865 6.83139 12.7158 7.02753 12.605C7.06381 12.1992 7.24399 11.8197 7.53553 11.535C5.75953 11.335 3.89153 10.647 3.89153 7.581C3.88005 6.78603 4.17513 6.01716 4.71553 5.434C4.47318 4.74369 4.50322 3.98693 4.79953 3.318C4.79953 3.318 5.47053 3.103 6.99953 4.138C8.31074 3.77905 9.69432 3.77905 11.0055 4.138C12.5325 3.103 13.2055 3.318 13.2055 3.318C13.5012 3.9877 13.5294 4.74513 13.2845 5.435C13.8221 6.01928 14.114 6.78817 14.0995 7.582C14.0995 10.655 12.2285 11.332 10.4465 11.53C10.6375 11.724 10.7847 11.9566 10.8784 12.2123C10.972 12.4679 11.0099 12.7405 10.9895 13.012C10.9895 14.081 10.9795 14.944 10.9795 15.206C10.9795 15.42 11.1235 15.669 11.5295 15.591C13.3328 14.9911 14.8636 13.7689 15.8479 12.1432C16.8321 10.5175 17.2054 8.59447 16.901 6.71858C16.5966 4.84268 15.6343 3.13642 14.1865 1.90536C12.7387 0.674306 10.9 -0.0011359 8.99953 1.43397e-06Z" fill="white" fill-rule="evenodd"> </path> </svg> </a> </div> </div> </div> <input class="radiotab w-0 h-0" data-lang="go" id="Go_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="Go_topk_tutorial-steptopk" title="Open example"> Go </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_Go_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-go" data-lang="go"><span class="line"><span class="cl"><span class="kn">package</span> <span class="nx">example_commands_test</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="p">(</span> </span></span><span class="line"><span class="cl"> <span class="s">"context"</span> </span></span><span class="line"><span class="cl"> <span class="s">"fmt"</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="s">"github.com/redis/go-redis/v9"</span> </span></span><span class="line"><span class="cl"><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">func</span> <span class="nf">ExampleClient_topk</span><span class="p">()</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nx">ctx</span> <span class="o">:=</span> <span class="nx">context</span><span class="p">.</span><span class="nf">Background</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="nx">rdb</span> <span class="o">:=</span> <span class="nx">redis</span><span class="p">.</span><span class="nf">NewClient</span><span class="p">(</span><span class="o">&amp;</span><span class="nx">redis</span><span class="p">.</span><span class="nx">Options</span><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nx">Addr</span><span class="p">:</span> <span class="s">"localhost:6379"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nx">Password</span><span class="p">:</span> <span class="s">""</span><span class="p">,</span> <span class="c1">// no password docs </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="nx">DB</span><span class="p">:</span> <span class="mi">0</span><span class="p">,</span> <span class="c1">// use default DB </span></span></span><span class="line"><span class="cl"><span class="c1"></span> <span class="p">})</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="nx">res1</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">TopKReserve</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bikes:keywords"</span><span class="p">,</span> <span class="mi">5</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res1</span><span class="p">)</span> <span class="c1">// &gt;&gt;&gt; OK </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="nx">res2</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">TopKAdd</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bikes:keywords"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handlebars"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handles"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"pedals"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"tires"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res2</span><span class="p">)</span> <span class="c1">// &gt;&gt;&gt; [ handlebars ] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="nx">res3</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">TopKList</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bikes:keywords"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res3</span><span class="p">)</span> <span class="c1">// [store seat pedals tires handles] </span></span></span><span class="line hl"><span class="cl"><span class="c1"></span> </span></span><span class="line hl"><span class="cl"> <span class="nx">res4</span><span class="p">,</span> <span class="nx">err</span> <span class="o">:=</span> <span class="nx">rdb</span><span class="p">.</span><span class="nf">TopKQuery</span><span class="p">(</span><span class="nx">ctx</span><span class="p">,</span> <span class="s">"bikes:keywords"</span><span class="p">,</span> <span class="s">"store"</span><span class="p">,</span> <span class="s">"handlebars"</span><span class="p">).</span><span class="nf">Result</span><span class="p">()</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="nx">err</span> <span class="o">!=</span> <span class="kc">nil</span> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="nb">panic</span><span class="p">(</span><span class="nx">err</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="nx">fmt</span><span class="p">.</span><span class="nf">Println</span><span class="p">(</span><span class="nx">res4</span><span class="p">)</span> <span class="c1">// [true false] </span></span></span><span class="line"><span class="cl"><span class="c1"></span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_Go_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <button aria-controls="panel_Go_topk_tutorial-steptopk" class="visibility-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-2 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="toggleVisibleLines(this)" tabindex="1" title="Toggle visibility"> <svg class="hidden" fill="currentColor" id="visibility-off" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="m31.45 27.05-2.2-2.2q1.3-3.55-1.35-5.9-2.65-2.35-5.75-1.2l-2.2-2.2q.85-.55 1.9-.8 1.05-.25 2.15-.25 3.55 0 6.025 2.475Q32.5 19.45 32.5 23q0 1.1-.275 2.175-.275 1.075-.775 1.875Zm6.45 6.45-2-2q2.45-1.8 4.275-4.025Q42 25.25 42.85 23q-2.5-5.55-7.5-8.775Q30.35 11 24.5 11q-2.1 0-4.3.4-2.2.4-3.45.95L14.45 10q1.75-.8 4.475-1.4Q21.65 8 24.25 8q7.15 0 13.075 4.075Q43.25 16.15 46 23q-1.3 3.2-3.35 5.85-2.05 2.65-4.75 4.65Zm2.9 11.3-8.4-8.25q-1.75.7-3.95 1.075T24 38q-7.3 0-13.25-4.075T2 23q1-2.6 2.775-5.075T9.1 13.2L2.8 6.9l2.1-2.15L42.75 42.6ZM11.15 15.3q-1.85 1.35-3.575 3.55Q5.85 21.05 5.1 23q2.55 5.55 7.675 8.775Q17.9 35 24.4 35q1.65 0 3.25-.2t2.4-.6l-3.2-3.2q-.55.25-1.35.375T24 31.5q-3.5 0-6-2.45T15.5 23q0-.75.125-1.5T16 20.15Zm15.25 7.1Zm-5.8 2.9Z"> </path> </svg> <svg fill="currentColor" id="visibility-on" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24 31.5q3.55 0 6.025-2.475Q32.5 26.55 32.5 23q0-3.55-2.475-6.025Q27.55 14.5 24 14.5q-3.55 0-6.025 2.475Q15.5 19.45 15.5 23q0 3.55 2.475 6.025Q20.45 31.5 24 31.5Zm0-2.9q-2.35 0-3.975-1.625T18.4 23q0-2.35 1.625-3.975T24 17.4q2.35 0 3.975 1.625T29.6 23q0 2.35-1.625 3.975T24 28.6Zm0 9.4q-7.3 0-13.2-4.15Q4.9 29.7 2 23q2.9-6.7 8.8-10.85Q16.7 8 24 8q7.3 0 13.2 4.15Q43.1 16.3 46 23q-2.9 6.7-8.8 10.85Q31.3 38 24 38Zm0-15Zm0 12q6.05 0 11.125-3.275T42.85 23q-2.65-5.45-7.725-8.725Q30.05 11 24 11t-11.125 3.275Q7.8 17.55 5.1 23q2.7 5.45 7.775 8.725Q17.95 35 24 35Z"> </path> </svg> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <a class="rounded rounded-mx px-3 py-1 text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.io/docs/latest/develop/connect/clients/go/" tabindex="1" title="Quick-Start"> Go Quick-Start </a> <div class="w-1/2"> </div> <div class="flex-1 text-right"> <a class="button text-neutral-400 hover:text-slate-100 h-6 w-6 p-1" href="https://github.com/redis/go-redis/tree/master/doctests/topk_tutorial_test.go" tabindex="1" title="Improve this code example"> <svg fill="github" height="16" viewbox="0 0 18 16" width="18" xmlns="http://www.w3.org/2000/svg"> <path clip-rule="evenodd" d="M8.99953 1.43397e-06C7.09918 -0.000897921 5.26058 0.674713 3.81295 1.90585C2.36533 3.13699 1.40324 4.84324 1.09896 6.71907C0.794684 8.5949 1.1681 10.5178 2.15233 12.1434C3.13657 13.769 4.66734 14.9912 6.47053 15.591C6.87053 15.664 7.01653 15.417 7.01653 15.205C7.01653 15.015 7.00953 14.512 7.00553 13.845C4.78053 14.328 4.31053 12.772 4.31053 12.772C4.16325 12.2887 3.84837 11.8739 3.42253 11.602C2.69653 11.102 3.47753 11.116 3.47753 11.116C3.73043 11.1515 3.97191 11.2442 4.18365 11.3869C4.39539 11.5297 4.57182 11.7189 4.69953 11.94C4.80755 12.1377 4.95378 12.3119 5.12972 12.4526C5.30567 12.5933 5.50782 12.6976 5.72442 12.7595C5.94103 12.8214 6.16778 12.8396 6.39148 12.813C6.61519 12.7865 6.83139 12.7158 7.02753 12.605C7.06381 12.1992 7.24399 11.8197 7.53553 11.535C5.75953 11.335 3.89153 10.647 3.89153 7.581C3.88005 6.78603 4.17513 6.01716 4.71553 5.434C4.47318 4.74369 4.50322 3.98693 4.79953 3.318C4.79953 3.318 5.47053 3.103 6.99953 4.138C8.31074 3.77905 9.69432 3.77905 11.0055 4.138C12.5325 3.103 13.2055 3.318 13.2055 3.318C13.5012 3.9877 13.5294 4.74513 13.2845 5.435C13.8221 6.01928 14.114 6.78817 14.0995 7.582C14.0995 10.655 12.2285 11.332 10.4465 11.53C10.6375 11.724 10.7847 11.9566 10.8784 12.2123C10.972 12.4679 11.0099 12.7405 10.9895 13.012C10.9895 14.081 10.9795 14.944 10.9795 15.206C10.9795 15.42 11.1235 15.669 11.5295 15.591C13.3328 14.9911 14.8636 13.7689 15.8479 12.1432C16.8321 10.5175 17.2054 8.59447 16.901 6.71858C16.5966 4.84268 15.6343 3.13642 14.1865 1.90536C12.7387 0.674306 10.9 -0.0011359 8.99953 1.43397e-06Z" fill="white" fill-rule="evenodd"> </path> </svg> </a> </div> </div> </div> <input class="radiotab w-0 h-0" data-lang="dotnet" id="Csharp_topk_tutorial-steptopk" name="topk_tutorial-steptopk" tabindex="1" type="radio"/> <label class="justify-left label ml-4 pt-3.5 px-3 pb-1 cursor-pointer text-sm text-center bg-redis-ink-900 hover:text-redis-red-600 rounded rounded-mx transition duration-150 ease-in-out" for="Csharp_topk_tutorial-steptopk" title="Open example"> C# </label> <div aria-labelledby="tab-topk_tutorial-steptopk" class="panel order-last hidden w-full mt-0 relative" id="panel_Csharp_topk_tutorial-steptopk" role="tabpanel" tabindex="0"> <div class="highlight"> <pre class="chroma"><code class="language-C#" data-lang="C#"><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">NRedisStack.RedisStackCommands</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">NRedisStack.Tests</span><span class="p">;</span> </span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">StackExchange.Redis</span><span class="p">;</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="k">public</span> <span class="k">class</span> <span class="nc">Topk_tutorial</span> </span></span><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="k">public</span> <span class="k">void</span> <span class="n">run</span><span class="p">()</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">muxer</span> <span class="p">=</span> <span class="n">ConnectionMultiplexer</span><span class="p">.</span><span class="n">Connect</span><span class="p">(</span><span class="s">"localhost:6379"</span><span class="p">);</span> </span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">db</span> <span class="p">=</span> <span class="n">muxer</span><span class="p">.</span><span class="n">GetDatabase</span><span class="p">();</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="kt">bool</span> <span class="n">res1</span> <span class="p">=</span> <span class="n">db</span><span class="p">.</span><span class="n">TOPK</span><span class="p">().</span><span class="n">Reserve</span><span class="p">(</span><span class="s">"bikes:keywords"</span><span class="p">,</span> <span class="m">5</span><span class="p">,</span> <span class="m">2000</span><span class="p">,</span> <span class="m">7</span><span class="p">,</span> <span class="m">0.925</span><span class="p">);</span> </span></span><span class="line hl"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="n">res1</span><span class="p">);</span> <span class="c1">// &gt;&gt;&gt; True</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="n">RedisResult</span><span class="p">[]?</span> <span class="n">res2</span> <span class="p">=</span> <span class="n">db</span><span class="p">.</span><span class="n">TOPK</span><span class="p">().</span><span class="n">Add</span><span class="p">(</span><span class="s">"bikes:keywords"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handlebars"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"handles"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"pedals"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"tires"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"store"</span><span class="p">,</span> </span></span><span class="line hl"><span class="cl"> <span class="s">"seat"</span> </span></span><span class="line hl"><span class="cl"> <span class="p">);</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="p">(</span><span class="n">res2</span> <span class="k">is</span> <span class="n">not</span> <span class="k">null</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="kt">string</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">", "</span><span class="p">,</span> <span class="kt">string</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">", "</span><span class="p">,</span> <span class="n">res2</span><span class="p">.</span><span class="n">Select</span><span class="p">(</span><span class="n">r</span> <span class="p">=&gt;</span> <span class="s">$"{(r.IsNull ? "</span><span class="n">Null</span><span class="s">" : r)}"</span><span class="p">))));</span> </span></span><span class="line hl"><span class="cl"> <span class="c1">// &gt;&gt;&gt; Null, Null, Null, Null, Null, handlebars, Null, Null</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="n">RedisResult</span><span class="p">[]</span> <span class="n">res3</span> <span class="p">=</span> <span class="n">db</span><span class="p">.</span><span class="n">TOPK</span><span class="p">().</span><span class="n">List</span><span class="p">(</span><span class="s">"bikes:keywords"</span><span class="p">);</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="k">if</span> <span class="p">(</span><span class="n">res3</span> <span class="k">is</span> <span class="n">not</span> <span class="k">null</span><span class="p">)</span> </span></span><span class="line hl"><span class="cl"> <span class="p">{</span> </span></span><span class="line hl"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="kt">string</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">", "</span><span class="p">,</span> <span class="kt">string</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">", "</span><span class="p">,</span> <span class="n">res3</span><span class="p">.</span><span class="n">Select</span><span class="p">(</span><span class="n">r</span> <span class="p">=&gt;</span> <span class="s">$"{(r.IsNull ? "</span><span class="n">Null</span><span class="s">" : r)}"</span><span class="p">))));</span> </span></span><span class="line hl"><span class="cl"> <span class="c1">// &gt;&gt;&gt; store, seat, pedals, tires, handles</span> </span></span><span class="line hl"><span class="cl"> <span class="p">}</span> </span></span><span class="line hl"><span class="cl"> </span></span><span class="line hl"><span class="cl"> <span class="kt">bool</span><span class="p">[]</span> <span class="n">res4</span> <span class="p">=</span> <span class="n">db</span><span class="p">.</span><span class="n">TOPK</span><span class="p">().</span><span class="n">Query</span><span class="p">(</span><span class="s">"bikes:keywords"</span><span class="p">,</span> <span class="s">"store"</span><span class="p">,</span> <span class="s">"handlebars"</span><span class="p">);</span> </span></span><span class="line hl"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="kt">string</span><span class="p">.</span><span class="n">Join</span><span class="p">(</span><span class="s">", "</span><span class="p">,</span> <span class="n">res4</span><span class="p">));</span> <span class="c1">// &gt;&gt;&gt; True, False</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="c1">// Tests for 'topk' step.</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span></code></pre> </div> <button class="clipboard-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-10 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="copyCodeToClipboard('#panel_Csharp_topk_tutorial-steptopk')" tabindex="1" title="Copy to clipboard"> <svg fill="currentColor" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M9 43.95q-1.2 0-2.1-.9-.9-.9-.9-2.1V10.8h3v30.15h23.7v3Zm6-6q-1.2 0-2.1-.9-.9-.9-.9-2.1v-28q0-1.2.9-2.1.9-.9 2.1-.9h22q1.2 0 2.1.9.9.9.9 2.1v28q0 1.2-.9 2.1-.9.9-2.1.9Zm0-3h22v-28H15v28Zm0 0v-28 28Z"> </path> </svg> <div class="tooltip relative inline-block"> <span class="tooltiptext hidden bg-slate-200 rounded rounded-mx text-slate-800 text-center text-xs p-1 absolute right-6 bottom-4"> Copied! </span> </div> </button> <button aria-controls="panel_Csharp_topk_tutorial-steptopk" class="visibility-button text-neutral-400 hover:text-slate-100 bg-slate-600 absolute -top-8 right-2 h-7 w-7 mr-2 mt-2 p-1 rounded rounded-mx" onclick="toggleVisibleLines(this)" tabindex="1" title="Toggle visibility"> <svg class="hidden" fill="currentColor" id="visibility-off" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="m31.45 27.05-2.2-2.2q1.3-3.55-1.35-5.9-2.65-2.35-5.75-1.2l-2.2-2.2q.85-.55 1.9-.8 1.05-.25 2.15-.25 3.55 0 6.025 2.475Q32.5 19.45 32.5 23q0 1.1-.275 2.175-.275 1.075-.775 1.875Zm6.45 6.45-2-2q2.45-1.8 4.275-4.025Q42 25.25 42.85 23q-2.5-5.55-7.5-8.775Q30.35 11 24.5 11q-2.1 0-4.3.4-2.2.4-3.45.95L14.45 10q1.75-.8 4.475-1.4Q21.65 8 24.25 8q7.15 0 13.075 4.075Q43.25 16.15 46 23q-1.3 3.2-3.35 5.85-2.05 2.65-4.75 4.65Zm2.9 11.3-8.4-8.25q-1.75.7-3.95 1.075T24 38q-7.3 0-13.25-4.075T2 23q1-2.6 2.775-5.075T9.1 13.2L2.8 6.9l2.1-2.15L42.75 42.6ZM11.15 15.3q-1.85 1.35-3.575 3.55Q5.85 21.05 5.1 23q2.55 5.55 7.675 8.775Q17.9 35 24.4 35q1.65 0 3.25-.2t2.4-.6l-3.2-3.2q-.55.25-1.35.375T24 31.5q-3.5 0-6-2.45T15.5 23q0-.75.125-1.5T16 20.15Zm15.25 7.1Zm-5.8 2.9Z"> </path> </svg> <svg fill="currentColor" id="visibility-on" viewbox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24 31.5q3.55 0 6.025-2.475Q32.5 26.55 32.5 23q0-3.55-2.475-6.025Q27.55 14.5 24 14.5q-3.55 0-6.025 2.475Q15.5 19.45 15.5 23q0 3.55 2.475 6.025Q20.45 31.5 24 31.5Zm0-2.9q-2.35 0-3.975-1.625T18.4 23q0-2.35 1.625-3.975T24 17.4q2.35 0 3.975 1.625T29.6 23q0 2.35-1.625 3.975T24 28.6Zm0 9.4q-7.3 0-13.2-4.15Q4.9 29.7 2 23q2.9-6.7 8.8-10.85Q16.7 8 24 8q7.3 0 13.2 4.15Q43.1 16.3 46 23q-2.9 6.7-8.8 10.85Q31.3 38 24 38Zm0-15Zm0 12q6.05 0 11.125-3.275T42.85 23q-2.65-5.45-7.725-8.725Q30.05 11 24 11t-11.125 3.275Q7.8 17.55 5.1 23q2.7 5.45 7.775 8.725Q17.95 35 24 35Z"> </path> </svg> </button> <div class="cli-footer flex items-center justify-between rounded-b-md bg-slate-900 mt-0 px-4 pt-0 mb-0 transition-opacity ease-in-out duration-300 opacity-0 invisible group-hover:opacity-100 group-hover:visible"> <a class="rounded rounded-mx px-3 py-1 text-white text-xs hover:text-white hover:bg-slate-600 hover:border-transparent focus:outline-none focus:ring-2 focus:white focus:border-slate-500" href="https://redis.io/docs/latest/develop/connect/clients/dotnet/" tabindex="1" title="Quick-Start"> C# Quick-Start </a> <div class="w-1/2"> </div> <div class="flex-1 text-right"> <a class="button text-neutral-400 hover:text-slate-100 h-6 w-6 p-1" href="https://github.com/redis/NRedisStack/tree/master/tests/Doc/Topk_tutorial.cs" tabindex="1" title="Improve this code example"> <svg fill="github" height="16" viewbox="0 0 18 16" width="18" xmlns="http://www.w3.org/2000/svg"> <path clip-rule="evenodd" d="M8.99953 1.43397e-06C7.09918 -0.000897921 5.26058 0.674713 3.81295 1.90585C2.36533 3.13699 1.40324 4.84324 1.09896 6.71907C0.794684 8.5949 1.1681 10.5178 2.15233 12.1434C3.13657 13.769 4.66734 14.9912 6.47053 15.591C6.87053 15.664 7.01653 15.417 7.01653 15.205C7.01653 15.015 7.00953 14.512 7.00553 13.845C4.78053 14.328 4.31053 12.772 4.31053 12.772C4.16325 12.2887 3.84837 11.8739 3.42253 11.602C2.69653 11.102 3.47753 11.116 3.47753 11.116C3.73043 11.1515 3.97191 11.2442 4.18365 11.3869C4.39539 11.5297 4.57182 11.7189 4.69953 11.94C4.80755 12.1377 4.95378 12.3119 5.12972 12.4526C5.30567 12.5933 5.50782 12.6976 5.72442 12.7595C5.94103 12.8214 6.16778 12.8396 6.39148 12.813C6.61519 12.7865 6.83139 12.7158 7.02753 12.605C7.06381 12.1992 7.24399 11.8197 7.53553 11.535C5.75953 11.335 3.89153 10.647 3.89153 7.581C3.88005 6.78603 4.17513 6.01716 4.71553 5.434C4.47318 4.74369 4.50322 3.98693 4.79953 3.318C4.79953 3.318 5.47053 3.103 6.99953 4.138C8.31074 3.77905 9.69432 3.77905 11.0055 4.138C12.5325 3.103 13.2055 3.318 13.2055 3.318C13.5012 3.9877 13.5294 4.74513 13.2845 5.435C13.8221 6.01928 14.114 6.78817 14.0995 7.582C14.0995 10.655 12.2285 11.332 10.4465 11.53C10.6375 11.724 10.7847 11.9566 10.8784 12.2123C10.972 12.4679 11.0099 12.7405 10.9895 13.012C10.9895 14.081 10.9795 14.944 10.9795 15.206C10.9795 15.42 11.1235 15.669 11.5295 15.591C13.3328 14.9911 14.8636 13.7689 15.8479 12.1432C16.8321 10.5175 17.2054 8.59447 16.901 6.71858C16.5966 4.84268 15.6343 3.13642 14.1865 1.90536C12.7387 0.674306 10.9 -0.0011359 8.99953 1.43397e-06Z" fill="white" fill-rule="evenodd"> </path> </svg> </a> </div> </div> </div> </div> <p> </p> </li> </ul> <h2 id="sizing"> Sizing </h2> <p> Choosing the size for a Top K sketch is relatively easy, because the only two parameters you need to set are a direct function of the number of elements (K) you want to keep in your list. </p> <p> If you start by knowing your desired <code> k </code> you can easily derive the width and depth: </p> <pre tabindex="0"><code>width = k*log(k) depth = log(k) # but a minimum of 5 </code></pre> <p> For the <code> decay_constant </code> you can use the value <code> 0.9 </code> which has been found as optimal in many cases, but you can experiment with different values and find what works best for your use case. </p> <h2 id="performance"> Performance </h2> <p> Insertion in a top-k has time complexity of O(K + depth) β‰ˆ O(K) and lookup has time complexity of O(K), where K is the number of top elements to be kept in the list and depth is the number of hash functions used. </p> <h2 id="academic-sources"> Academic sources </h2> <ul> <li> <a href="https://yangtonghome.github.io/uploads/HeavyKeeper_ToN.pdf"> HeavyKeeper: An Accurate Algorithm for Finding Top-k Elephant Flows. </a> </li> </ul> <h2 id="references"> References </h2> <ul> <li> <a href="https://redis.com/blog/meet-top-k-awesome-probabilistic-addition-redisbloom/"> Meet Top-K: an Awesome Probabilistic Addition to RedisBloom </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/data-types/probabilistic/top-k/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/subscriptions/view-pro-subscription/.html
<section class="prose w-full py-12 max-w-none"> <h1> View and edit Redis Cloud Pro plan </h1> <p> To view the details of a Redis Cloud Pro subscription: </p> <ol> <li> <p> Sign in to the <a href="https://cloud.redis.io/#"> Redis Cloud console </a> and select <strong> Subscriptions </strong> . </p> </li> <li> <p> If you have more than one subscription, select the target subscription from the subscription list. </p> <a href="/docs/latest/images/rc/subscription-list-select.png" sdata-lightbox="/images/rc/subscription-list-select.png"> <img alt="The Subscription list shows your current subscriptions." src="/docs/latest/images/rc/subscription-list-select.png"/> </a> </li> <li> <p> Your subscription details appear, along with a summary of your database details. </p> <a href="/docs/latest/images/rc/subscription-flexible-databases-tab-pending.png" sdata-lightbox="/images/rc/subscription-flexible-databases-tab-pending.png"> <img alt="The Databases tab of the subscription details page is the default view." src="/docs/latest/images/rc/subscription-flexible-databases-tab-pending.png"/> </a> </li> </ol> <p> From here, you can: </p> <ul> <li> <p> Select the <strong> New database </strong> button to add a database to your subscription. </p> <a href="/docs/latest/images/rc/button-database-new.png" sdata-lightbox="/images/rc/button-database-new.png"> <img alt="Use the **New database** button to create a new database for your subscription." src="/docs/latest/images/rc/button-database-new.png"/> </a> </li> <li> <p> View the Status icon to learn the status of your subscription. Active subscriptions display a green circle with a check mark. Pending subscriptions display an animated, grey circle. </p> <p> <a href="/docs/latest/images/rc/icon-database-status-active.png#no-click" sdata-lightbox="/images/rc/icon-database-status-active.png#no-click"> <img alt="When a subscription is active, the status icon displays a green circle with a checkmark." class="inline" src="/docs/latest/images/rc/icon-database-status-active.png#no-click"/> </a> <a href="/docs/latest/images/rc/icon-subscription-status-pending.png#no-click" sdata-lightbox="/images/rc/icon-subscription-status-pending.png#no-click"> <img alt="When a subscription is pending, the status icon displays a gre, animated circle." class="inline" src="/docs/latest/images/rc/icon-subscription-status-pending.png#no-click"/> </a> </p> </li> <li> <p> Select <strong> Opt-in to 7.2 </strong> to request to upgrade your subscription and databases to Redis 7.2 ( <em> Redis 6.2 and earlier only </em> ). </p> <a href="/docs/latest/images/rc/button-opt-in-to-72.png" sdata-lightbox="/images/rc/button-opt-in-to-72.png"> <img alt="Opt-in to 7.2 button." src="/docs/latest/images/rc/button-opt-in-to-72.png" width="150px"/> </a> <p> The upgrade will start one week from your request, according to <a href="/docs/latest/operate/rc/subscriptions/maintenance/set-maintenance-windows/"> maintenance windows </a> . </p> <p> Redis 7.2 introduces several changes to existing Redis commands; see the list of <a href="/docs/latest/operate/rc/changelog/2023/june-2023/#redis-72-breaking-changes"> breaking changes </a> for more details. </p> </li> </ul> <p> Because subscriptions represent active deployments, there aren't many details you can change. If your needs change, create a new subscription and then migrate the existing data to the new databases. </p> <p> In addition, three tabs are available: </p> <ol> <li> <p> The <strong> Databases </strong> tab lists the databases in your subscription and summarizes their settings. </p> </li> <li> <p> The <strong> Overview </strong> tab displays subscription settings for your Redis Cloud Pro subscription. </p> </li> <li> <p> The <strong> Connectivity </strong> tab lets you limit access to the subscription by defining a VPC peering relationship or by setting up an allow list. </p> </li> </ol> <p> The following sections provide more info. </p> <h2 id="databases-tab"> <strong> Databases </strong> tab </h2> <p> The <strong> Databases </strong> tab summarizes the databases in your subscription. </p> <a href="/docs/latest/images/rc/subscription-flexible-databases-tab-pending.png" sdata-lightbox="/images/rc/subscription-flexible-databases-tab-pending.png"> <img alt="The Databases tab of the subscription details page is the default view." src="/docs/latest/images/rc/subscription-flexible-databases-tab-pending.png"/> </a> <p> The following details are provided: </p> <table> <thead> <tr> <th style="text-align:left"> Detail </th> <th style="text-align:left"> Description </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <strong> Status </strong> </td> <td style="text-align:left"> An icon indicating whether the database is active (a green circle) or pending (yellow circle) <br/> <a href="/docs/latest/images/rc/icon-database-detail-status-active.png#no-click" sdata-lightbox="/images/rc/icon-database-detail-status-active.png#no-click"> <img alt="Active status is indicated by a teal circle." class="inline" src="/docs/latest/images/rc/icon-database-detail-status-active.png#no-click"/> </a> <a href="/docs/latest/images/rc/icon-database-detail-status-pending.png#no-click" sdata-lightbox="/images/rc/icon-database-detail-status-pending.png#no-click"> <img alt="Pending status is indicated by a yellow circle." class="inline" src="/docs/latest/images/rc/icon-database-detail-status-pending.png#no-click"/> </a> </td> </tr> <tr> <td style="text-align:left"> <strong> Name </strong> </td> <td style="text-align:left"> The database name </td> </tr> <tr> <td style="text-align:left"> <strong> Endpoint </strong> </td> <td style="text-align:left"> Use the <strong> Copy </strong> button to copy the endpoint URI to the Clipboard </td> </tr> <tr> <td style="text-align:left"> <strong> Memory </strong> </td> <td style="text-align:left"> Memory size of the database, showing the current size and the maximum size </td> </tr> <tr> <td style="text-align:left"> <strong> Throughput </strong> </td> <td style="text-align:left"> Maximum operations per second supported for the database </td> </tr> <tr> <td style="text-align:left"> <strong> Capabilities </strong> </td> <td style="text-align:left"> Identifies advanced capabilities attached to the database </td> </tr> <tr> <td style="text-align:left"> <strong> Options </strong> </td> <td style="text-align:left"> Icons showing options associated with the database </td> </tr> </tbody> </table> <p> To view full details of a database, click its name in the list. </p> <h2 id="overview-tab"> <strong> Overview </strong> tab </h2> <p> The <strong> Overview </strong> summarizes the options use to created the subscription. </p> <a href="/docs/latest/images/rc/subscription-details-overview-flexible.png" sdata-lightbox="/images/rc/subscription-details-overview-flexible.png"> <img alt="The Overview tab displays the settings used to create your Redis Cloud Pro subscription." src="/docs/latest/images/rc/subscription-details-overview-flexible.png"/> </a> <ul> <li> <p> The general settings panel describes the cloud vendor, region, and high-availability settings for your subscription. </p> <p> Select <strong> Edit </strong> to change the name of the subscription. </p> <a href="/docs/latest/images/rc/icon-edit-subscription-name.png" sdata-lightbox="/images/rc/icon-edit-subscription-name.png"> <img alt="Use the **Edit** button to change the subscription name." src="/docs/latest/images/rc/icon-edit-subscription-name.png"/> </a> <table> <thead> <tr> <th style="text-align:left"> Setting </th> <th style="text-align:left"> Description </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <strong> Cloud vendor </strong> </td> <td style="text-align:left"> Your subscription cloud vendor </td> </tr> <tr> <td style="text-align:left"> <strong> Plan description </strong> </td> <td style="text-align:left"> Brief summary of subscription, including the plan type, cloud provider, and region </td> </tr> <tr> <td style="text-align:left"> <strong> Auto Tiering </strong> </td> <td style="text-align:left"> Checked when Auto Tiering is enabled </td> </tr> <tr> <td style="text-align:left"> <strong> Multi-AZ </strong> </td> <td style="text-align:left"> Checked when multiple availability zones are enabled </td> </tr> <tr> <td style="text-align:left"> <strong> Active-Active Redis </strong> </td> <td style="text-align:left"> Checked when Active-Active Redis is enabled for your subscription </td> </tr> <tr> <td style="text-align:left"> <strong> Region </strong> </td> <td style="text-align:left"> Describes the region your subscription is deployed to </td> </tr> <tr> <td style="text-align:left"> <strong> Availability Zones </strong> </td> <td style="text-align:left"> The availability zones your subscription is deployed in (Visible if you selected availability zones on creation) </td> </tr> </tbody> </table> </li> <li> <p> The <strong> Price </strong> panel shows the monthly cost of your Redis Cloud Pro subscription. </p> </li> <li> <p> The <strong> Payment Method </strong> panel shows the current payment details. </p> <p> Select the <strong> Edit payment method </strong> button to change the credit card associated with this subscription. </p> <a href="/docs/latest/images/rc/icon-subscription-detail-change-payment-flexible.png" sdata-lightbox="/images/rc/icon-subscription-detail-change-payment-flexible.png"> <img alt="The edit payment method button, selected and showing two credit cards." src="/docs/latest/images/rc/icon-subscription-detail-change-payment-flexible.png" width="400px"/> </a> <p> Select <strong> Add credit card </strong> to add a new credit card. </p> </li> <li> <p> The <strong> Maintenance Window </strong> panel shows your current <a href="/docs/latest/operate/rc/subscriptions/maintenance/set-maintenance-windows/"> maintenance window settings </a> . </p> <p> See <a href="/docs/latest/operate/rc/subscriptions/maintenance/"> Maintenance </a> for more information about subscription maintenance on Redis Cloud. </p> </li> <li> <p> The <strong> Provisioned cloud resources </strong> panel shows the storage resources used by your subscription. </p> <p> If your subscription is attached to a cloud account, the details appear in the panel header. </p> </li> <li> <p> The <strong> Redis price </strong> panel breaks down your subscription price. </p> </li> </ul> <h2 id="connectivity-tab"> <strong> Connectivity </strong> tab </h2> <p> The <strong> Connectivity </strong> tabs helps secure your subscription. </p> <a href="/docs/latest/images/rc/subscription-details-connectivity-tab-flexible.png" sdata-lightbox="/images/rc/subscription-details-connectivity-tab-flexible.png"> <img alt="The Connectivity tab helps you secure your subscription." src="/docs/latest/images/rc/subscription-details-connectivity-tab-flexible.png"/> </a> <p> Here, you can: </p> <ul> <li> <p> Set up a <a href="/docs/latest/operate/rc/security/vpc-peering/"> VPC peering </a> relationship between the virtual PC (VPC) hosting your subscription and another virtual PC. </p> </li> <li> <p> Set up a <a href="/docs/latest/operate/rc/security/cidr-whitelist/"> CIDR allow list </a> containing IP addresses or security groups ( <em> AWS only </em> ) permitted to access your subscription. </p> </li> <li> <p> Set up <a href="/docs/latest/operate/rc/security/private-service-connect/"> Private Service Connect </a> ( <em> Google Cloud only </em> ) or <a href="/docs/latest/operate/rc/security/aws-transit-gateway/"> Transit Gateway </a> ( <em> AWS only </em> ). </p> </li> </ul> <p> See the individual links to learn more. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/subscriptions/view-pro-subscription/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/register-events/.html
<section class="prose w-full py-12 max-w-none"> <h1> Register events </h1> <p class="text-lg -mt-5 mb-10"> Register RedisGears functions to run when certain events occur in a Redis database. </p> <p> You can register RedisGears functions to run when certain events occur in a Redis database. </p> <h2 id="register-on-events"> Register on events </h2> <p> To register RedisGears functions to run on an event, your code needs to: </p> <ol> <li> <p> Pass <code> KeysReader </code> to a <code> GearsBuilder </code> object. </p> </li> <li> <p> Call the <code> GearsBuilder.register() </code> function. </p> </li> <li> <p> Pass the <code> eventTypes </code> parameter to either: </p> <ul> <li> <p> The <code> register </code> function for Python. </p> </li> <li> <p> The <code> KeysReader </code> object for Java. </p> </li> </ul> </li> </ol> <p> For more information and examples of event registration, see: </p> <ul> <li> <p> Java references: </p> <ul> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/jvm/classes/readers/keysreader/"> <code> KeysReader </code> </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/jvm/classes/gearsbuilder/register/"> <code> GearsBuilder.register() </code> </a> </p> </li> </ul> </li> </ul> <h2 id="event-types"> Event types </h2> <p> For the list of event types you can register on, see the <a href="/docs/latest/develop/use/keyspace-notifications/#events-generated-by-different-commands"> Redis keyspace notification documentation </a> . </p> <h2 id="active-active-event-types"> Active-Active event types </h2> <p> In addition to standard Redis <a href="/docs/latest/develop/use/keyspace-notifications/#events-generated-by-different-commands"> events </a> , <a href="/docs/latest/operate/rs/databases/active-active/"> Redis Enterprise Active-Active databases </a> also support the registration of RedisGears functions for the following event types: </p> <ul> <li> <code> change </code> : This event occurs when a key changes on another replica of the Active-Active database. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/register-events/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/subscriptions/view-essentials-subscription/.html
<section class="prose w-full py-12 max-w-none"> <h1> View and Upgrade Redis Cloud Essentials plan </h1> <p> To view the details of a Redis Cloud Essentials subscription: </p> <ol> <li> <p> Sign in to the <a href="https://cloud.redis.io/"> Redis Cloud console </a> and select the <strong> Subscriptions </strong> list. </p> </li> <li> <p> Select the target subscription from the subscription list. </p> <a href="/docs/latest/images/rc/subscription-list-select.png" sdata-lightbox="/images/rc/subscription-list-select.png"> <img alt="The Subscription list shows your current subscriptions." src="/docs/latest/images/rc/subscription-list-select.png"/> </a> </li> <li> <p> Your subscription details appear, along with a summary of your database details. </p> <a href="/docs/latest/images/rc/subscription-details-fixed-databases-tab.png" sdata-lightbox="/images/rc/subscription-details-fixed-databases-tab.png"> <img alt="The Databases tab of the subscription details page is the default view." src="/docs/latest/images/rc/subscription-details-fixed-databases-tab.png"/> </a> </li> </ol> <p> From here, you can: </p> <ul> <li> <p> Select the <strong> Upgrade Plan </strong> button to update your subscription plan, high availability settings, or payment method. </p> <a href="/docs/latest/images/rc/button-subscription-upgrade-plan.png" sdata-lightbox="/images/rc/button-subscription-upgrade-plan.png"> <img alt="Select the Upgrade plan button to update your subscription settings." src="/docs/latest/images/rc/button-subscription-upgrade-plan.png"/> </a> </li> <li> <p> Select the <strong> Overview </strong> tab to view and edit subscription details. </p> </li> </ul> <p> The following sections provide more details. </p> <h2 id="upgrade-plan"> Upgrade plan </h2> <p> Use the <strong> Upgrade plan </strong> button to update your Redis Cloud Essentials plan, your high availability settings, or your payment method. Upgrading your database between Redis Cloud Essentials plans does not impact database availability during the update. </p> <a href="/docs/latest/images/rc/button-subscription-upgrade-plan.png" sdata-lightbox="/images/rc/button-subscription-upgrade-plan.png"> <img alt="Use the Upgrade plan button to change selected Redis Cloud Essentials subscription detils." src="/docs/latest/images/rc/button-subscription-upgrade-plan.png"/> </a> <p> For information on how to upgrade to Redis Cloud Pro, see <a href="/docs/latest/operate/rc/subscriptions/upgrade-essentials-pro/"> upgrade subscription plan from Essentials to Pro </a> . </p> <h3 id="change-subscription-plan"> Change subscription plan </h3> <p> To change your subscription plan, select the desired plan from the list and select the <strong> Upgrade plan </strong> button: </p> <a href="/docs/latest/images/rc/subscription-change-fixed-tiers.png" sdata-lightbox="/images/rc/subscription-change-fixed-tiers.png"> <img alt="Select the desired subscription plan from the ones shown." src="/docs/latest/images/rc/subscription-change-fixed-tiers.png" width="100%"/> </a> <p> Each Redis Cloud Essentials plan provides a variety of benefits, including increased memory and number of connections. For a comparison of available plans, see <a href="/docs/latest/operate/rc/subscriptions/view-essentials-subscription/essentials-plan-details/"> Redis Cloud Essentials plans </a> . </p> <p> When you change your plan, your data and endpoints are not disrupted. </p> <p> If you upgrade a free plan to a paid plan, you need to add a payment method. </p> <p> If you change your subscription to a lower plan, make sure your data fits within the limits of the new plan; otherwise, the change attempt will fail. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> As of January 2024, new and upgraded Redis Cloud Essentials subscriptions are limited to one database per subscription. If you have a Redis Cloud Essentials subscription created before January 2024, you can add databases up to the previous plan limit. If you choose to upgrade your plan, you can keep your databases, but you will need to create a new subscription to add another database. </div> </div> <h3 id="change-high-availability"> Change high availability </h3> <p> To change your plan's high availability settings, select the desired setting in the <strong> High availability </strong> panel. </p> <a href="/docs/latest/images/rc/subscription-fixed-high-availability-panel.png" sdata-lightbox="/images/rc/subscription-fixed-high-availability-panel.png"> <img alt="Use the High availability panel to set Essentials subscription replication settings." src="/docs/latest/images/rc/subscription-fixed-high-availability-panel.png"/> </a> <p> You can switch between <strong> No replication </strong> and <strong> Single-zone replication </strong> at any time, but you cannot choose <strong> Multi-zone replication </strong> after your subscription is created. You also cannot switch from <strong> Multi-zone replication </strong> to another high availability option. </p> <h3 id="change-payment-method"> Change payment method </h3> <p> To change your subscription payment method, update the <strong> Credit card </strong> settings. You can select a known payment method from the drop-down list or use the <strong> Add </strong> button to add a new one. </p> <a href="/docs/latest/images/rc/subscription-change-credit-card.png" sdata-lightbox="/images/rc/subscription-change-credit-card.png"> <img alt="Use the Credit card drop-down to set your subscription payment method." src="/docs/latest/images/rc/subscription-change-credit-card.png"/> </a> <p> Payment method changes require the Owner role. If your sign-on is not a subscription owner, you cannot change the payment method. </p> <p> To verify your role, select <strong> Access Management </strong> from the admin menu and then locate your credentials in the <strong> Team </strong> tab. </p> <h3 id="save-changes"> Save changes </h3> <p> Use the <strong> Upgrade plan </strong> button to save changes. </p> <a href="/docs/latest/images/rc/button-subscription-upgrade-plan-blue.png" sdata-lightbox="/images/rc/button-subscription-upgrade-plan-blue.png"> <img alt="Use the Upgrade plan button to save your subscription plan changes." src="/docs/latest/images/rc/button-subscription-upgrade-plan-blue.png"/> </a> <h2 id="subscription-overview"> Subscription overview </h2> <p> The <strong> Overview </strong> tab summarizes your Redis Cloud Essentials subscription details using a series of panels: </p> <a href="/docs/latest/images/rc/subscription-details-fixed-overview-tab.png" sdata-lightbox="/images/rc/subscription-details-fixed-overview-tab.png"> <img alt="The Overview tab displays the details of your Fixed subscription." src="/docs/latest/images/rc/subscription-details-fixed-overview-tab.png" width="75%"/> </a> <p> The following details are displayed: </p> <table> <thead> <tr> <th style="text-align:left"> Detail </th> <th style="text-align:left"> Description </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <strong> Cloud vendor </strong> </td> <td style="text-align:left"> Your database's cloud vendor </td> </tr> <tr> <td style="text-align:left"> <strong> Plan description </strong> </td> <td style="text-align:left"> Brief summary of subscription, including the plan type, cloud provider, region, and data size limit </td> </tr> <tr> <td style="text-align:left"> <strong> Availability </strong> </td> <td style="text-align:left"> Describes high availability settings </td> </tr> <tr> <td style="text-align:left"> <strong> Region </strong> </td> <td style="text-align:left"> The region your subscription is deployed to </td> </tr> <tr> <td style="text-align:left"> <strong> Plan </strong> </td> <td style="text-align:left"> The maximum database size of your Essentials plan. Also displays the cost for paid plans. </td> </tr> <tr> <td style="text-align:left"> <strong> Databases </strong> </td> <td style="text-align:left"> Maximum number of databases for your plan </td> </tr> <tr> <td style="text-align:left"> <strong> Connections </strong> </td> <td style="text-align:left"> Maximum number of concurrent connections </td> </tr> <tr> <td style="text-align:left"> <strong> CIDR allow rules </strong> </td> <td style="text-align:left"> Maximum number of authorization rules </td> </tr> <tr> <td style="text-align:left"> <strong> Data persistence </strong> </td> <td style="text-align:left"> Indicates whether persistence is supported for your subscription </td> </tr> <tr> <td style="text-align:left"> <strong> Daily &amp; instant backups </strong> </td> <td style="text-align:left"> Indicates whether backups are supported for your subscription </td> </tr> <tr> <td style="text-align:left"> <strong> Replication </strong> </td> <td style="text-align:left"> Indicates whether replication is supported for your subscription </td> </tr> <tr> <td style="text-align:left"> <strong> Clustering </strong> </td> <td style="text-align:left"> Indicates whether clustering is supported for your subscription </td> </tr> </tbody> </table> <p> Select the <strong> Edit </strong> button to change the subscription name. </p> <a href="/docs/latest/images/rc/icon-edit-subscription-name.png" sdata-lightbox="/images/rc/icon-edit-subscription-name.png"> <img alt="Use the **Edit** button to change the subscription name." src="/docs/latest/images/rc/icon-edit-subscription-name.png"/> </a> <p> The <strong> Delete subscription </strong> button lets you <a href="/docs/latest/operate/rc/subscriptions/delete-subscription/"> delete your subscription </a> . </p> <a href="/docs/latest/images/rc/button-subscription-delete.png" sdata-lightbox="/images/rc/button-subscription-delete.png"> <img alt="Use the Delete subscription button to delete your subscription plan." src="/docs/latest/images/rc/button-subscription-delete.png"/> </a> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/subscriptions/view-essentials-subscription/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/ft.synupdate/.html
<section class="prose w-full py-12"> <h1 class="command-name"> FT.SYNUPDATE </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">FT.SYNUPDATE index synonym_group_id [SKIPINITIALSCAN] term [term ...] </pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/interact/search-and-query"> Search 1.2.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) </dd> </dl> <p> Update a synonym group </p> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> index </code> </summary> <p> is index name. </p> </details> <details open=""> <summary> <code> synonym_group_id </code> </summary> <p> is synonym group to return. </p> </details> <p> Use FT.SYNUPDATE to create or update a synonym group with additional terms. The command triggers a scan of all documents. </p> <h2 id="optional-parameters"> Optional parameters </h2> <details open=""> <summary> <code> SKIPINITIALSCAN </code> </summary> <p> does not scan and index, and only documents that are indexed after the update are affected. </p> </details> <h2 id="return"> Return </h2> <p> FT.SYNUPDATE returns a simple string reply <code> OK </code> if executed correctly, or an error reply otherwise. </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Update a synonym group </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.SYNUPDATE idx synonym hello hi shalom </span></span><span class="line"><span class="cl">OK</span></span></code></pre> </div> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.SYNUPDATE idx synonym SKIPINITIALSCAN hello hi shalom </span></span><span class="line"><span class="cl">OK</span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/ft.syndump/"> <code> FT.SYNDUMP </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <p> <a href="/docs/latest/develop/interact/search-and-query/"> RediSearch </a> </p> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/ft.synupdate/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/installing-upgrading/uninstalling/.html
<section class="prose w-full py-12 max-w-none"> <h1> Uninstall Redis Enterprise Software </h1> <p> Use the script <code> rl_uninstall.sh </code> to uninstall Redis Enterprise Software and remove its files from a node. The script also deletes all Redis data and configuration from the node. </p> <p> The uninstall script does not remove the node from the cluster, but the node's status changes to down. For node removal instructions, see <a href="/docs/latest/operate/rs/clusters/remove-node/"> Remove a cluster node </a> . </p> <h2 id="uninstall-redis-enterprise-software"> Uninstall Redis Enterprise Software </h2> <p> To uninstall Redis Enterprise Software from a cluster node: </p> <ol> <li> <p> Navigate to the script's location, which is in <code> /opt/redislabs/bin/ </code> by default. </p> </li> <li> <p> Run the uninstall script as the root user: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">sudo ./rl_uninstall.sh </span></span></code></pre> </div> </li> </ol> <p> When you run the uninstall script on a node, it only uninstalls Redis Enterprise Software from that node. To uninstall Redis Enterprise Software for the entire cluster, run the uninstall script on each cluster node. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/installing-upgrading/uninstalling/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/hardware-requirements/.html
<section class="prose w-full py-12 max-w-none"> <h1> Hardware requirements </h1> <p class="text-lg -mt-5 mb-10"> Redis Enterprise Software hardware requirements for development and production environments. </p> <p> The hardware requirements for Redis Enterprise Software are different for development and production environments. </p> <ul> <li> <p> In a development environment, you can test your application with a live database. </p> <p> If you want to test your application under production conditions, use the production environment requirements. </p> </li> <li> <p> In a production environment, you must have enough resources to handle the load on the database and recover from failures. </p> </li> </ul> <h2 id="developmentenvironment"> DevelopmentΒ environment </h2> <p> You can build your development environment with non-production hardware, such as a laptop, desktop, or small VM or instance, and with these hardware requirements: </p> <table> <thead> <tr> <th> Item </th> <th> Description </th> <th> Minimum requirements </th> <th> Recommended </th> </tr> </thead> <tbody> <tr> <td> Nodes per cluster </td> <td> You can install on one node but many features require at least two nodes. </td> <td> 1 node </td> <td> &gt;= 2 nodes </td> </tr> <tr> <td> RAM per node </td> <td> The amount of RAM for each node. </td> <td> 4GB </td> <td> &gt;= 10GB </td> </tr> <tr> <td> Storage per node </td> <td> The amount of storage space for each node. </td> <td> 10GB </td> <td> &gt;= 20GB </td> </tr> </tbody> </table> <h2 id="productionenvironment"> ProductionΒ environment </h2> <p> We recommend these hardware requirements for production systems or for development systems that are designed to demonstrate production use cases: </p> <table> <thead> <tr> <th> Item </th> <th> Description </th> <th> Minimum requirements </th> <th> Recommended </th> </tr> </thead> <tbody> <tr> <td> Nodes <sup> * </sup> per cluster </td> <td> At least three nodes are required to support a reliable, highly available deployment that handles process failure, node failure, and network split events in a consistent manner. </td> <td> 3 nodes </td> <td> &gt;= 3 nodes (Must be an odd number of nodes) </td> </tr> <tr> <td> Cores <sup> * </sup> per node </td> <td> Redis Enterprise SoftwareΒ is based on a multi-tenant architecture and can run multiple Redis processes (or shards) on the same core without significant performance degradation. </td> <td> 4 cores </td> <td> &gt;=8 cores </td> </tr> <tr> <td> RAM <sup> * </sup> per node </td> <td> Defining your RAM size must be part of the capacity planning for your Redis usage. </td> <td> 15GB </td> <td> &gt;=30GB </td> </tr> <tr> <td> Ephemeral Storage </td> <td> Used for storing <a href="/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/"> replication files (RDB format) and cluster log files </a> . </td> <td> RAM x 2 </td> <td> &gt;= RAM x 4 </td> </tr> <tr> <td> Persistent Storage </td> <td> Used for storing <a href="/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/"> snapshot (RDB format) and AOF files </a> over a persistent storage media, such as AWS Elastic Block Storage (EBS) or Azure Data Disk. </td> <td> RAM x 3 </td> <td> In-memory &gt;= RAM x 6 (except for <a href="/docs/latest/operate/rs/clusters/optimize/disk-sizing-heavy-write-scenarios/"> extreme 'write' scenarios </a> ) <br/> <br/> <a href="/docs/latest/operate/rs/databases/auto-tiering/"> Auto Tiering </a> &gt;= (RAM + Flash) x 5. </td> </tr> <tr> <td> Network </td> <td> We recommend using multiple NICs per node where each NIC is &gt;100Mbps, but Redis Enterprise SoftwareΒ can also run over a single 1Gbps interface network used for processing application requests, inter-cluster communication, and storage access. </td> <td> 1G </td> <td> &gt;=10G </td> </tr> </tbody> </table> <p> <sup> * </sup> Additional considerations: </p> <ul> <li> <p> Nodes per Cluster: </p> <ul> <li> <p> Clusters with more than 35 nodes are not supported. Please contact the Redis support team for assistance if your sizing calls for deploying a larger number of nodes. </p> </li> <li> <p> Quorum nodes also must comply with the above minimal hardware requirements. </p> </li> <li> <p> To ensure synchronization and consistency, Active-Active deployments with three-node clusters should not use quorum nodes. Because quorum nodes do not store data shards, they cannot support replication. In case of a node failure, replica shards aren't available for Active-Active synchronization. </p> </li> </ul> </li> <li> <p> Cores: </p> <ul> <li> <p> When the CPU load reaches a certain level, Redis Enterprise Software sends an alert to the operator. </p> </li> <li> <p> If your application is designed to put a lot of load on your Redis database, make sure that you have at least one available core for each shard of your database. </p> </li> <li> <p> If some of the cluster nodes are utilizing more than 80% of the CPU, consider migrating busy resources to less busy nodes. </p> </li> <li> <p> If all the cluster nodes are utilizing over 80% of the CPU, consider scaling out the cluster by <a href="/docs/latest/operate/rs/clusters/add-node/"> adding a node </a> . </p> </li> </ul> </li> <li> <p> RAM: </p> <ul> <li> <p> Redis uses a relatively large number of buffers, which enable replica communication, client communication, pub/sub commands, and more. As a result, you should ensure that 30% of the RAM is available on each node at any given time. </p> </li> <li> <p> If one or more cluster nodes utilizes more than 65% of the RAM, consider migrating resources to less active nodes. </p> </li> <li> <p> If all cluster nodes are utilizing more than 70% of available RAM, consider <a href="/docs/latest/operate/rs/clusters/add-node/"> adding a node </a> . </p> </li> <li> <p> Do not run any other memory-intensive processes on the Redis Enterprise Software node. </p> </li> </ul> </li> </ul> <h2 id="sizing-considerations"> Sizing considerations </h2> <h3 id="general-sizing"> General database sizing </h3> <p> Factors to consider when sizing your database. </p> <ul> <li> <strong> Dataset size </strong> – Your limit should be greater than your dataset size to leave room for overhead. </li> <li> <strong> Database throughput </strong> – High throughput needs more shards, leading to a higher memory limit. </li> <li> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/"> <strong> Modules </strong> </a> – Using modules with your database consumes more memory. </li> <li> <a href="/docs/latest/operate/rs/databases/durability-ha/clustering/"> <strong> Database clustering </strong> </a> – Allows you to spread your data into shards across multiple nodes. </li> <li> <a href="/docs/latest/operate/rs/databases/durability-ha/replication/"> <strong> Database replication </strong> </a> – Enabling replication doubles memory consumption. </li> </ul> <h3 id="active-active-sizing"> Active-Active database sizing </h3> <p> Additional factors for sizing Active-Active databases: </p> <ul> <li> <a href="/docs/latest/operate/rs/databases/active-active/"> <strong> Active-Active replication </strong> </a> – Requires double the memory of regular replication, which can be up to two times (2x) the original data size per instance. </li> <li> <a href="/docs/latest/operate/rs/databases/durability-ha/replication/#database-replication-backlog"> <strong> Database replication backlog </strong> </a> – For synchronization between shards. By default, this is set to 1% of the database size. </li> <li> <a href="/docs/latest/operate/rs/databases/active-active/manage/#replication-backlog"> <strong> Active-Active replication backlog </strong> </a> – For synchronization between clusters. By default, this is set to 1% of the database size. </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Active-Active databases have a lower threshold for activating the eviction policy, because it requires propagation to all participating clusters. The eviction policy starts to evict keys when one of the Active-Active instances reaches 80% of its memory limit. </div> </div> <h3 id="redis-on-flash-sizing"> Sizing databases with Auto Tiering enabled </h3> <p> Additional factors for sizing databases with Auto Tiering enabled: </p> <ul> <li> <a href="/docs/latest/operate/rs/databases/configure/database-persistence/#redis-on-flash-data-persistence"> <strong> Database persistence </strong> </a> – Auto Tiering uses dual database persistence where both the primary and replica shards persist to disk. This may add some processor and network overhead, especially in cloud configurations with network-attached storage. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/hardware-requirements/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/develop/tools/insight/release-notes/v.2.36.0/.html
<section class="prose w-full py-12"> <h1> RedisInsight v2.36.0, October 2023 </h1> <p class="text-lg -mt-5 mb-10"> RedisInsight v2.36 </p> <h2 id="236-october-2023"> 2.36 (October 2023) </h2> <p> This is the General Availability (GA) release of RedisInsight 2.36. </p> <h3 id="highlights"> Highlights </h3> <ul> <li> Optimizations for efficient handling of big <a href="https://redis.io/docs/data-types/strings/"> Redis strings </a> : choose to either view the string value for up to a maximum of 5,000 characters or download the data fully as a file if it exceeds the limit </li> <li> Improved security measurement to no longer display in plain text existing database passwords, SSH passwords, passphrases, and private keys </li> </ul> <h3 id="details"> Details </h3> <p> <strong> Features and improvements </strong> </p> <ul> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2685"> #2685 </a> , <a href="https://github.com/RedisInsight/RedisInsight/pull/2686"> #2686 </a> Added optimizations for working with big <a href="https://redis.io/docs/data-types/strings/"> Redis strings </a> . Users can now choose to either view the data up to a maximum of 5,000 characters or download it in a file fully if it exceeds the limit. </li> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2647"> #2647 </a> Improved security measurement to no longer expose the existing database passwords, SSH passwords, passphrases, and private keys in plain text </li> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2631"> #2631 </a> Added proactive notification to restart the application when a new version becomes available </li> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2705"> #2705 </a> Basic support in the <a href="https://redis.io/docs/interact/search-and-query/"> search index </a> creation form (in Browser) to enable <a href="https://redis.io/commands/ft.create/#:~:text=Vector%20Fields.-,GEOSHAPE,-%2D%20Allows%20polygon%20queries"> geo polygon </a> search </li> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2681"> #2681 </a> Updated the Pickle formatter to <a href="https://github.com/RedisInsight/RedisInsight/issues/2260"> support </a> Pickle protocol 5 </li> </ul> <p> <strong> Bugs </strong> </p> <ul> <li> <a href="https://github.com/RedisInsight/RedisInsight/pull/2675"> #2675 </a> Show the "Scan more" control until the cursor returned by the server is 0 to fix <a href="https://github.com/RedisInsight/RedisInsight/issues/2618"> cases </a> when not all keys are displayed. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/tools/insight/release-notes/v.2.36.0/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/discard/.html
<section class="prose w-full py-12"> <h1 class="command-name"> DISCARD </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">DISCARD</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 2.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N), when N is the number of queued commands </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @fast </code> <span class="mr-1 last:hidden"> , </span> <code> @transaction </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Flushes all previously queued commands in a <a href="/develop/interact/transactions"> transaction </a> and restores the connection state to normal. </p> <p> If <a href="/docs/latest/commands/watch/"> <code> WATCH </code> </a> was used, <code> DISCARD </code> unwatches all keys watched by the connection. </p> <h2 id="resp2resp3-reply"> RESP2/RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#simple-strings"> Simple string reply </a> : <code> OK </code> . <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/discard/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.4-release-notes.html
<section class="prose w-full py-12 max-w-none"> <h1> RedisBloom 2.4 release notes </h1> <p class="text-lg -mt-5 mb-10"> Added t-digest - a probabilistic data structure for estimating quantiles based on a data stream or a large dataset of floating-point values. </p> <h2 id="requirements"> Requirements </h2> <p> RedisBloom v2.4.9 requires: </p> <ul> <li> Minimum Redis compatibility version (database): 6.0.16 </li> <li> Minimum Redis Enterprise Software version (cluster): 6.2.8 </li> </ul> <h2 id="v249-march-2024"> v2.4.9 (March 2024) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> MODERATE </code> : Program an upgrade of the server, but it's not urgent. </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/issues/753"> #753 </a> Potential crash on <code> CMS.MERGE </code> when using invalid arguments </li> </ul> </li> </ul> <h2 id="v248-january-2024"> v2.4.8 (January 2024) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/pull/727"> #727 </a> Additional fixes for potential crash on <code> CF.LOADCHUNK </code> (MOD-6344) </li> </ul> </li> </ul> <h2 id="v247-january-2024"> v2.4.7 (January 2024) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> HIGH </code> : There is a critical bug that may affect a subset of users. Upgrade! </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/pull/735"> #735 </a> Potential crash on <code> CF.RESERVE </code> (MOD-6343) </li> <li> <a href="https://github.com/RedisBloom/RedisBloom/pull/727"> #727 </a> Potential crash on <code> CF.LOADCHUNK </code> (MOD-6344) </li> </ul> </li> </ul> <h2 id="v246-december-2023"> v2.4.6 (December 2023) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> LOW </code> : No need to upgrade unless there are new features you want to use. </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/pull/707"> #707 </a> Top-K: <code> TOPK.ADD </code> and <code> TOPK.QUERY </code> crash when an item name is an empty string (RED-114676) </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/pull/706"> #706 </a> Added support for CBL-Mariner 2 (MOD-6200) </li> </ul> </li> </ul> <h2 id="v245-april-2023"> v2.4.5 (April 2023) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> LOW </code> : No need to upgrade unless there are new features you want to use. </p> <p> Details: </p> <ul> <li> <p> Improvements: </p> <ul> <li> Internal changes for supporting future Redis Enterprise releases </li> </ul> </li> </ul> <h2 id="v244-february-2023"> v2.4.4 (February 2023) </h2> <p> This is a maintenance release for RedisBloom 2.4. </p> <p> Update urgency: <code> MODERATE </code> : Program an upgrade of the server, but it's not urgent. </p> <p> Details: </p> <ul> <li> <p> Bug fixes: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/issues/609"> #609 </a> <a href="/docs/latest/commands/cf.info"> CF.INFO </a> - incorrect information for large filters </li> </ul> </li> <li> <p> Improvements: </p> <ul> <li> <a href="https://github.com/RedisBloom/RedisBloom/issues/389"> #389 </a> Introduce <a href="/docs/latest/commands/bf.card"> BF.CARD </a> to retrieve the cardinality of a Bloom filter or 0 when such key does not exist </li> </ul> </li> </ul> <h2 id="v24-ga-v243-november-2022"> v2.4 GA (v2.4.3) (November 2022) </h2> <p> This is the General Availability release of RedisBloom 2.4. </p> <h3 id="highlights"> Highlights </h3> <p> RedisBloom 2.4 introduces a new sketch data structure: <strong> t-digest </strong> . </p> <h3 id="whats-new-in-24"> What's new in 2.4 </h3> <p> <a href="https://www.sciencedirect.com/science/article/pii/S2665963820300403"> t-digest </a> is a probabilistic data structure for estimating quantiles based on a data stream or a large dataset of floating-point values. It can be used to answer the following questions: </p> <ul> <li> What fraction of the values in the data stream are smaller than a given value? </li> <li> How many values in the data stream are smaller than a given value? </li> <li> Which value is smaller than <em> p </em> percent of the values in the data stream? (what is the <em> p </em> -percentile value)? </li> <li> What is the mean value between the <em> p1 </em> -percentile value and the <em> p2 </em> -percentile value? </li> <li> What is the value of the <em> n </em> -th smallest / largest value in the data stream? (what is the value with [reverse] rank <em> n </em> )? </li> </ul> <p> As for any other probabilistic data structures, t-digest requires sublinear space and has controllable space-accuracy tradeoffs. </p> <p> Using t-digest is simple and straightforward: </p> <ul> <li> <p> <strong> Creating a sketch and adding observations </strong> </p> <p> <code> TDIGEST.CREATE key [COMPRESSION compression] </code> initializes a new t-digest sketch (and errors if the key already exists). The <code> COMPRESSION </code> argument is used to specify the tradeoff between accuracy and memory consumption. The default is 100. Higher values mean more accuracy. </p> <p> <code> TDIGEST.ADD key value... </code> adds new observations (floating-point values) to the sketch. You can repeat calling <a href="/docs/latest/commands/tdigest.add"> TDIGEST.ADD </a> whenever new observations are available. </p> </li> <li> <p> <strong> Estimating fractions or ranks by values </strong> </p> <p> Use <code> TDIGEST.CDF key value... </code> to retrieve, for each input <strong> value </strong> , an estimation of the <strong> fraction </strong> of (observations <strong> smaller </strong> than the given value + half the observations equal to the given value). </p> <p> <code> TDIGEST.RANK key value... </code> is similar to <a href="/docs/latest/commands/tdigest.cdf"> TDIGEST.CDF </a> , but used for estimating the number of observations instead of the fraction of observations. More accurately it returns, for each input <strong> value </strong> , an estimation of the <strong> number </strong> of (observations <strong> smaller </strong> than a given value + half the observations equal to the given value). </p> <p> And lastly, <code> TDIGEST.REVRANK key value... </code> is similar to <a href="/docs/latest/commands/tdigest.rank"> TDIGEST.RANK </a> , but returns, for each input <strong> value </strong> , an estimation of the <strong> number </strong> of (observations <strong> larger </strong> than a given value + half the observations equal to the given value). </p> </li> <li> <p> <strong> Estimating values by fractions or ranks </strong> </p> <p> <code> TDIGEST.QUANTILE key fraction... </code> returns, for each input <strong> fraction </strong> , an estimation of the <strong> value </strong> (floating point) that is <strong> smaller </strong> than the given fraction of observations. </p> <p> <code> TDIGEST.BYRANK key rank... </code> returns, for each input <strong> rank </strong> , an estimation of the <strong> value </strong> (floating point) with that rank. </p> <p> <code> TDIGEST.BYREVRANK key rank... </code> returns, for each input <strong> reverse rank </strong> , an estimation of the <strong> value </strong> (floating point) with that reverse rank. </p> </li> <li> <p> <strong> Estimating trimmed mean </strong> </p> <p> Use <code> TDIGEST.TRIMMED_MEAN key lowFraction highFraction </code> to retrieve an estimation of the mean value between the specified fractions. </p> <p> This is especially useful for calculating the average value ignoring outliers. For example, calculating the average value between the 20th percentile and the 80th percentile. </p> </li> <li> <p> <strong> Merging sketches </strong> </p> <p> Sometimes it is useful to merge sketches. For example, suppose we measure latencies for 3 servers, and we want to calculate the 90%, 95%, and 99% latencies for all the servers combined. </p> <p> <code> TDIGEST.MERGE destKey numKeys sourceKey... [COMPRESSION compression] [OVERRIDE] </code> merges multiple sketches into a single sketch. </p> <p> If <code> destKey </code> does not exist, a new sketch is created. </p> <p> If <code> destKey </code> is an existing sketch, its values are merged with the values of the source keys. To override the destination key contents, use <code> OVERRIDE </code> . </p> </li> <li> <p> <strong> Retrieving sketch information </strong> </p> <p> Use <code> TDIGEST.MIN </code> key and <code> TDIGEST.MAX key </code> to retrieve the minimal and maximal values in the sketch, respectively. </p> <p> Both return NaN (Not a Number) when the sketch is empty. </p> <p> Both commands return accurate results and are equivalent to <code> TDIGEST.BYRANK key 0 </code> and <code> TDIGEST.BYREVRANK key 0 </code> respectively. </p> <p> Use <code> TDIGEST.INFO key </code> to retrieve some additional information about the sketch. </p> </li> <li> <p> <strong> Resetting a sketch </strong> </p> <p> <code> TDIGEST.RESET key </code> empties the sketch and reinitializes it. </p> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.4-release-notes/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/api/examples/update-database/.html
<section class="prose w-full py-12 max-w-none"> <h1> Update databases </h1> <p class="text-lg -mt-5 mb-10"> How to construct requests that update an existing database. </p> <p> The API operation that updates an existing database is: <code> PUT /subscriptions/{subscription-id}/databases/{database-id} </code> </p> <p> This API operation uses the same <a href="/docs/latest/operate/rc/api/get-started/process-lifecycle/"> provisioning lifecycle </a> as the <a href="/docs/latest/operate/rc/api/examples/create-database/"> create database </a> operation. The examples in this article refer to Redis Cloud Pro databases. </p> <h2 id="database-update-request-json-body"> Database update request JSON body </h2> <p> The primary component of a database update request is the JSON request body that contains the details of the requested database changes. </p> <p> You can see <a href="/docs/latest/operate/rc/api/get-started/use-rest-api/#inputs-for-operations-in-swagger"> the complete set of JSON elements </a> accepted by the database update API operation in the <a href="https://api.redislabs.com/v1/swagger-ui.html"> Swagger UI </a> . To see the JSON elements, expand the specific API operation and, in the request section, click <strong> Model </strong> . </p> <p> Here are several examples of JSON requests to update a database: </p> <h3 id="add-or-remove-replica-of"> Add or remove Replica Of </h3> <p> Setting one or more source Redis databases configures the updated database as a Replica Of destination database for the specified Redis databases. </p> <h4 id="add-a-source-database"> Add a source database </h4> <p> The following JSON request specifies two source databases for the updated database: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replicaOf"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="s2">"redis://redis-12345.c9876.us-east-1-mz.ec2.cloud.rlrcp.com:12345"</span> </span></span><span class="line"><span class="cl"> <span class="p">,</span> <span class="s2">"redis://redis-54321.internal.c9876.us-east-1-mz.ec2.cloud.rlrcp.com:54321"</span> </span></span><span class="line"><span class="cl"> <span class="p">]</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <ul> <li> The <code> replicaOf </code> array contains one or more URIs with the format: <code> redis://user:password@host:port </code> </li> <li> If the URI provided belongs to the same account, you can provide just the host and port (example: <code> ["redis://endpoint1:6379', "redis://endpoint2:6380"] </code> ) </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> If a source database is already defined for a specific database, and the goal is to add an additional source database, the source databases URI for the existing source must be included in the database updates JSON request. </div> </div> <h4 id="remove-a-source-database"> Remove a source database </h4> <p> To remove a source database from the <code> replicaOf </code> list, submit a JSON request that does not include the specific source database URI. </p> <h5 id="example"> Example: </h5> <p> Given a database that has two defined source databases: </p> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replicaOf"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="s2">"redis://redis-12345.c9876.us-east-1-mz.ec2.cloud.rlrcp.com:12345"</span> </span></span><span class="line"><span class="cl"> <span class="p">,</span> <span class="s2">"redis://redis-54321.internal.c9876.us-east-1-mz.ec2.cloud.rlrcp.com:54321"</span> </span></span><span class="line"><span class="cl"> <span class="p">]</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <ul> <li> You can use this JSON request to remove one of the two source databases: </li> </ul> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replicaOf"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="s2">"redis://redis-12345.c9876.us-east-1-mz.ec2.cloud.rlrcp.com:12345"</span> </span></span><span class="line"><span class="cl"> <span class="p">]</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <ul> <li> You can use this JSON request to remove all source databases: </li> </ul> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replicaOf"</span><span class="p">:</span> <span class="p">[]</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="viewing-database-replica-of-information"> Viewing database Replica Of information </h4> <p> The API operation <code> GET /subscriptions/{subscription-id}/databases/{database-id} </code> returns information on a specific database, including the Replica Of endpoints defined for the specific database. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/api/examples/update-database/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/memtier-benchmark/.html
<section class="prose w-full py-12 max-w-none"> <h1> Benchmark an Auto Tiering enabled database </h1> <p> Auto Tiering on Redis Enterprise Software lets you use cost-effective Flash memory as a RAM extension for your database. </p> <p> But what does the performance look like as compared to a memory-only database, one stored solely in RAM? </p> <p> These scenarios use the <code> memtier_benchmark </code> utility to evaluate the performance of a Redis Enterprise Software deployment, including the trial version. </p> <p> The <code> memtier_benchmark </code> utility is located in <code> /opt/redislabs/bin/ </code> of Redis Enterprise Software deployments. To test performance for cloud provider deployments, see the <a href="https://github.com/RedisLabs/memtier_benchmark"> memtier-benchmark GitHub project </a> . </p> <p> For additional, such as assistance with larger clusters, <a href="https://redislabs.com/company/support/"> contact support </a> . </p> <h2 id="benchmark-and-performance-test-considerations"> Benchmark and performance test considerations </h2> <p> These tests assume you're using a trial version of Redis Enterprise Software and want to test the performance of a Auto Tiering enabled database in the following scenarios: </p> <ul> <li> Without replication: Four (4) master shards </li> <li> With replication: Two (2) primary and two replica shards </li> </ul> <p> With the trial version of Redis Enterprise Software you can create a cluster of up to four shards using a combination of database configurations, including: </p> <ul> <li> Four databases, each with a single master shard </li> <li> Two highly available databases with replication enabled (each database has one master shard and one replica shard) </li> <li> One non-replicated clustered database with four master shards </li> <li> One highly available and clustered database with two master shards and two replica shards </li> </ul> <h2 id="test-environment-and-cluster-setup"> Test environment and cluster setup </h2> <p> For the test environment, you need to: </p> <ol> <li> Create a cluster with three nodes. </li> <li> Prepare the flash memory. </li> <li> Configure the load generation tool. </li> </ol> <h3 id="creating-a-threenode-rs-cluster"> Creating a three-node cluster </h3> <p> This performance test requires a three-node cluster. </p> <p> You can run all of these tests on Amazon AWS with these hosts: </p> <ul> <li> <p> 2 x i3.2xlarge (8 vCPU, 61 GiB RAM, up to 10GBit, 1.9TB NMVe SSD) </p> <p> These nodes serve RoF data </p> </li> <li> <p> 1 x m4.large, which acts as a quorum node </p> </li> </ul> <p> To learn how to install Redis Enterprise Software and set up a cluster, see: </p> <ul> <li> <a href="/docs/latest/operate/rs/installing-upgrading/quickstarts/redis-enterprise-software-quickstart/"> Redis Enterprise Software quickstart </a> for a test installation </li> <li> <a href="/docs/latest/operate/rs/installing-upgrading/"> Install and upgrade </a> for a production installation </li> </ul> <p> These tests use a quorum node to reduce AWS EC2 instance use while maintaining the three nodes required to support a quorum node in case of node failure. Quorum nodes can be on less powerful instances because they do not have shards or support traffic. </p> <p> As of this writing, i3.2xlarge instances are required because they support NVMe SSDs, which are required to support RoF. Auto Tiering requires Flash-enabled storage, such as NVMe SSDs. </p> <p> For best results, compare performance of a Flash-enabled deployment to the performance in a RAM-only environment, such as a strictly on-premises deployment. </p> <h2 id="prepare-the-flash-memory"> Prepare the flash memory </h2> <p> After you install RS on the nodes, the flash memory attached to the i3.2xlarge instances must be prepared and formatted with the <code> /opt/redislabs/sbin/prepare_flash.sh </code> script. </p> <h2 id="set-up-the-load-generation-tool"> Set up the load generation tool </h2> <p> The memtier_benchmark load generator tool generates the load on the RoF databases. To use this tool, install RS on a dedicated instance that is not part of the RS cluster but is in the same region/zone/subnet of your cluster. We recommend that you use a relatively powerful instance to avoid bottlenecks at the load generation tool itself. </p> <p> For these tests, the load generation host uses a c4.8xlarge instance type. </p> <h2 id="database-configuration-parameters"> Database configuration parameters </h2> <h3 id="create-a-auto-tiering-test-database"> Create a Auto Tiering test database </h3> <p> You can use the Redis Enterprise Cluster Manager UI to create a test database. We recommend that you use a separate database for each test case with these requirements: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> With replication </strong> </th> <th> <strong> Without replication </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Name </td> <td> test-1 </td> <td> test-2 </td> <td> The name of the test database </td> </tr> <tr> <td> Memory limit </td> <td> 100 GB </td> <td> 100 GB </td> <td> The memory limit refers to RAM+Flash, aggregated across all the shards of the database, including master and replica shards. </td> </tr> <tr> <td> RAM limit </td> <td> 0.3 </td> <td> 0.3 </td> <td> RoF always keeps the Redis keys and Redis dictionary in RAM and additional RAM is required for storing hot values. For the purpose of these tests 30% RAM was calculated as an optimal value. </td> </tr> <tr> <td> Replication </td> <td> Enabled </td> <td> Disabled </td> <td> A database with no replication has only master shards. A database with replication has master and replica shards. </td> </tr> <tr> <td> Data persistence </td> <td> None </td> <td> None </td> <td> No data persistence is needed for these tests. </td> </tr> <tr> <td> Database clustering </td> <td> Enabled </td> <td> Enabled </td> <td> A clustered database consists of multiple shards. </td> </tr> <tr> <td> Number of (master) shards </td> <td> 2 </td> <td> 4 </td> <td> Shards are distributed as follows: <br/> - With replication: One master shard and one replica shard on each node <br/> - Without replication: Two master shards on each node </td> </tr> <tr> <td> Other parameters </td> <td> Default </td> <td> Default </td> <td> Keep the default values for the other configuration parameters. </td> </tr> </tbody> </table> <h2 id="data-population"> Data population </h2> <h3 id="populate-the-benchmark-dataset"> Populate the benchmark dataset </h3> <p> The memtier_benchmark load generation tool populates the database. To populate the database with N itemsΒ of 500 Bytes each in size, on the load generation instance run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-maximum<span class="o">=</span><span class="nv">$N</span> -n allkeys -d <span class="m">500</span> --key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>1:0 </span></span></code></pre> </div> <p> Set up a test database: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Database host <br/> (-s) </td> <td> The fully qualified name of the endpoint or the IP shown in the RS database configuration </td> </tr> <tr> <td> Database port <br/> (-p) </td> <td> The endpoint port shown in your database configuration </td> </tr> <tr> <td> Number of items <br/> (–key-maximum) </td> <td> With replication: 75 Million <br/> Without replication: 150 Million </td> </tr> <tr> <td> Item size <br/> (-d) </td> <td> 500 Bytes </td> </tr> </tbody> </table> <h2 id="centralize-the-keyspace"> Centralize the keyspace </h2> <h3 id="centralize-with-repl"> With replication </h3> <p> To create roughly 20.5 million items in RAM for your highly available clustered database with 75 million items, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-minimum<span class="o">=</span><span class="m">27250000</span> --key-maximum<span class="o">=</span><span class="m">47750000</span> -n allkeys </span></span><span class="line"><span class="cl">--key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>0:1 </span></span></code></pre> </div> <p> To verify the database values, use <strong> Values in RAM </strong> metric, which is available from the <strong> Metrics </strong> tab of your database in the Cluster Manager UI. </p> <h3 id="centralize-wo-repl"> Without replication </h3> <p> To create 41 million items in RAM without replication enabled and 150 million items, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-minimum<span class="o">=</span><span class="m">54500000</span> --key-maximum<span class="o">=</span><span class="m">95500000</span> -n allkeys </span></span><span class="line"><span class="cl">--key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>0:1 </span></span></code></pre> </div> <h2 id="test-runs"> Test runs </h2> <h3 id="generate-load"> Generate load </h3> <h4 id="generate-with-repl"> With replication </h4> <p> We recommend that you do a dry run and double check the RAM Hit Ratio on the <strong> Metrics </strong> screen in the Cluster Manager UI before you write down the test results. </p> <p> To test RoF with an 85% RAM Hit Ratio, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --pipeline<span class="o">=</span><span class="m">11</span> -c <span class="m">20</span> -t <span class="m">1</span> </span></span><span class="line"><span class="cl">-d <span class="m">500</span> --key-maximum<span class="o">=</span><span class="m">75000000</span> --key-pattern<span class="o">=</span>G:G --key-stddev<span class="o">=</span><span class="m">5125000</span> </span></span><span class="line"><span class="cl">--ratio<span class="o">=</span>1:1 --distinct-client-seed --randomize --test-time<span class="o">=</span><span class="m">600</span> </span></span><span class="line"><span class="cl">--run-count<span class="o">=</span><span class="m">1</span> --out-file<span class="o">=</span>test.out </span></span></code></pre> </div> <h4 id="generate-wo-repl"> Without replication </h4> <p> Here is the command for 150 million items: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --pipeline<span class="o">=</span><span class="m">24</span> -c <span class="m">20</span> -t <span class="m">1</span> </span></span><span class="line"><span class="cl">-d <span class="m">500</span> --key-maximum<span class="o">=</span><span class="m">150000000</span> --key-pattern<span class="o">=</span>G:G --key-stddev<span class="o">=</span><span class="m">10250000</span> </span></span><span class="line"><span class="cl">--ratio<span class="o">=</span>1:1 --distinct-client-seed --randomize --test-time<span class="o">=</span><span class="m">600</span> </span></span><span class="line"><span class="cl">--run-count<span class="o">=</span><span class="m">1</span> --out-file<span class="o">=</span>test.out </span></span></code></pre> </div> <p> Where: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Access pattern (--key-pattern) and standard deviation (--key-stddev) </td> <td> Controls the RAM Hit ratio after the centralization process is complete </td> </tr> <tr> <td> Number of threads (-t and -c)\ </td> <td> Controls how many connections are opened to the database, whereby the number of connections is the number of threads multiplied by the number of connections per thread (-t) and number of clients per thread (-c) </td> </tr> <tr> <td> Pipelining (--pipeline)\ </td> <td> Pipelining allows you to send multiple requests without waiting for each individual response (-t) and number of clients per thread (-c) </td> </tr> <tr> <td> Read\write ratio (--ratio)\ </td> <td> A value of 1:1 means that you have the same number of write operations as read operations (-t) and number of clients per thread (-c) </td> </tr> </tbody> </table> <h2 id="test-results"> Test results </h2> <h3 id="monitor-the-test-results"> Monitor the test results </h3> <p> You can either monitor the results in the <strong> Metrics </strong> tab of the Cluster Manager UI or with the <code> memtier_benchmark </code> output. However, be aware that: </p> <ul> <li> <p> The memtier_benchmark results include the network latency between the load generator instance and the cluster instances. </p> </li> <li> <p> The metrics shown in the Cluster Manager UI do <em> not </em> include network latency. </p> </li> </ul> <h3 id="expected-results"> Expected results </h3> <p> You should expect to see an average throughput of: </p> <ul> <li> Around 160,000 ops/sec when testing without replication (i.e. Four master shards) </li> <li> Around 115,000 ops/sec when testing with enabled replication (i.e. 2 master and 2 replica shards) </li> </ul> <p> In both cases, the average latency should be below one millisecond. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/memtier-benchmark/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/kubernetes/logs/collect-logs/.html
<section class="prose w-full py-12 max-w-none"> <h1> Collect logs </h1> <p class="text-lg -mt-5 mb-10"> Run the log collector script to package relevant logs into a tar.gz file to send to Redis Support for help troubleshooting your Kubernetes environment. </p> <p> The Redis Enterprise cluster (REC) log collector script ( <a href="https://github.com/RedisLabs/redis-enterprise-k8s-docs/blob/master/log_collector/log_collector.py"> <code> log_collector.py </code> </a> ) creates and fills a directory with the relevant logs for your environment. These logs will help the support team with troubleshooting. </p> <p> As of version 6.2.18-3, the log collector tool has two modes: </p> <ul> <li> <strong> restricted </strong> collects only resources and logs created by the operator and Redis Enterprise deployments <ul> <li> This is the default for versions 6.2.18-3 and later </li> </ul> </li> <li> <strong> all </strong> collects everything from your environment <ul> <li> This is the default mode for versions 6.2.12-1 and earlier </li> </ul> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> This script requires Python 3.6 or later. </div> </div> <ol> <li> <p> Download the latest <a href="https://github.com/RedisLabs/redis-enterprise-k8s-docs/blob/master/log_collector/log_collector.py"> <code> log_collector.py </code> </a> file. </p> </li> <li> <p> Have a K8s administrator run the script on the system that runs your <code> kubectl </code> or <code> oc </code> commands. </p> <ul> <li> Pass <code> -n </code> parameter to run on a different namespace than the one you are currently on </li> <li> Pass <code> -m </code> parameter to change the log collector mode ( <code> all </code> or <code> restricted </code> ) </li> <li> Run with <code> -h </code> to see more options </li> </ul> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">python log_collector.py </span></span></code></pre> </div> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> If you get an error because the yaml module is not found, install the pyYAML module with <code> pip install pyyaml </code> . </div> </div> </li> <li> <p> Upload the resulting <code> tar.gz </code> file containing all the logs to <a href="https://support.redislabs.com/"> Redis Support </a> . </p> </li> </ol> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/kubernetes/logs/collect-logs/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/cf.del.html
<section class="prose w-full py-12"> <h1 class="command-name"> CF.DEL </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">CF.DEL key item</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 1.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(k), where k is the number of sub-filters </dd> </dl> <p> Deletes an item once from the filter. </p> <p> If the item exists only once, it will be removed from the filter. If the item was added multiple times, it will still be present. </p> <p> <note> <b> Note: </b> </note> </p> <ul> <li> Deleting an item that are not in the filter may delete a different item, resulting in false negatives. </li> </ul> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key name for a cuckoo filter. </p> </details> <details open=""> <summary> <code> item </code> </summary> <p> is an item to delete. </p> </details> <h2 id="complexity"> Complexity </h2> <p> O(n), where n is the number of <code> sub-filters </code> . Both alternative locations are checked on all <code> sub-filters </code> . </p> <h2 id="return-value"> Return value </h2> <p> Returns one of these replies: </p> <ul> <li> <a href="/docs/latest/develop/reference/protocol-spec/#integers"> Integer reply </a> - where "1" means that the item has been deleted, and "0" means that such item was not found in the filter </li> <li> [] on error (invalid arguments, wrong key type, etc.) </li> </ul> <h2 id="examples"> Examples </h2> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; CF.INSERT cf ITEMS item1 item2 item2 </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">3<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; CF.DEL cf item1 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; CF.DEL cf item1 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl">redis&gt; CF.DEL cf item2 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; CF.DEL cf item2 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; CF.DEL cf item2 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span></span></span></code></pre> </div> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/cf.del/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/.html
<section class="prose w-full py-12 max-w-none"> <h1> 6.4.2 release notes </h1> <p class="text-lg -mt-5 mb-10"> Release notes for the 6.4.2 releases of Redis Enterprise Software for Kubernetes. </p> <h2 id="before-upgrading"> Before upgrading </h2> <p> Be aware the following changes included in this release affect the upgrade process. Please read carefully before upgrading. </p> <h3 id="supported-upgrade-paths"> Supported upgrade paths </h3> <p> If you are using operator version 6.2.8-15 or earlier, you cannot upgrade directly to operator versions 6.2.12 through 6.4.2-5. You must upgrade to operator version 6.2.10-45 before you can upgrade to operator versions between 6.2.12 and 6.4.2-5. However, upgrades directly to operator version 6.4.2-6 are supported. </p> <h3 id="openshift-versions-6212-or-earlier"> OpenShift versions 6.2.12 or earlier </h3> <p> Due to a change in the SCC, on OpenShift clusters running version 6.2.12 or earlier upgrading to version 6.2.18 or later, where <code> node:1 </code> is <b> not </b> the master node, the upgrade might get stuck. </p> <p> For more info and steps to prevent this issue, see <a href="/docs/latest/operate/kubernetes/upgrade/upgrade-redis-cluster/#before-upgrading"> upgrade a Redis Enterprise cluster (REC) </a> . </p> <p> Operator version 6.4.2-6 includes a fix for this issue. </p> <h3 id="large-clusters"> Large clusters </h3> <p> On clusters with more than 9 REC nodes, a Kubernetes upgrade can render the Redis cluster unresponsive in some cases. A fix is available in the 6.4.2-5 release. Upgrade your operator version to 6.4.2-5 or later before upgrading your Kubernetes cluster. </p> <h2 id="security"> Security </h2> <p> For a list of fixes related to CVEs, see the <a href="/docs/latest/operate/rs/release-notes/rs-6-4-2-releases/"> Redis Enterprise 6.4.2 release notes </a> . </p> <table> <thead> <tr> <th style="text-align:left"> VersionΒ (ReleaseΒ date) </th> <th style="text-align:left"> Major changes </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/6-4-2-8-oct24/"> 6.4.2-8 (Oct 2024) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-8 release supports Redis Enterprise Software 6.4.2. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/6-4-2-8-dec23/"> 6.4.2-8 (Dec 2023) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-8 release supports Redis Enterprise Software 6.4.2 and contains new features and feature improvements. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/6-4-2-8/"> 6.4.2-8 (July 2023) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-8 release supports Redis Enterprise Software 6.4.2 and contains new features and feature improvements. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/6-4-2-6/"> 6.4.2-6 (June 2023) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-6 release supports Redis Enterprise Software 6.4.2 and contains new features and feature improvements. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/6-4-2-5/"> 6.4.2-5 (April 2023) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-5 is a maintenance release for version 6.4.2-4. </td> </tr> <tr> <td style="text-align:left"> <a href="/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/k8s-6-4-2-4/"> 6.4.2-4 (March 2023) </a> </td> <td style="text-align:left"> The Redis Enterprise K8s 6.4.2-4 release supports Redis Enterprise Software 6.4.2 and contains new features and feature improvements. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/kubernetes/release-notes/6-4-2-releases/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/clusters/configure/license-keys/.html
<section class="prose w-full py-12 max-w-none"> <h1> Cluster license keys </h1> <p class="text-lg -mt-5 mb-10"> The cluster key (or license) enables features and capacity within Redis Enterprise Software </p> <p> The cluster license key enables Redis Enterprise Software features and determines shard usage and limits. You can add or update a cluster key at any time. </p> <h2 id="trial-mode"> Trial mode </h2> <p> Trial mode allows all features to be enabled during the trial period. </p> <p> Trial mode is limited to 30 days and 4 shards, including master and replica shards. A new Redis Enterprise Software installation starts its 30-day trial period from the day you set up the cluster on the first node. </p> <p> Trial mode requires a trial license. If you do not provide a license when you create a cluster using the Cluster Manager UI or a <a href="/docs/latest/operate/rs/references/rest-api/requests/bootstrap/#post-bootstrap"> bootstrapping REST API request </a> , a trial cluster license is generated by default. </p> <h2 id="view-cluster-license-key"> View cluster license key </h2> <p> To view the cluster license key, use: </p> <ul> <li> <p> Cluster Manager UI </p> <ol> <li> <p> Go to <strong> Cluster &gt; Configuration &gt; General &gt; License </strong> to see the cluster license details. </p> </li> <li> <p> Select <strong> Change </strong> to view the cluster license key. </p> </li> </ol> </li> <li> <p> REST API - <a href="/docs/latest/operate/rs/references/rest-api/requests/license/#get-license"> <code> GET /v1/license </code> </a> </p> <p> For a list of returned fields, see the <a href="/docs/latest/operate/rs/references/rest-api/requests/license/#get-response"> response section </a> . </p> </li> </ul> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> As of version 7.2, Redis Enterprise enforces shard limits by shard types, RAM or flash, instead of the total number of shards. The flash shards limit only appears in the UI if Auto Tiering is enabled. </div> </div> <h2 id="update-cluster-license"> Update cluster license </h2> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> After you add a cluster key, you cannot remove the key to return the cluster to trial mode. </div> </div> <p> You can update the cluster license key: </p> <ul> <li> <p> During cluster setup using the Cluster Manager UI or CLI </p> </li> <li> <p> After cluster setup using the Cluster Manager UI: </p> <ol> <li> <p> Go to <strong> Cluster &gt; Configuration &gt; General &gt; License </strong> . </p> </li> <li> <p> Select <strong> Change </strong> . </p> </li> <li> <p> Upload or enter your cluster license key. </p> </li> <li> <p> Select <strong> Save </strong> . </p> </li> </ol> </li> </ul> <p> You can update an existing cluster key at any time. Redis Enterprise checks its validity for the following: </p> <ul> <li> Cluster name </li> <li> Activation and expiration dates </li> <li> Shard usage and limits </li> <li> Features </li> </ul> <p> If saving a new cluster key fails, the operation returns an error with the failure's cause. In this case, the existing key stays in effect. </p> <h2 id="expired-cluster-license"> Expired cluster license </h2> <p> When the license is expired: </p> <ul> <li> <p> You cannot do these actions: </p> <ul> <li> <p> Change database settings, including security and configuration options. </p> </li> <li> <p> Add a database. </p> </li> </ul> </li> <li> <p> You can do these actions: </p> <ul> <li> <p> Sign in to the Cluster Manager UI and view settings and metrics at all resolutions for the cluster, nodes, and databases. </p> </li> <li> <p> Change cluster settings, including the license key, security for administrators, and cluster alerts. </p> </li> <li> <p> Fail over when a node fails and explicitly migrate shards between nodes. </p> </li> <li> <p> Upgrade a node to a new version of Redis Enterprise Software. </p> </li> </ul> </li> </ul> <h2 id="configure-license-expiration-alert"> Configure license expiration alert </h2> <p> By default, a cluster license alert is scheduled to occur 7 days before the cluster license expiration date. </p> <a href="/docs/latest/images/rs/screenshots/cluster/cluster-license-expiration-alert.png" sdata-lightbox="/images/rs/screenshots/cluster/cluster-license-expiration-alert.png"> <img alt="An alert appears in the Cluster Manager UI that says 'Your license will expire on day-month-year time. Contact support to renew your license.'" src="/docs/latest/images/rs/screenshots/cluster/cluster-license-expiration-alert.png"/> </a> <p> You can adjust the threshold value of the cluster license expiration alert based on how far in advance you want to be notified of the license expiration. The value should be within a reasonable range that allows your organization enough time to take action, such as renewing the license, before it expires. </p> <p> To change the cluster license alert settings, use one of the following methods: </p> <ul> <li> <p> Cluster Manager UI: </p> <ol> <li> <p> On the <strong> Cluster &gt; Configuration </strong> screen, select the <strong> Alerts Settings </strong> tab. </p> </li> <li> <p> Click <strong> Edit </strong> . </p> </li> <li> <p> In the <strong> Cluster utilization </strong> section, enable the alert setting "License expiry notifications will be sent &lt;value&gt; days before the license expires" and enter a new value in the box. </p> <a href="/docs/latest/images/rs/screenshots/cluster/cluster-config-alert-settings-utilization.png" sdata-lightbox="/images/rs/screenshots/cluster/cluster-config-alert-settings-utilization.png"> <img alt="Cluster utilization alert settings." src="/docs/latest/images/rs/screenshots/cluster/cluster-config-alert-settings-utilization.png"/> </a> </li> <li> <p> Click <strong> Save </strong> . </p> </li> </ol> </li> <li> <p> <a href="/docs/latest/operate/rs/references/rest-api/requests/cluster/#put-cluster"> Update cluster </a> REST API request: </p> <p> The following example changes the cluster license alert to occur 30 days before the cluster license expiration date: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /v1/cluster </span></span><span class="line"><span class="cl"><span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="s2">"alert_settings"</span>: <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="s2">"cluster_license_about_to_expire"</span>: <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="s2">"enabled"</span>: true, </span></span><span class="line"><span class="cl"> <span class="s2">"threshold"</span>: <span class="s2">"30"</span> </span></span><span class="line"><span class="cl"> <span class="o">}</span> </span></span><span class="line"><span class="cl"> <span class="o">}</span> </span></span><span class="line"><span class="cl"><span class="o">}</span> </span></span></code></pre> </div> </li> </ul> <h2 id="monitor-cluster-license"> Monitor cluster license </h2> <p> As of version 7.2, Redis Enterprise exposes the license quotas and the shards consumption metrics in the Cluster Manager UI or via the <a href="/docs/latest/integrate/prometheus-with-redis-enterprise/"> Prometheus integration </a> . </p> <p> The <code> cluster_shards_limit </code> metric displays the total shard limit by shard type. </p> <p> Examples: </p> <ul> <li> <code> cluster_shards_limit{cluster="mycluster.local",shard_type="ram"} 100.0 </code> </li> <li> <code> cluster_shards_limit{cluster="mycluster.local",shard_type="flash"} 50.0 </code> </li> </ul> <p> The <code> bdb_shards_used </code> metric displays the used shard count by database and shard type. </p> <p> Examples: </p> <ul> <li> <code> bdb_shards_used{bdb="2",cluster="mycluster.local",shard_type="ram"} 86.0 </code> </li> <li> <code> bdb_shards_used{bdb="3",cluster="mycluster.local",shard_type="flash"} 23.0 </code> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/clusters/configure/license-keys/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/cf.mexists.html
<section class="prose w-full py-12"> <h1 class="command-name"> CF.MEXISTS </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">CF.MEXISTS key item [item ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 1.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(k * n), where k is the number of sub-filters and n is the number of items </dd> </dl> <p> Determines whether one or more items were added to a cuckoo filter. </p> <p> This command is similar to <a href="/docs/latest/commands/cf.exists/"> <code> CF.EXISTS </code> </a> , except that more than one item can be checked. </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key name for a cuckoo filter. </p> </details> <details open=""> <summary> <code> item... </code> </summary> <p> One or more items to check. </p> </details> <h2 id="return-value"> Return value </h2> <p> Returns one of these replies: </p> <ul> <li> <a href="/docs/latest/develop/reference/protocol-spec/#arrays"> Array reply </a> of <a href="/docs/latest/develop/reference/protocol-spec/#integers"> Integer reply </a> - where "1" means that, with high probability, <code> item </code> was already added to the filter, and "0" means that <code> key </code> does not exist or that <code> item </code> had not added to the filter. See note in <a href="/docs/latest/commands/cf.del/"> <code> CF.DEL </code> </a> . </li> <li> [] on error (invalid arguments, wrong key type, etc.) </li> </ul> <h2 id="examples"> Examples </h2> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; CF.INSERT cf ITEMS item1 item2 </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; CF.MEXISTS cf item1 item2 item3 </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">3<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span></span></span></code></pre> </div> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/cf.mexists/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/json.toggle.html
<section class="prose w-full py-12"> <h1 class="command-name"> JSON.TOGGLE </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">JSON.TOGGLE key path</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/json"> JSON 2.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) when path is evaluated to a single value, O(N) when path is evaluated to multiple values, where N is the size of the key </dd> </dl> <p> Toggle a Boolean value stored at <code> path </code> </p> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key to modify. </p> </details> <h2 id="optional-arguments"> Optional arguments </h2> <details open=""> <summary> <code> path </code> </summary> <p> is JSONPath to specify. Default is root <code> $ </code> . </p> </details> <h2 id="return"> Return </h2> <p> JSON.TOGGLE returns an array of integer replies for each path, the new value ( <code> 0 </code> if <code> false </code> or <code> 1 </code> if <code> true </code> ), or <code> nil </code> for JSON values matching the path that are not Boolean. For more information about replies, see <a href="/docs/latest/develop/reference/protocol-spec/"> Redis serialization protocol specification </a> . </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Toogle a Boolean value stored at <code> path </code> </b> </summary> <p> Create a JSON document. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.SET doc $ <span class="s1">'{"bool": true}'</span> </span></span><span class="line"><span class="cl">OK</span></span></code></pre> </div> <p> Toggle the Boolean value. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.TOGGLE doc $.bool </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span></span></span></code></pre> </div> <p> Get the updated document. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.GET doc $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"bool\":false}]"</span></span></span></code></pre> </div> <p> Toggle the Boolean value. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.TOGGLE doc $.bool </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span></span></span></code></pre> </div> <p> Get the updated document. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.GET doc $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"bool\":true}]"</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/json.set/"> <code> JSON.SET </code> </a> | <a href="/docs/latest/commands/json.get/"> <code> JSON.GET </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <ul> <li> <a href="/docs/latest/develop/data-types/json/"> RedisJSON </a> </li> <li> <a href="/docs/latest/develop/interact/search-and-query/indexing/"> Index and search JSON documents </a> </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/json.toggle/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/.html
<section class="prose w-full py-12 max-w-none"> <h1> Persistent and ephemeral node storage </h1> <p class="text-lg -mt-5 mb-10"> Configure paths for persistent storage and ephemeral storage. </p> <p> For each node in the cluster, you can configure paths for both persistent storage and ephemeral storage. To do so, the volume must have full permissions for user and group <code> redislabs </code> or users:group <code> redislabs:redislabs </code> . See the <a href="/docs/latest/operate/rs/7.4/installing-upgrading/install/customize-user-and-group/"> Customize system user and group </a> page for instructions. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> The persistent storageΒ and ephemeral storage discussed in this document are not related to Redis persistence or AWS ephemeral drives. </div> </div> <h2 id="persistent-storage"> Persistent storage </h2> <p> Persistent storage is mandatory. The cluster uses persistent storage to store information that needs to persist if a shard or a node fails, such as server logs, configurations, and files. </p> <p> To set the frequency of syncs, you can configure <a href="/docs/latest/operate/rs/7.4/databases/configure/database-persistence/"> persistence </a> options for a database. </p> <p> The persistent volume must be a storage area network (SAN) using an EXT4 or XFS file system and be connected as an external storage volume. </p> <p> When using append-only file (AOF) persistence, use flash-based storage for the persistent volume. </p> <h2 id="ephemeral-storage"> Ephemeral storage </h2> <p> Ephemeral storage is optional. If configured, temporary information that does not need to be persisted is stored by the cluster in the ephemeral storage. This improves performance and helps reduce the load on the persistent storage. </p> <p> Ephemeral storage must be a locally attached volume on each node. </p> <h2 id="disk-size-requirements"> Disk size requirements </h2> <p> For disk size requirements, see: </p> <ul> <li> <a href="/docs/latest/operate/rs/7.4/installing-upgrading/install/plan-deployment/hardware-requirements/"> Hardware requirements </a> for general guidelines regarding the ideal disk size for each type of storage. </li> <li> <a href="/docs/latest/operate/rs/7.4/clusters/optimize/disk-sizing-heavy-write-scenarios/"> Disk size requirements for extreme write scenarios </a> for special considerations when dealing with a high rate of write commands. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/crdb_task/.html
<section class="prose w-full py-12 max-w-none"> <h1> CRDB task object </h1> <p class="text-lg -mt-5 mb-10"> An object that represents a CRDB task </p> <p> An object that represents an Active-Active (CRDB) task. </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> id </td> <td> string </td> <td> CRDB task ID (read only) </td> </tr> <tr> <td> crdb_guid </td> <td> string </td> <td> Globally unique Active-Active database ID (GUID) (read-only) </td> </tr> <tr> <td> errors </td> <td> <pre><code> [{ "cluster_name": string, "description": string, "error_code": string }, ...] </code></pre> </td> <td> Details for errors that occurred on a cluster </td> </tr> <tr> <td> status </td> <td> 'queued' <br/> 'started' <br/> 'finished' <br/> 'failed' </td> <td> CRDB task status (read only) </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/crdb_task/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/security/encryption/.html
<section class="prose w-full py-12 max-w-none"> <h1> Encryption in Redis Enterprise Software </h1> <p class="text-lg -mt-5 mb-10"> Encryption in Redis Enterprise Software. </p> <p> Redis Enterprise Software uses encryption to secure communications between clusters, nodes, databases, and clients and to protect <a href="https://en.wikipedia.org/wiki/Data_in_transit"> data in transit </a> , <a href="https://en.wikipedia.org/wiki/Data_at_rest"> at rest </a> , and <a href="https://en.wikipedia.org/wiki/Data_in_use"> in use </a> . </p> <h2 id="encrypt-data-in-transit"> Encrypt data in transit </h2> <h3 id="tls"> TLS </h3> <p> Redis Enterprise Software uses <a href="/docs/latest/operate/rs/7.4/security/encryption/tls/"> Transport Layer Security (TLS) </a> to encrypt communications for the following: </p> <ul> <li> <p> Cluster Manager UI </p> </li> <li> <p> Command-line utilities </p> </li> <li> <p> REST API </p> </li> <li> <p> Internode communication </p> </li> </ul> <p> You can also <a href="/docs/latest/operate/rs/7.4/security/encryption/tls/enable-tls/"> enable TLS authentication </a> for the following: </p> <ul> <li> <p> Communication from clients or applications to your database </p> </li> <li> <p> Communication from your database to other clusters for replication using <a href="/docs/latest/operate/rs/7.4/databases/import-export/replica-of/"> Replica Of </a> </p> </li> <li> <p> Communication to and from your database to other clusters for <a href="/docs/latest/operate/rs/7.4/databases/active-active/"> Active-Active </a> synchronization </p> </li> </ul> <h3 id="internode-encryption"> Internode encryption </h3> <p> <a href="/docs/latest/operate/rs/7.4/security/encryption/internode-encryption/"> Internode encryption </a> uses TLS to encrypt data in transit between cluster nodes. </p> <p> By default, internode encryption is enabled for the control plane, which manages the cluster and databases. If you also want to encrypt replication and proxy communications between database shards on different nodes, <a href="/docs/latest/operate/rs/7.4/security/encryption/internode-encryption/#enable-data-internode-encryption"> enable data internode encryption </a> . </p> <h3 id="require-https-for-rest-api-endpoints"> Require HTTPS for REST API endpoints </h3> <p> By default, the Redis Enterprise Software API supports communication over HTTP and HTTPS. However, you can <a href="/docs/latest/operate/rs/7.4/references/rest-api/encryption/"> turn off HTTP support </a> to ensure that API requests are encrypted. </p> <h2 id="encrypt-data-at-rest"> Encrypt data at rest </h2> <h3 id="file-system-encryption"> File system encryption </h3> <p> To encrypt data stored on disk, use file system-based encryption capabilities available on Linux operating systems before you install Redis Enterprise Software. </p> <h3 id="private-key-encryption"> Private key encryption </h3> <p> Enable PEM encryption to <a href="/docs/latest/operate/rs/7.4/security/encryption/pem-encryption/"> encrypt all private keys </a> on disk. </p> <h2 id="encrypt-data-in-use"> Encrypt data in use </h2> <h3 id="client-side-encryption"> Client-side encryption </h3> <p> Use client-side encryption to encrypt the data an application stores in a Redis database. The application decrypts the data when it retrieves it from the database. </p> <p> You can add client-side encryption logic to your application or use built-in client functions. </p> <p> Client-side encryption has the following limitations: </p> <ul> <li> <p> Operations that must operate on the data, such as increments, comparisons, and searches will not function properly. </p> </li> <li> <p> Increases management overhead. </p> </li> <li> <p> Reduces performance. </p> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/security/encryption/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/jvm/classes/gearsbuilder/accumulateby/.html
<section class="prose w-full py-12 max-w-none"> <h1> AccumulateBy </h1> <p class="text-lg -mt-5 mb-10"> Groups records and reduces each group to a single record per group. </p> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="kd">public</span> <span class="o">&lt;</span><span class="n">I</span> <span class="kd">extends</span> <span class="n">java</span><span class="o">.</span><span class="na">io</span><span class="o">.</span><span class="na">Serializable</span><span class="o">&gt;</span> <span class="n">GearsBuilder</span><span class="o">&lt;</span><span class="n">I</span><span class="o">&gt;</span> <span class="n">accumulateBy</span><span class="err">​</span><span class="o">(</span> </span></span><span class="line"><span class="cl"> <span class="n">gears</span><span class="o">.</span><span class="na">operations</span><span class="o">.</span><span class="na">ExtractorOperation</span><span class="o">&lt;</span><span class="n">T</span><span class="o">&gt;</span> <span class="n">extractor</span><span class="o">,</span> </span></span><span class="line"><span class="cl"> <span class="n">gears</span><span class="o">.</span><span class="na">operations</span><span class="o">.</span><span class="na">AccumulateByOperation</span><span class="o">&lt;</span><span class="n">T</span><span class="o">,</span><span class="err">​</span><span class="n">I</span><span class="o">&gt;</span> <span class="n">accumulator</span><span class="o">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="kd">public</span> <span class="o">&lt;</span><span class="n">I</span> <span class="kd">extends</span> <span class="n">java</span><span class="o">.</span><span class="na">io</span><span class="o">.</span><span class="na">Serializable</span><span class="o">&gt;</span> <span class="n">GearsBuilder</span><span class="o">&lt;</span><span class="n">I</span><span class="o">&gt;</span> <span class="n">accumulateBy</span><span class="err">​</span><span class="o">(</span> </span></span><span class="line"><span class="cl"> <span class="n">gears</span><span class="o">.</span><span class="na">operations</span><span class="o">.</span><span class="na">ValueInitializerOperation</span><span class="o">&lt;</span><span class="n">I</span><span class="o">&gt;</span> <span class="n">valueInitializer</span><span class="o">,</span> </span></span><span class="line"><span class="cl"> <span class="n">gears</span><span class="o">.</span><span class="na">operations</span><span class="o">.</span><span class="na">ExtractorOperation</span><span class="o">&lt;</span><span class="n">T</span><span class="o">&gt;</span> <span class="n">extractor</span><span class="o">,</span> </span></span><span class="line"><span class="cl"> <span class="n">gears</span><span class="o">.</span><span class="na">operations</span><span class="o">.</span><span class="na">AccumulateByOperation</span><span class="o">&lt;</span><span class="n">T</span><span class="o">,</span><span class="err">​</span><span class="n">I</span><span class="o">&gt;</span> <span class="n">accumulator</span><span class="o">)</span> </span></span></code></pre> </div> <p> Iterates through the records in the pipe, groups them based on the provided extractor, and then reduces each group to a single record per group with the accumulator function. </p> <p> The initial value of the accumulator is null unless you provide a value initializer operation as a parameter. </p> <h2 id="parameters"> Parameters </h2> <p> Type parameters: </p> <table> <thead> <tr> <th> Name </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> I </td> <td> The template type of the returned builder </td> </tr> </tbody> </table> <p> Function parameters: </p> <table> <thead> <tr> <th> Name </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> accumulator </td> <td> <nobr> AccumulateByOperation&lt;T,​I&gt; </nobr> </td> <td> A function with logic to update the accumulator value with each record </td> </tr> <tr> <td> extractor </td> <td> ExtractorOperation <t> </t> </td> <td> Extracts a specific value from each record </td> </tr> <tr> <td> valueInitializer </td> <td> ValueInitializerOperation <i> </i> </td> <td> Whenever the accumulated value is null, use this function to initialize it </td> </tr> </tbody> </table> <h2 id="returns"> Returns </h2> <p> Returns a GearsBuilder object with a new template type. </p> <h2 id="examples"> Examples </h2> <p> Both of the following examples count the number of unique values. </p> <p> Without the <code> valueInitializer </code> parameter: </p> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="n">GearsBuilder</span><span class="o">.</span><span class="na">CreateGearsBuilder</span><span class="o">(</span><span class="n">reader</span><span class="o">).</span> </span></span><span class="line"><span class="cl"> <span class="n">accumulateBy</span><span class="o">(</span><span class="n">r</span><span class="o">-&gt;{</span> </span></span><span class="line"><span class="cl"> <span class="k">return</span> <span class="n">r</span><span class="o">.</span><span class="na">getStringVal</span><span class="o">();</span> </span></span><span class="line"><span class="cl"> <span class="o">},(</span><span class="n">k</span><span class="o">,</span> <span class="n">a</span><span class="o">,</span> <span class="n">r</span><span class="o">)-&gt;{</span> </span></span><span class="line"><span class="cl"> <span class="n">Integer</span> <span class="n">ret</span> <span class="o">=</span> <span class="kc">null</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> <span class="k">if</span><span class="o">(</span><span class="n">a</span> <span class="o">==</span> <span class="kc">null</span><span class="o">)</span> <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="n">ret</span> <span class="o">=</span> <span class="mi">0</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> <span class="o">}</span><span class="k">else</span> <span class="o">{</span> </span></span><span class="line"><span class="cl"> <span class="n">ret</span> <span class="o">=</span> <span class="o">(</span><span class="n">Integer</span><span class="o">)</span><span class="n">a</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> <span class="o">}</span> </span></span><span class="line"><span class="cl"> <span class="k">return</span> <span class="n">ret</span> <span class="o">+</span> <span class="mi">1</span><span class="o">;</span> </span></span><span class="line"><span class="cl"><span class="o">});</span> </span></span></code></pre> </div> <p> With the <code> valueInitializer </code> parameter: </p> <div class="highlight"> <pre class="chroma"><code class="language-java" data-lang="java"><span class="line"><span class="cl"><span class="n">GearsBuilder</span><span class="o">.</span><span class="na">CreateGearsBuilder</span><span class="o">(</span><span class="n">reader</span><span class="o">).</span> </span></span><span class="line"><span class="cl"> <span class="n">accumulateBy</span><span class="o">(()-&gt;{</span> </span></span><span class="line"><span class="cl"> <span class="k">return</span> <span class="mi">0</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> <span class="o">},</span><span class="n">r</span><span class="o">-&gt;{</span> </span></span><span class="line"><span class="cl"> <span class="k">return</span> <span class="n">r</span><span class="o">.</span><span class="na">getStringVal</span><span class="o">();</span> </span></span><span class="line"><span class="cl"> <span class="o">},(</span><span class="n">k</span><span class="o">,</span> <span class="n">a</span><span class="o">,</span> <span class="n">r</span><span class="o">)-&gt;{</span> </span></span><span class="line"><span class="cl"> <span class="k">return</span> <span class="n">a</span> <span class="o">+</span> <span class="mi">1</span><span class="o">;</span> </span></span><span class="line"><span class="cl"> <span class="o">});</span> </span></span></code></pre> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/jvm/classes/gearsbuilder/accumulateby/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/security/access-control/create-combined-roles/.html
<section class="prose w-full py-12 max-w-none"> <h1> Create roles with combined access </h1> <p class="text-lg -mt-5 mb-10"> Create roles with both cluster and database access. </p> <p> To create a role that grants database access privileges and allows access to the Cluster Management UI and REST API: </p> <ol> <li> <p> <a href="#define-redis-acls"> Define Redis ACLs </a> that determine database access privileges. </p> </li> <li> <p> <a href="#create-role"> Create a role with ACLs </a> added and choose a <strong> Cluster management role </strong> other than <strong> None </strong> . </p> </li> </ol> <h2 id="define-redis-acls"> Define Redis ACLs </h2> <p> To define a Redis ACL rule that you can assign to a role: </p> <ol> <li> <p> From <strong> Access Control &gt; Redis ACLs </strong> , you can either: </p> <ul> <li> <p> Point to a Redis ACL and select <a href="/docs/latest/images/rs/buttons/edit-button.png#no-click" sdata-lightbox="/images/rs/buttons/edit-button.png#no-click"> <img alt="The Edit button" class="inline" src="/docs/latest/images/rs/buttons/edit-button.png#no-click" width="25px"/> </a> to edit an existing Redis ACL. </p> </li> <li> <p> Select <strong> + Add Redis ACL </strong> to create a new Redis ACL. </p> </li> </ul> </li> <li> <p> Enter a descriptive name for the Redis ACL. This will be used to associate the ACL rule with the role. </p> </li> <li> <p> Define the ACL rule. For more information about Redis ACL rules and syntax, see the <a href="/docs/latest/operate/rs/7.4/security/access-control/redis-acl-overview/"> Redis ACL overview </a> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> The <strong> ACL builder </strong> does not support selectors and key permissions. Use <strong> Free text command </strong> to manually define them instead. </div> </div> </li> <li> <p> Select <strong> Save </strong> . </p> </li> </ol> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> For multi-key commands on multi-slot keys, the return value is <code> failure </code> , but the command runs on the keys that are allowed. </div> </div> <h2 id="create-role"> Create roles with ACLs and cluster access </h2> <p> To create a role that grants database access privileges and allows access to the Cluster Management UI and REST API: </p> <ol> <li> <p> From <strong> Access Control </strong> &gt; <strong> Roles </strong> , you can: </p> <ul> <li> <p> Point to a role and select <a href="/docs/latest/images/rs/buttons/edit-button.png#no-click" sdata-lightbox="/images/rs/buttons/edit-button.png#no-click"> <img alt="The Edit button" class="inline" src="/docs/latest/images/rs/buttons/edit-button.png#no-click" width="25px"/> </a> to edit an existing role. </p> </li> <li> <p> Select <strong> + Add role </strong> to create a new role. </p> </li> </ul> <a href="/docs/latest/images/rs/access-control-role-panel.png" sdata-lightbox="/images/rs/access-control-role-panel.png"> <img alt="Add role with name" src="/docs/latest/images/rs/access-control-role-panel.png"/> </a> </li> <li> <p> Enter a descriptive name for the role. This will be used to reference the role when configuring users. </p> </li> <li> <p> Choose a <strong> Cluster management role </strong> other than <strong> None </strong> . For details about permissions granted by each role, see <a href="/docs/latest/operate/rs/7.4/security/access-control/create-cluster-roles/#cluster-manager-ui-permissions"> Cluster Manager UI permissions </a> and <a href="/docs/latest/operate/rs/7.4/references/rest-api/permissions/"> REST API permissions </a> . </p> <a href="/docs/latest/images/rs/screenshots/access-control/rbac-create-combined-role-select-cm-role.png" sdata-lightbox="/images/rs/screenshots/access-control/rbac-create-combined-role-select-cm-role.png"> <img alt="Add role with name" src="/docs/latest/images/rs/screenshots/access-control/rbac-create-combined-role-select-cm-role.png"/> </a> </li> <li> <p> Select <strong> + Add ACL </strong> . </p> <a href="/docs/latest/images/rs/access-control-role-acl.png" sdata-lightbox="/images/rs/access-control-role-acl.png"> <img alt="Add role database acl" src="/docs/latest/images/rs/access-control-role-acl.png"/> </a> </li> <li> <p> Choose a Redis ACL and databases to associate with the role. </p> <a href="/docs/latest/images/rs/screenshots/access-control/access-control-role-databases.png" sdata-lightbox="/images/rs/screenshots/access-control/access-control-role-databases.png"> <img alt="Add databases to access" src="/docs/latest/images/rs/screenshots/access-control/access-control-role-databases.png"/> </a> </li> <li> <p> Select the check mark <a href="/docs/latest/images/rs/buttons/checkmark-button.png#no-click" sdata-lightbox="/images/rs/buttons/checkmark-button.png#no-click"> <img alt="The Check button" class="inline" src="/docs/latest/images/rs/buttons/checkmark-button.png#no-click" width="25px"/> </a> to confirm. </p> </li> <li> <p> Select <strong> Save </strong> . </p> <a href="/docs/latest/images/rs/screenshots/access-control/rbac-save-combined-role.png" sdata-lightbox="/images/rs/screenshots/access-control/rbac-save-combined-role.png"> <img alt="Add databases to access" src="/docs/latest/images/rs/screenshots/access-control/rbac-save-combined-role.png"/> </a> </li> </ol> <p> You can <a href="/docs/latest/operate/rs/7.4/security/access-control/create-users/#assign-roles-to-users"> assign the new role to users </a> to grant database access and access to the Cluster Manager UI and REST API. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/security/access-control/create-combined-roles/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/.html
<section class="prose w-full py-12 max-w-none"> <h1> CLI reference </h1> <p class="text-lg -mt-5 mb-10"> Reference for the RDI CLI commands </p> <nav> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di/"> redis-di </a> <p> A command line tool to manage &amp; configure Redis Data Integration </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-add-context/"> redis-di add-context </a> <p> Adds a new context </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-config-rdi/"> redis-di config-rdi </a> <p> Configures RDI DB connection credentials </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-delete/"> redis-di delete </a> <p> Deletes RDI database permanently </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-delete-all-contexts/"> redis-di delete-all-contexts </a> <p> Deletes all contexts </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-delete-context/"> redis-di delete-context </a> <p> Deletes a context </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-deploy/"> redis-di deploy </a> <p> Deploys the RDI configurations including target </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-describe-job/"> redis-di describe-job </a> <p> Describes a transformation engine's job </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-dump-support-package/"> redis-di dump-support-package </a> <p> Dumps RDI support package </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-get-rejected/"> redis-di get-rejected </a> <p> Returns all the stored rejected entries </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-install/"> redis-di install </a> <p> Installs RDI </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-list-contexts/"> redis-di list-contexts </a> <p> Lists all saved contexts </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-list-jobs/"> redis-di list-jobs </a> <p> Lists transformation engine's jobs </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-reset/"> redis-di reset </a> <p> Resets the pipeline into initial full sync mode </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-scaffold/"> redis-di scaffold </a> <p> Generates configuration files for RDI </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-set-context/"> redis-di set-context </a> <p> Sets a context to be the active one </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-set-secret/"> redis-di set-secret </a> <p> Creates a secret of a specified key </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-start/"> redis-di start </a> <p> Starts the pipeline </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-status/"> redis-di status </a> <p> Displays the status of the pipeline end to end </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-stop/"> redis-di stop </a> <p> Stops the pipeline </p> <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-trace/"> redis-di trace </a> <p> Starts a trace session for troubleshooting data transformation </p> </nav> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-install/.html
<section class="prose w-full py-12"> <h1> redis-di install </h1> <p class="text-lg -mt-5 mb-10"> Installs RDI </p> <h2 id="usage"> Usage </h2> <pre tabindex="0"><code>Usage: redis-di install [OPTIONS] </code></pre> <h2 id="options"> Options </h2> <ul> <li> <p> <code> log_level </code> : </p> <ul> <li> Type: Choice(['DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL']) </li> <li> Default: <code> warn </code> </li> <li> Usage: <code> --log-level -l </code> </li> </ul> </li> <li> <p> <code> file </code> : </p> <ul> <li> Type: &lt;click.types.Path object at 0x7f99b7e778e0&gt; </li> <li> Default: <code> none </code> </li> <li> Usage: <code> -f --file </code> </li> </ul> <p> Path to a TOML configuration file for silent installation </p> </li> <li> <p> <code> online </code> : </p> <ul> <li> Type: BOOL </li> <li> Default: <code> false </code> </li> <li> Usage: <code> --online </code> </li> </ul> <p> Run installer in online mode </p> </li> <li> <p> <code> help </code> : </p> <ul> <li> Type: BOOL </li> <li> Default: <code> false </code> </li> <li> Usage: <code> --help </code> </li> </ul> <p> Show this message and exit. </p> </li> </ul> <h2 id="cli-help"> CLI help </h2> <pre tabindex="0"><code>Usage: redis-di install [OPTIONS] Installs RDI Options: -l, --log-level [DEBUG|INFO|WARN|ERROR|CRITICAL] [default: WARN] -f, --file FILE Path to a TOML configuration file for silent installation --help Show this message and exit. </code></pre> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-install/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/bf.add/.html
<section class="prose w-full py-12"> <h1 class="command-name"> BF.ADD </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">BF.ADD key item</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 1.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(k), where k is the number of hash functions used by the last sub-filter </dd> </dl> <p> Adds an item to a Bloom filter. </p> <p> This command is similar to <a href="/docs/latest/commands/bf.madd/"> <code> BF.MADD </code> </a> , except that only one item can be added. </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key name for a Bloom filter to add the item to. </p> <p> If <code> key </code> does not exist - a new Bloom filter is created with default error rate, capacity, and expansion (see <a href="/docs/latest/commands/bf.reserve/"> <code> BF.RESERVE </code> </a> ). </p> </details> <details open=""> <summary> <code> item </code> </summary> <p> is an item to add. </p> </details> <h2 id="return-value"> Return value </h2> <p> Returns one of these replies: </p> <ul> <li> <a href="/docs/latest/develop/reference/protocol-spec/#integers"> Integer reply </a> - where "1" means that the item has been added successfully, and "0" means that such item was already added to the filter (which could be wrong) </li> <li> [] on error (invalid arguments, wrong key type, etc.) and also when the filter is full </li> </ul> <h2 id="examples"> Examples </h2> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; BF.ADD bf item1 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">redis&gt; BF.ADD bf item1 </span></span><span class="line"><span class="cl"><span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span></span></span></code></pre> </div> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/bf.add/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/objects/db-conns-auditing-config/.html
<section class="prose w-full py-12 max-w-none"> <h1> Database connection auditing configuration object </h1> <p class="text-lg -mt-5 mb-10"> An object for database connection auditing settings </p> <p> Database connection auditing configuration </p> <table> <thead> <tr> <th> Name </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> audit_address </td> <td> string </td> <td> TCP/IP address where one can listen for notifications. </td> </tr> <tr> <td> audit_port </td> <td> integer </td> <td> Port where one can listen for notifications. </td> </tr> <tr> <td> audit_protocol </td> <td> <code> TCP </code> <br/> <code> local </code> </td> <td> Protocol used to process notifications. For production systems, <code> TCP </code> is the only valid value. </td> </tr> <tr> <td> audit_reconnect_interval </td> <td> integer </td> <td> Interval (in seconds) between attempts to reconnect to the listener. Default is 1 second. </td> </tr> <tr> <td> audit_reconnect_max_attempts </td> <td> integer </td> <td> Maximum number of attempts to reconnect. Default is 0 (infinite). </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/objects/db-conns-auditing-config/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/develop/data-types/timeseries/use_cases/.html
<section class="prose w-full py-12"> <h1> Use cases </h1> <p class="text-lg -mt-5 mb-10"> Time series use cases </p> <p> <strong> Monitoring (data center) </strong> </p> <p> Modern data centers have a lot of moving pieces, such as infrastructure (servers and networks) and software systems (applications and services) that need to be monitored around the clock. </p> <p> Redis Time Series allows you to plan for new resources upfront, optimize the utilization of existing resources, reconstruct the circumstances that led to outages, and identify application performance issues by analyzing and reporting on the following metrics: </p> <ul> <li> Maximum CPU utilization per server </li> <li> Maximum network latency between two services </li> <li> Average IO bandwidth utilization of a storage system </li> <li> 99th percentile of the response time of a specific application outages </li> </ul> <p> <strong> Weather analysis (environment) </strong> </p> <p> Redis Time Series can be used to track environmental measurements such as the number of daily sunshine hours and hourly rainfall depth, over a period of many years. Seasonally, you can measure average rainfall depth, average daily temperature, and the maximum number of sunny hours per day, for example. Watch the increase of the maximum daily temperature over the years. Predict the expected temperature and rainfall depth in a specific location for a particular week of the year. </p> <p> Multiple time series can be collected, each for a different location. By utilizing secondary indexes, measurements can be aggregated over given geographical regions (e.g., minimal and maximal daily temperature in Europe) or over locations with specific attributes (e.g., average rainfall depth in mountainous regions). </p> <p> Example metrics include: </p> <ul> <li> Rain (cm) </li> <li> Temperature (C) </li> <li> Sunny periods (h) </li> </ul> <p> <strong> Analysis of the atmosphere (environment) </strong> </p> <p> The atmospheric concentration of CO2 is more important than ever before. Use TimeSeries to track average, maximum and minimum CO2 level per season and average yearly CO2 over the last decades. Example metrics include: </p> <ul> <li> Concentration of CO2 (ppm) </li> <li> Location </li> </ul> <p> <strong> Flight data recording (sensor data and IoT) </strong> </p> <p> Planes have a multitude of sensors. This sensor data is stored in a black box and also shared with external systems. TimeSeries can help you reconstruct the sequence of events over time, optimize operations and maintenance intervals, improve safety, and provide feedback to the equipment manufacturers about the part quality. Example metrics include: </p> <ul> <li> Altitude </li> <li> Flight path </li> <li> Engine temperature </li> <li> Level of vibrations </li> <li> Pressure </li> </ul> <p> <strong> Ship logbooks (sensor data and IoT) </strong> </p> <p> It's very common to keep track of ship voyages via (digital) logbooks. Use TimeSeries to calculate optimal routes using these metrics: </p> <ul> <li> Wind (km/h) </li> <li> Ocean conditions (classes) </li> <li> Speed (knots) </li> <li> Location (long, lat) </li> </ul> <p> <strong> Connected car (sensor data and IoT) </strong> </p> <p> Modern cars are exposing several metrics via a standard interface. Use TimeSeries to correlate average fuel consumption with the tire pressure, figure out how long to keep a car in the fleet, determine optimal maintenance intervals, and calculate tax savings by type of the road (taxable vs. nontaxable roads). Example metrics include: </p> <ul> <li> Acceleration </li> <li> Location (long, lat) </li> <li> Fuel level (liter) </li> <li> Distances (km) </li> <li> Speed (km/h) </li> <li> Tire pressure </li> <li> Distance until next maintenance check </li> </ul> <p> <strong> Smart metering (sensor data and IoT) </strong> </p> <p> Modern houses and facilities gather details about energy consumption/production. Use Redis Time Series to aggregate billing based on monthly consumption. Optimize the network by redirecting the energy delivery relative to the fluctuations in need. Provide recommendations on how to improve the energy consumption behavior. Example metrics include: </p> <ul> <li> Consumption per location </li> <li> Produced amount of electrical energy per location </li> </ul> <p> <strong> Quality of service (telecom) </strong> </p> <p> Mobile phone usage is increasing, producing a natural growth that just correlates to the increasing number of cellphones. However, there might also be spikes that correlate with specific events (for example, more messages around world championships). </p> <p> Telecom providers need to ensure that they are providing the necessary infrastructure to deliver the right quality of service. This includes using mini towers for short-term peaks. Use TimeSeries to correlate traffic peaks to specific events, load balance traffic over several towers or mini towers, and predictively plan the infrastructure. Metrics include the amount of traffic per tower. </p> <p> <strong> Stock trading (finance) </strong> </p> <p> Stock trading is highly automated today. Algorithms, and not just human beings, are trading, from the amount of bids and asks for the trading of a stock to the extreme volumes of trades per second (millions of ops per second). Computer-driven trading requires millisecond response times. It's necessary to keep a lot of data points within a very short period of time (for example, price fluctuations per second within a minute). In addition, the long-term history needs to be kept to make statements about trends or for regulatory purposes. </p> <p> Use Redis Time Series to identify correlations between the trading behavior and other events (for example, social network posts). Discover a developing market. Detect anomalies to discover insider trades. Example metrics include: </p> <ul> <li> Exact time and order of a trade by itself </li> <li> Type of the event (trade/bid) </li> <li> The stock price </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/develop/data-types/timeseries/use_cases/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/json.set//.html
<section class="prose w-full py-12"> <h1 class="command-name"> JSON.SET </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">JSON.SET key path value [NX | XX]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/json"> JSON 1.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(M+N) when path is evaluated to a single value where M is the size of the original value (if it exists) and N is the size of the new value, O(M+N) when path is evaluated to multiple values where M is the size of the key and N is the size of the new value * the number of original values in the key </dd> </dl> <p> Set the JSON value at <code> path </code> in <code> key </code> </p> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> <p> is key to modify. </p> </details> <details open=""> <summary> <code> path </code> </summary> <p> is JSONPath to specify. Default is root <code> $ </code> . For new Redis keys the <code> path </code> must be the root. For existing keys, when the entire <code> path </code> exists, the value that it contains is replaced with the <code> json </code> value. For existing keys, when the <code> path </code> exists, except for the last element, a new child is added with the <code> json </code> value. </p> <p> Adds a key (with its respective value) to a JSON Object (in a RedisJSON data type key) only if it is the last child in the <code> path </code> , or it is the parent of a new child being added in the <code> path </code> . Optional arguments <code> NX </code> and <code> XX </code> modify this behavior for both new RedisJSON data type keys as well as the JSON Object keys in them. </p> </details> <details open=""> <summary> <code> value </code> </summary> <p> is value to set at the specified path </p> </details> <h2 id="optional-arguments"> Optional arguments </h2> <details open=""> <summary> <code> NX </code> </summary> <p> sets the key only if it does not already exist. </p> </details> <details open=""> <summary> <code> XX </code> </summary> <p> sets the key only if it already exists. </p> </details> <h2 id="return-value"> Return value </h2> <p> JSET.SET returns a simple string reply: <code> OK </code> if executed correctly or <code> nil </code> if the specified <code> NX </code> or <code> XX </code> conditions were not met. For more information about replies, see <a href="/docs/latest/develop/reference/protocol-spec/"> Redis serialization protocol specification </a> . </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Replace an existing value </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.SET doc $ <span class="s1">'{"a":2}'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.SET doc $.a <span class="s1">'3'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"a\":3}]"</span></span></span></code></pre> </div> </details> <details open=""> <summary> <b> Add a new value </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.SET doc $ <span class="s1">'{"a":2}'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.SET doc $.b <span class="s1">'8'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc $ </span></span><span class="line"><span class="cl"><span class="s2">"[{\"a\":2,\"b\":8}]"</span></span></span></code></pre> </div> </details> <details open=""> <summary> <b> Update multi-paths </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; JSON.SET doc $ <span class="s1">'{"f1": {"a":1}, "f2":{"a":2}}'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.SET doc $..a <span class="m">3</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">redis&gt; JSON.GET doc </span></span><span class="line"><span class="cl"><span class="s2">"{\"f1\":{\"a\":3},\"f2\":{\"a\":3}}"</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/json.get/"> <code> JSON.GET </code> </a> | <a href="/docs/latest/commands/json.mget/"> <code> JSON.MGET </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <ul> <li> <a href="/docs/latest/develop/data-types/json/"> RedisJSON </a> </li> <li> <a href="/docs/latest/develop/interact/search-and-query/indexing/"> Index and search JSON documents </a> </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/json.set/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/riot/install/.html
<section class="prose w-full py-12 max-w-none"> <h1> Install </h1> <p class="text-lg -mt-5 mb-10"> Install RIOT on macOS, Linux, Windows, and Docker </p> <p> RIOT can be installed in different ways depending on your environment and preference. </p> <h2 id="macos-via-homebrew"> macOS via Homebrew </h2> <pre tabindex="0"><code>brew install redis/tap/riot </code></pre> <h2 id="windows-via-scoop"> Windows via Scoop </h2> <pre tabindex="0"><code>scoop bucket add redis https://github.com/redis/scoop.git scoop install riot </code></pre> <h2 id="linux-via-homebrew"> Linux via Homebrew </h2> <pre tabindex="0"><code>brew install redis/tap/riot </code></pre> <h2 id="docker"> Docker </h2> <pre tabindex="0"><code>docker run riotx/riot [OPTIONS] [COMMAND] </code></pre> <h2 id="manual-installation"> Manual installation </h2> <p> Download the pre-compiled binary from the <a href="https://github.com/redis/riot/releases"> releases page </a> , uncompress, and copy to the desired location. </p> <p> Full documentation is available at <a href="https://redis.github.io/riot/"> redis.github.io/riot </a> . </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/riot/install/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/.html
<section class="prose w-full py-12 max-w-none"> <h1> Database requests </h1> <p class="text-lg -mt-5 mb-10"> Database requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#get-all-bdbs"> GET </a> </td> <td> <code> /v1/bdbs </code> </td> <td> Get all databases </td> </tr> <tr> <td> <a href="#get-bdbs"> GET </a> </td> <td> <code> /v1/bdbs/{uid} </code> </td> <td> Get a single database </td> </tr> <tr> <td> <a href="#put-bdbs"> PUT </a> </td> <td> <code> /v1/bdbs/{uid} </code> </td> <td> Update database configuration </td> </tr> <tr> <td> <a href="#put-bdbs-action"> PUT </a> </td> <td> <code> /v1/bdbs/{uid}/{action} </code> </td> <td> Update database configuration and perform additional action </td> </tr> <tr> <td> <a href="#post-bdbs-v1"> POST </a> </td> <td> <code> /v1/bdbs </code> </td> <td> Create a new database </td> </tr> <tr> <td> <a href="#post-bdbs-v2"> POST </a> </td> <td> <code> /v2/bdbs </code> </td> <td> Create a new database </td> </tr> <tr> <td> <a href="#delete-bdbs"> DELETE </a> </td> <td> <code> /v1/bdbs/{uid} </code> </td> <td> Delete a database </td> </tr> </tbody> </table> <h2 id="get-all-bdbs"> Get all databases </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/bdbs </span></span></code></pre> </div> <p> Get all databases in the cluster. </p> <h3 id="permissions"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_all_bdbs_info"> view_all_bdbs_info </a> </td> <td> admin <br/> cluster_member <br/> cluster_viewer <br/> db_member <br/> db_viewer <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-all-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/bdbs?fields<span class="o">=</span>uid,name </span></span></code></pre> </div> <h4 id="headers"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="query-parameters"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> fields </td> <td> string </td> <td> Comma-separated list of field names to return (by default all fields are returned). (optional) </td> </tr> </tbody> </table> <h3 id="get-all-response"> Response </h3> <p> The response body contains a JSON array with all databases, represented as <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB objects </a> . </p> <h4 id="body"> Body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"name of database #1"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">2</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"name of database #2"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">]</span> </span></span></code></pre> </div> <h4 id="get-all-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> No error </td> </tr> </tbody> </table> <h3 id="example-requests"> Example requests </h3> <h4 id="curl"> cURL </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ curl -k -X GET -u <span class="s2">"[username]:[password]"</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> -H <span class="s2">"accept: application/json"</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> https://<span class="o">[</span>host<span class="o">][</span>:port<span class="o">]</span>/v1/bdbs?fields<span class="o">=</span>uid,name </span></span></code></pre> </div> <h4 id="python"> Python </h4> <div class="highlight"> <pre class="chroma"><code class="language-python" data-lang="python"><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">requests</span> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">json</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">url</span> <span class="o">=</span> <span class="s2">"https://[host][:port]/v1/bdbs?fields=uid,name"</span> </span></span><span class="line"><span class="cl"><span class="n">auth</span> <span class="o">=</span> <span class="p">(</span><span class="s2">"[username]"</span><span class="p">,</span> <span class="s2">"[password]"</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">headers</span> <span class="o">=</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="s1">'Content-Type'</span><span class="p">:</span> <span class="s1">'application/json'</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">response</span> <span class="o">=</span> <span class="n">requests</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s2">"GET"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">auth</span><span class="o">=</span><span class="n">auth</span><span class="p">,</span> <span class="n">headers</span><span class="o">=</span><span class="n">headers</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">response</span><span class="o">.</span><span class="n">text</span><span class="p">)</span> </span></span></code></pre> </div> <h2 id="get-bdbs"> Get a database </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Get a single database. </p> <h4 id="permissions-1"> Permissions </h4> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_bdb_info"> view_bdb_info </a> </td> <td> admin <br/> cluster_member <br/> cluster_viewer <br/> db_member <br/> db_viewer <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-request"> Request </h3> <h4 id="example-http-request-1"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /bdbs/1 </span></span></code></pre> </div> <h4 id="headers-1"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database requested. </td> </tr> </tbody> </table> <h4 id="query-parameters-1"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> fields </td> <td> string </td> <td> Comma-separated list of field names to return (by default all fields are returned). (optional) </td> </tr> </tbody> </table> <h3 id="get-response"> Response </h3> <p> Returns a <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> . </p> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"name of database #1"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="get-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> No error </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> Database UID does not exist </td> </tr> </tbody> </table> <h2 id="put-bdbs"> Update database configuration </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Update the configuration of an active database. </p> <p> If called with the <code> dry_run </code> URL query string, the function will validate the <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> against the existing database, but will not invoke the state machine that will update it. </p> <p> This is the basic version of the update request. See <a href="#put-bdbs-action"> Update database and perform action </a> to send an update request with an additional action. </p> <p> To track this request's progress, poll the <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/"> <code> /actions/&lt;action_uid&gt; </code> endpoint </a> with the action_uid returned in the response body. </p> <h3 id="permissions-2"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_bdb"> update_bdb </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="put-request"> Request </h3> <h4 id="example-http-request-2"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /bdbs/1 </span></span></code></pre> </div> <h4 id="headers-2"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> <tr> <td> Content-type </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="query-parameters-2"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> dry_run </td> <td> </td> <td> Validate the new <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> but don't apply the update. </td> </tr> </tbody> </table> <h4 id="url-parameters-1"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database for which update is requested. </td> </tr> </tbody> </table> <h4 id="body-1"> Body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> with updated fields in the request body. </p> <h5 id="example-json-body-1"> Example JSON body </h5> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replication"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"data_persistence"</span><span class="p">:</span> <span class="s2">"aof"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request attempts to modify a database configuration to enable in-memory data replication and append-only file data persistence. </p> <h3 id="put-response"> Response </h3> <p> Returns the updated <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> . </p> <h4 id="example-json-body-2"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replication"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"data_persistence"</span><span class="p">:</span> <span class="s2">"aof"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="put-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The request is accepted and is being processed. The database state will be 'active-change-pending' until the request has been fully processed. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404Β NotΒ Found </a> </td> <td> Attempting to change a nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406Β NotΒ Acceptable </a> </td> <td> The requested configuration is invalid. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10"> 409 Conflict </a> </td> <td> Attempting to change a database while it is busy with another configuration change. In this context, this is a temporary condition, and the request should be reattempted later. </td> </tr> </tbody> </table> <h4 id="put-error-codes"> Error codes </h4> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> field that provide additional information. The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> rack_awareness_violation </td> <td> β€’ Non rack-aware cluster. <br/> β€’ Not enough nodes in unique racks. </td> </tr> <tr> <td> invalid_certificate </td> <td> SSL client certificate is missing or malformed. </td> </tr> <tr> <td> certificate_expired </td> <td> SSL client certificate has expired. </td> </tr> <tr> <td> duplicated_certs </td> <td> An SSL client certificate appears more than once. </td> </tr> <tr> <td> insufficient_resources </td> <td> Shards count exceeds shards limit per bdb. </td> </tr> <tr> <td> not_supported_action_on_crdt </td> <td> <code> reset_admin_pass </code> action is not allowed on CRDT enabled BDB. </td> </tr> <tr> <td> name_violation </td> <td> CRDT database name cannot be changed. </td> </tr> <tr> <td> bad_shards_blueprint </td> <td> The sharding blueprint is broken or doesn’t fit the BDB. </td> </tr> <tr> <td> replication_violation </td> <td> CRDT database must use replication. </td> </tr> <tr> <td> eviction_policy_violation </td> <td> LFU eviction policy is not supported on bdb version&lt;4 </td> </tr> <tr> <td> replication_node_violation </td> <td> Not enough nodes for replication. </td> </tr> <tr> <td> replication_size_violation </td> <td> Database limit too small for replication. </td> </tr> <tr> <td> invalid_oss_cluster_configuration </td> <td> BDB configuration does not meet the requirements for OSS cluster mode </td> </tr> <tr> <td> missing_backup_interval </td> <td> BDB backup is enabled but backup interval is missing. </td> </tr> <tr> <td> crdt_sharding_violation </td> <td> CRDB created without sharding cannot be changed to use sharding </td> </tr> <tr> <td> invalid_proxy_policy </td> <td> Invalid proxy_policy value. </td> </tr> <tr> <td> invalid_bdb_tags </td> <td> Tag objects with the same key parameter were passed. </td> </tr> <tr> <td> unsupported_module_capabilities </td> <td> Not all modules configured for the database support the capabilities needed for the database configuration. </td> </tr> <tr> <td> redis_acl_unsupported </td> <td> Redis ACL is not supported for this database. </td> </tr> </tbody> </table> <h2 id="put-bdbs-action"> Update database and perform action </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span>/<span class="o">{</span>action<span class="o">}</span> </span></span></code></pre> </div> <p> Update the configuration of an active database and perform an additional action. </p> <p> If called with the <code> dry_run </code> URL query string, the function will validate the <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> against the existing database, but will not invoke the state machine that will update it. </p> <h4 id="permissions-3"> Permissions </h4> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_bdb_with_action"> update_bdb_with_action </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="put-request-action"> Request </h3> <h4 id="example-http-request-3"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /bdbs/1/reset_admin_pass </span></span></code></pre> </div> <p> The above request resets the admin password after updating the database. </p> <h4 id="headers-3"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> <tr> <td> Content-type </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="url-parameters-2"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database to update. </td> </tr> <tr> <td> action </td> <td> string </td> <td> Additional action to perform. Currently supported actions are: <code> flush </code> , <code> reset_admin_pass </code> . </td> </tr> </tbody> </table> <h4 id="query-parameters-3"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> dry_run </td> <td> </td> <td> Validate the new <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> but don't apply the update. </td> </tr> </tbody> </table> <h4 id="body-2"> Body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> with updated fields in the request body. </p> <h5 id="example-json-body-3"> Example JSON body </h5> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"replication"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"data_persistence"</span><span class="p">:</span> <span class="s2">"aof"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request attempts to modify a database configuration to enable in-memory data replication and append-only file data persistence. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> To change the shard hashing policy, you must flush all keys from the database. </div> </div> <h3 id="put-response-action"> Response </h3> <p> If the request succeeds, the response body returns the updated <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> . If an error occurs, the response body may include an error code and message with more details. </p> <h4 id="put-status-codes-action"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The request is accepted and is being processed. The database state will be 'active-change-pending' until the request has been fully processed. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.4"> 403Β Forbidden </a> </td> <td> redislabs license expired. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404Β NotΒ Found </a> </td> <td> Attempting to change a nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406Β NotΒ Acceptable </a> </td> <td> The requested configuration is invalid. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10"> 409 Conflict </a> </td> <td> Attempting to change a database while it is busy with another configuration change. In this context, this is a temporary condition, and the request should be reattempted later. </td> </tr> </tbody> </table> <h4 id="put-error-codes-action"> Error codes </h4> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> field that provide additional information. The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> rack_awareness_violation </td> <td> β€’ Non rack-aware cluster. <br/> β€’ Not enough nodes in unique racks. </td> </tr> <tr> <td> invalid_certificate </td> <td> SSL client certificate is missing or malformed. </td> </tr> <tr> <td> certificate_expired </td> <td> SSL client certificate has expired. </td> </tr> <tr> <td> duplicated_certs </td> <td> An SSL client certificate appears more than once. </td> </tr> <tr> <td> insufficient_resources </td> <td> Shards count exceeds shards limit per bdb. </td> </tr> <tr> <td> not_supported_action_on_crdt </td> <td> <code> reset_admin_pass </code> action is not allowed on CRDT enabled BDB. </td> </tr> <tr> <td> name_violation </td> <td> CRDT database name cannot be changed. </td> </tr> <tr> <td> bad_shards_blueprint </td> <td> The sharding blueprint is broken or doesn’t fit the BDB. </td> </tr> <tr> <td> replication_violation </td> <td> CRDT database must use replication. </td> </tr> <tr> <td> eviction_policy_violation </td> <td> LFU eviction policy is not supported on bdb version&lt;4 </td> </tr> <tr> <td> replication_node_violation </td> <td> Not enough nodes for replication. </td> </tr> <tr> <td> replication_size_violation </td> <td> Database limit too small for replication. </td> </tr> <tr> <td> invalid_oss_cluster_configuration </td> <td> BDB configuration does not meet the requirements for OSS cluster mode </td> </tr> <tr> <td> missing_backup_interval </td> <td> BDB backup is enabled but backup interval is missing. </td> </tr> <tr> <td> crdt_sharding_violation </td> <td> CRDB created without sharding cannot be changed to use sharding </td> </tr> <tr> <td> invalid_proxy_policy </td> <td> Invalid proxy_policy value. </td> </tr> <tr> <td> invalid_bdb_tags </td> <td> Tag objects with the same key parameter were passed. </td> </tr> <tr> <td> unsupported_module_capabilities </td> <td> Not all modules configured for the database support the capabilities needed for the database configuration. </td> </tr> <tr> <td> redis_acl_unsupported </td> <td> Redis ACL is not supported for this database. </td> </tr> </tbody> </table> <h2 id="post-bdbs-v1"> Create database v1 </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/bdbs </span></span></code></pre> </div> <p> Create a new database in the cluster. </p> <p> The request must contain a single JSON <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> with the configuration parameters for the new database. </p> <p> The following parameters are required to create the database: </p> <table> <thead> <tr> <th> Parameter </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> name </td> <td> string </td> <td> Name of the new database </td> </tr> <tr> <td> memory_size </td> <td> integer </td> <td> Size of the database, in bytes </td> </tr> </tbody> </table> <p> If passed with the <code> dry_run </code> URL query string, the function will validate the <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> , but will not invoke the state machine that will create it. </p> <p> To track this request's progress, poll the <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/"> <code> /actions/&lt;action_uid&gt; </code> endpoint </a> with the <code> action_uid </code> returned in the response body. </p> <p> The cluster will use default configuration for any missing database field. The cluster creates a database UID if it is missing. </p> <h3 id="permissions-4"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#create_bdb"> create_bdb </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="post-request-v1"> Request </h3> <h4 id="example-http-request-4"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /bdbs </span></span></code></pre> </div> <h4 id="headers-4"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> <tr> <td> Content-type </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="query-parameters-4"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> dry_run </td> <td> </td> <td> Validate the new <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> but don't create the database. </td> </tr> </tbody> </table> <h4 id="body-3"> Body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> in the request body. </p> <p> The following parameters are required to create the database: </p> <table> <thead> <tr> <th> Paramter </th> <th> Type/Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> name </td> <td> string </td> <td> Name of the new database </td> </tr> <tr> <td> memory_size </td> <td> integer </td> <td> Size of the database, in bytes </td> </tr> </tbody> </table> <p> The <code> uid </code> of the database is auto-assigned by the cluster because it was not explicitly listed in this request. If you specify the database ID ( <code> uid </code> ), then you must specify the database ID for every subsequent database and make sure that the database ID does not conflict with an existing database. If you do not specify the database ID, then the it is automatically assigned in sequential order. </p> <p> Defaults are used for all other configuration parameters. </p> <h4 id="example-json-body-4"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"test-database"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"redis"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"memory_size"</span><span class="p">:</span> <span class="mi">1073741824</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <p> The above request is an attempt to create a Redis database with a user-specified name and a memory limit of 1GB. </p> <h3 id="post-response-v1"> Response </h3> <p> The response includes the newly created <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> . </p> <h4 id="example-json-body-5"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"test-database"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"redis"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"memory_size"</span><span class="p">:</span> <span class="mi">1073741824</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="post-error-codes-v1"> Error codes </h4> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> field that provide additional information. The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid_exists </td> <td> The specified database UID is already in use. </td> </tr> <tr> <td> missing_db_name </td> <td> DB name is a required property. </td> </tr> <tr> <td> missing_memory_size </td> <td> Memory Size is a required property. </td> </tr> <tr> <td> missing_module </td> <td> Modules missing from the cluster. </td> </tr> <tr> <td> port_unavailable </td> <td> The specified database port is reserved or already in use. </td> </tr> <tr> <td> invalid_sharding </td> <td> Invalid sharding configuration was specified. </td> </tr> <tr> <td> bad_shards_blueprint </td> <td> The sharding blueprint is broken. </td> </tr> <tr> <td> not_rack_aware </td> <td> Cluster is not rack-aware and a rack-aware database was requested. </td> </tr> <tr> <td> invalid_version </td> <td> An invalid database version was requested. </td> </tr> <tr> <td> busy </td> <td> The request failed because another request is being processed at the same time on the same database. </td> </tr> <tr> <td> invalid_data_persistence </td> <td> Invalid data persistence configuration. </td> </tr> <tr> <td> invalid_proxy_policy </td> <td> Invalid proxy_policy value. </td> </tr> <tr> <td> invalid_sasl_credentials </td> <td> SASL credentials are missing or invalid. </td> </tr> <tr> <td> invalid_replication </td> <td> Not enough nodes to perform replication. </td> </tr> <tr> <td> insufficient_resources </td> <td> Not enough resources in cluster to host the database. </td> </tr> <tr> <td> rack_awareness_violation </td> <td> β€’ Rack awareness violation. <br/> β€’ Not enough nodes in unique racks. </td> </tr> <tr> <td> invalid_certificate </td> <td> SSL client certificate is missing or malformed. </td> </tr> <tr> <td> certificate_expired </td> <td> SSL client certificate has expired. </td> </tr> <tr> <td> duplicated_certs </td> <td> An SSL client certificate appears more than once. </td> </tr> <tr> <td> replication_violation </td> <td> CRDT database must use replication. </td> </tr> <tr> <td> eviction_policy_violation </td> <td> LFU eviction policy is not supported on bdb version&lt;4 </td> </tr> <tr> <td> invalid_oss_cluster_configuration </td> <td> BDB configuration does not meet the requirements for OSS cluster mode </td> </tr> <tr> <td> memcached_cannot_use_modules </td> <td> Cannot create a memcached database with modules. </td> </tr> <tr> <td> missing_backup_interval </td> <td> BDB backup is enabled but backup interval is missing. </td> </tr> <tr> <td> wrong_cluster_state_id </td> <td> The given CLUSTER-STATE-ID does not match the current one </td> </tr> <tr> <td> invalid_bdb_tags </td> <td> Tag objects with the same key parameter were passed. </td> </tr> <tr> <td> unsupported_module_capabilities </td> <td> Not all modules configured for the database support the capabilities needed for the database configuration. </td> </tr> <tr> <td> redis_acl_unsupported </td> <td> Redis ACL is not supported for this database. </td> </tr> </tbody> </table> <h4 id="post-status-codes-v1"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.4"> 403 Forbidden </a> </td> <td> redislabs license expired. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10"> 409 Conflict </a> </td> <td> Database with the same UID already exists. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> Invalid configuration parameters provided. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, database is being created. </td> </tr> </tbody> </table> <h2 id="post-bdbs-v2"> Create database v2 </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v2/bdbs </span></span></code></pre> </div> <p> Create a new database in the cluster. See <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/#post-bdbs-v1"> <code> POST /v1/bdbs </code> </a> for more information. </p> <p> The database's configuration should be under the "bdb" field. </p> <p> This endpoint allows you to specify a recovery_plan to recover a database. If you include a recovery_plan within the request body, the database will be loaded from the persistence files according to the recovery plan. The recovery plan must match the number of shards requested for the database. </p> <p> The persistence files must exist in the locations specified by the recovery plan. The persistence files must belong to a database with the same shard settings as the one being created (slot range distribution and shard_key_regex); otherwise, the operation will fail or yield unpredictable results. </p> <p> If you create a database with a shards_blueprint and a recovery plan, the shard placement may not fully follow the shards_blueprint. </p> <h3 id="post-request-v2"> Request </h3> <h4 id="example-http-request-5"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v2/bdbs </span></span></code></pre> </div> <h4 id="headers-5"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> <tr> <td> Content-type </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="query-parameters-5"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> dry_run </td> <td> </td> <td> Validate the new <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> but don't create the database. </td> </tr> </tbody> </table> <h4 id="body-4"> Body </h4> <p> Include a JSON object that contains a <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> and an optional <code> recovery_plan </code> object in the request body. </p> <h5 id="example-json-body-6"> Example JSON body </h5> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"bdb"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"test-database"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"redis"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"memory_size"</span><span class="p">:</span> <span class="mi">1073741824</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"shards_count"</span><span class="p">:</span> <span class="mi">1</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="nt">"recovery_plan"</span><span class="p">:</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"data_files"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"shard_slots"</span><span class="p">:</span> <span class="s2">"0-16383"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"node_uid"</span><span class="p">:</span> <span class="s2">"1"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"filename"</span><span class="p">:</span> <span class="s2">"redis-4.rdb"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"> <span class="p">]</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="post-response-v2"> Response </h3> <p> The response includes the newly created <a href="/docs/latest/operate/rs/references/rest-api/objects/bdb/"> BDB object </a> . </p> <h4 id="example-json-body-7"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"test-database"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"type"</span><span class="p">:</span> <span class="s2">"redis"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"memory_size"</span><span class="p">:</span> <span class="mi">1073741824</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"shards_count"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"// additional fields..."</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h2 id="delete-bdbs"> Delete database </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Delete an active database. </p> <h3 id="permissions-5"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#delete_bdb"> delete_bdb </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="delete-request"> Request </h3> <h4 id="example-http-request-6"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /bdbs/1 </span></span></code></pre> </div> <h4 id="headers-6"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> The domain name or IP of the cluster </td> </tr> <tr> <td> Accept </td> <td> application/json </td> </tr> </tbody> </table> <h4 id="url-parameters-3"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database to delete. </td> </tr> </tbody> </table> <h3 id="delete-response"> Response </h3> <p> Returns a status code that indicates the database deletion success or failure. </p> <h3 id="delete-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> The request is accepted and is being processed. The database state will be 'delete-pending' until the request has been fully processed. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.4"> 403 Forbidden </a> </td> <td> Attempting to delete an internal database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404Β NotΒ Found </a> </td> <td> Attempting to delete a nonexistent database. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10"> 409 Conflict </a> </td> <td> Either the database is not in 'active' state and cannot be deleted, or it is busy with another configuration change. In the second case, this is a temporary condition, and the request should be re-attempted later. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/python/install/.html
<section class="prose w-full py-12 max-w-none"> <h1> Install RedisGears and the Python plugin </h1> <p> Before you can use RedisGears with Python, you need to install the RedisGears module and Python plugin on your Redis Enterprise cluster and enable them for a database. </p> <h2 id="prerequisites"> Prerequisites </h2> <ol> <li> <p> Redis Enterprise v6.0.12 or later </p> </li> <li> <p> <a href="/docs/latest/operate/rs/clusters/new-cluster-setup/"> Created a Redis Enterprise cluster </a> </p> </li> <li> <p> <a href="/docs/latest/operate/rs/clusters/add-node/"> Added nodes to the cluster </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/installing-redisgears/#install-redisgears"> Installed RedisGears and the Python plugin </a> </p> </li> </ol> <h2 id="enable-redisgears-for-a-database"> Enable RedisGears for a database </h2> <ol> <li> <p> From the Redis Enterprise admin console's <strong> databases </strong> page, select the <strong> Add </strong> button to create a new database: </p> <a href="/docs/latest/images/rs/icon_add.png" sdata-lightbox="/images/rs/icon_add.png"> <img alt="The Add icon" src="/docs/latest/images/rs/icon_add.png" width="30px"/> </a> </li> <li> <p> Confirm that you want to create a new Redis database with the <strong> Next </strong> button. </p> </li> <li> <p> On the <strong> create database </strong> page, give your database a name. </p> </li> <li> <p> For <strong> Redis Modules </strong> , select the <strong> Add </strong> button and choose RedisGears from the <strong> Module </strong> dropdown list. </p> </li> <li> <p> Select <strong> Add Configuration </strong> , enter <nobr> <code> Plugin gears_python CreateVenv 1 </code> </nobr> in the box, then select the <strong> OK </strong> button: </p> <a href="/docs/latest/images/rs/icon_save.png" sdata-lightbox="/images/rs/icon_save.png"> <img alt="The Save icon" src="/docs/latest/images/rs/icon_save.png" width="30px"/> </a> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Only RedisGears v1.2 and later require this configuration. </div> </div> </li> <li> <p> Select the <strong> Activate </strong> button. </p> </li> </ol> <h2 id="verify-the-install"> Verify the install </h2> <p> Run the <code> RG.PYSTATS </code> command to view statistics and verify that you set up RedisGears and the Python plugin correctly: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">redis&gt; RG.PYSTATS </span></span></code></pre> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/oss_and_stack/stack-with-enterprise/gears-v1/python/install/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-126/.html
<section class="prose w-full py-12 max-w-none"> <h1> Redis Enterprise Software release notes 7.4.2-126 (April 2024) </h1> <p class="text-lg -mt-5 mb-10"> Redis database version selection during database creation in the Cluster Manager UI. New Redis logo. </p> <p> This is a maintenance release for ​ <a href="https://redis.com/redis-enterprise-software/download-center/software/"> ​Redis Enterprise Software version 7.4.2 </a> . </p> <h2 id="highlights"> Highlights </h2> <p> This version offers: </p> <ul> <li> <p> Redis database version selection during database creation in the Cluster Manager UI </p> </li> <li> <p> New Redis logo </p> </li> </ul> <h2 id="new-in-this-release"> New in this release </h2> <h3 id="enhancements"> Enhancements </h3> <ul> <li> <p> New Cluster Manager UI enhancements: </p> <ul> <li> <p> You can choose the Redis database version during <a href="/docs/latest/operate/rs/databases/create/"> database creation </a> . </p> </li> <li> <p> Updated the Redis logo. </p> </li> </ul> </li> </ul> <h4 id="redis-module-feature-sets"> Redis module feature sets </h4> <p> Redis Enterprise comes packaged with several modules. As of version 7.4.2, Redis Enterprise includes two feature sets, compatible with different Redis database versions. </p> <p> Bundled Redis modules compatible with Redis database version 7.2: </p> <ul> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.8-release-notes/"> RediSearch 2.8.12 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisjson/redisjson-2.6-release-notes/"> RedisJSON 2.6.9 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redistimeseries/redistimeseries-1.10-release-notes/"> RedisTimeSeries 1.10.11 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.6-release-notes/"> RedisBloom 2.6.12 </a> </p> </li> <li> <p> <a href="https://github.com/RedisGears/RedisGears/releases/tag/v2.0.19-m20"> RedisGears 2.0.19 </a> </p> </li> </ul> <p> Bundled Redis modules compatible with Redis database versions 6.0 and 6.2: </p> <ul> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisearch/redisearch-2.6-release-notes/"> RediSearch 2.6.16 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisjson/redisjson-2.4-release-notes/"> RedisJSON 2.4.8 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redistimeseries/redistimeseries-1.8-release-notes/"> RedisTimeSeries 1.8.12 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisbloom/redisbloom-2.4-release-notes/"> RedisBloom 2.4.9 </a> </p> </li> <li> <p> <a href="/docs/latest/operate/oss_and_stack/stack-with-enterprise/release-notes/redisgraph/redisgraph-2.10-release-notes/"> RedisGraph v2.10.15 </a> </p> </li> </ul> <h3 id="resolved-issues"> Resolved issues </h3> <ul> <li> <p> RS113727: Added <code> automatic_node_offload </code> policy, which defines whether the cluster can automatically migrate shards from a node if the node is overbooked and is enabled by default. During an upgrade, don't offload even if the policy is enabled. </p> </li> <li> <p> RS113828: Removed legacy function that adjusted existing users to role-based access control. </p> </li> <li> <p> RS115636: Delete tasks with "aborted" status from the resource manager result queue. </p> </li> <li> <p> RS122225: Improved descriptions in Cluster Manager UI logs for database upgrade, check node error, and upgrade mode. </p> </li> <li> <p> RS122031: Improved performance of database search in the Cluster Manager UI. </p> </li> <li> <p> RS121866: Block scripts that contain write commands from running on stale CRDB servers. </p> </li> <li> <p> RS122570: Improved error message when unable to locate a requested CRDB-compatible module during Active-Active database creation. </p> </li> <li> <p> RS120820: When using OSS Cluster API, improved availability during failover, database migration, database upgrade, and node optimization. </p> </li> <li> <p> RS117388: Improved <code> rladmin status </code> output for stale shards. </p> </li> </ul> <h2 id="version-changes"> Version changes </h2> <h3 id="supported-platforms"> Supported platforms </h3> <p> The following table provides a snapshot of supported platforms as of this Redis Enterprise Software release. See the <a href="/docs/latest/operate/rs/references/supported-platforms/"> supported platforms reference </a> for more details about operating system compatibility. </p> <p> <span title="Check mark icon"> βœ… </span> Supported – The platform is supported for this version of Redis Enterprise Software and Redis Stack modules. </p> <p> <span class="font-serif" title="Warning icon"> ⚠️ </span> Deprecation warning – The platform is still supported for this version of Redis Enterprise Software, but support will be removed in a future release. </p> <table> <thead> <tr> <th> Redis Enterprise <br/> major versions </th> <th style="text-align:center"> 7.4 </th> <th style="text-align:center"> 7.2 </th> <th style="text-align:center"> 6.4 </th> <th style="text-align:center"> 6.2 </th> </tr> </thead> <tbody> <tr> <td> <strong> Release date </strong> </td> <td style="text-align:center"> Feb 2024 </td> <td style="text-align:center"> Aug 2023 </td> <td style="text-align:center"> Feb 2023 </td> <td style="text-align:center"> Aug 2021 </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/installing-upgrading/product-lifecycle/#endoflife-schedule"> <strong> End-of-life date </strong> </a> </td> <td style="text-align:center"> Determined after <br/> next major release </td> <td style="text-align:center"> July 2025 </td> <td style="text-align:center"> Feb 2025 </td> <td style="text-align:center"> Aug 2024 </td> </tr> <tr> <td> <strong> Platforms </strong> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> <td style="text-align:center"> </td> </tr> <tr> <td> RHEL 9 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> <td style="text-align:center"> – </td> </tr> <tr> <td> RHEL 8 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> RHEL 7 &amp; <br/> compatible distros <sup> <a href="#table-note-1"> 1 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 20.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Ubuntu 18.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Ubuntu 16.04 <sup> <a href="#table-note-2"> 2 </a> </sup> </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span class="font-serif" title="Deprecated"> ⚠️ </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Amazon Linux 2 </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> – </td> </tr> <tr> <td> Amazon Linux 1 </td> <td style="text-align:center"> – </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Kubernetes <sup> <a href="#table-note-3"> 3 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> Docker <sup> <a href="#table-note-4"> 4 </a> </sup> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> <td style="text-align:center"> <span title="Supported"> βœ… </span> </td> </tr> </tbody> </table> <ol> <li> <p> <a name="table-note-1" style="display: block; height: 80px; margin-top: -80px;"> </a> The RHEL-compatible distributions CentOS, CentOS Stream, Alma, and Rocky are supported if they have full RHEL compatibility. Oracle Linux running the Red Hat Compatible Kernel (RHCK) is supported, but the Unbreakable Enterprise Kernel (UEK) is not supported. </p> </li> <li> <p> <a name="table-note-2" style="display: block; height: 80px; margin-top: -80px;"> </a> The server version of Ubuntu is recommended for production installations. The desktop version is only recommended for development deployments. </p> </li> <li> <p> <a name="table-note-3" style="display: block; height: 80px; margin-top: -80px;"> </a> See the <a href="/docs/latest/operate/kubernetes/reference/supported_k8s_distributions/"> Redis Enterprise for Kubernetes documentation </a> for details about support per version and Kubernetes distribution. </p> </li> <li> <p> <a name="table-note-4" style="display: block; height: 80px; margin-top: -80px;"> </a> <a href="/docs/latest/operate/rs/installing-upgrading/quickstarts/docker-quickstart/"> Docker images </a> of Redis Enterprise Software are certified for development and testing only. </p> </li> </ol> <h2 id="downloads"> Downloads </h2> <p> The following table shows the MD5 checksums for the available packages: </p> <table> <thead> <tr> <th> Package </th> <th> MD5 checksum (7.4.2-126 April release) </th> </tr> </thead> <tbody> <tr> <td> Ubuntu 18 </td> <td> 0cca90f27f368d35b9ca08e4016047c7 </td> </tr> <tr> <td> Ubuntu 20 </td> <td> 1933107157365c1c1b38b69b9644b47 </td> </tr> <tr> <td> Red Hat Enterprise Linux (RHEL) 8 </td> <td> 4eb11678fa80cddca17fc7cfb94b9289 </td> </tr> <tr> <td> Red Hat Enterprise Linux (RHEL) 9 </td> <td> 217b6669ff8ac5bbcc2fc8fbc2930c59 </td> </tr> <tr> <td> Amazon Linux 2 </td> <td> d0f472f173f09c56a14c57f17d146deb </td> </tr> </tbody> </table> <h2 id="security"> Security </h2> <h4 id="open-source-redis-security-fixes-compatibility"> Open source Redis security fixes compatibility </h4> <p> As part of Redis's commitment to security, Redis Enterprise Software implements the latest <a href="https://github.com/redis/redis/releases"> security fixes </a> available with <a href="https://github.com/redis/redis"> open source Redis </a> . Redis Enterprise has already included the fixes for the relevant CVEs. </p> <p> Some CVEs announced for open source Redis do not affect Redis Enterprise due to different or additional functionality available in Redis Enterprise that is not available in open source Redis. </p> <p> Redis Enterprise 7.4.2 supports open source Redis 7.2, 6.2, and 6.0. Below is the list of open source Redis CVEs fixed by version. </p> <p> Redis 7.2.x: </p> <ul> <li> <p> (CVE-2023-41056) In some cases, Redis may incorrectly handle resizing of memory buffers, which can result in incorrect accounting of buffer sizes and lead to heap overflow and potential remote code execution. </p> </li> <li> <p> (CVE-2023-41053) Redis does not correctly identify keys accessed by <code> SORT_RO </code> and, as a result, may grant users executing this command access to keys that are not explicitly authorized by the ACL configuration. (Redis 7.2.1) </p> </li> </ul> <p> Redis 7.0.x: </p> <ul> <li> <p> (CVE-2023-41056) In some cases, Redis may incorrectly handle resizing of memory buffers, which can result in incorrect accounting of buffer sizes and lead to heap overflow and potential remote code execution. </p> </li> <li> <p> (CVE-2023-41053) Redis does not correctly identify keys accessed by <code> SORT_RO </code> and, as a result, may grant users executing this command access to keys that are not explicitly authorized by the ACL configuration. (Redis 7.0.13) </p> </li> <li> <p> (CVE-2023-36824) Extracting key names from a command and a list of arguments may, in some cases, trigger a heap overflow and result in reading random heap memory, heap corruption, and potentially remote code execution. Specifically: using <code> COMMAND GETKEYS* </code> and validation of key names in ACL rules. (Redis 7.0.12) </p> </li> <li> <p> (CVE-2023-28856) Authenticated users can use the <code> HINCRBYFLOAT </code> command to create an invalid hash field that will crash Redis on access. (Redis 7.0.11) </p> </li> <li> <p> (CVE-2023-28425) Specially crafted <code> MSETNX </code> command can lead to assertion and denial-of-service. (Redis 7.0.10) </p> </li> <li> <p> (CVE-2023-25155) Specially crafted <code> SRANDMEMBER </code> , <code> ZRANDMEMBER </code> , and <code> HRANDFIELD </code> commands can trigger an integer overflow, resulting in a runtime assertion and termination of the Redis server process. (Redis 7.0.9) </p> </li> <li> <p> (CVE-2023-22458) Integer overflow in the Redis <code> HRANDFIELD </code> and <code> ZRANDMEMBER </code> commands can lead to denial-of-service. (Redis 7.0.8) </p> </li> <li> <p> (CVE-2022-36021) String matching commands (like <code> SCAN </code> or <code> KEYS </code> ) with a specially crafted pattern to trigger a denial-of-service attack on Redis, causing it to hang and consume 100% CPU time. (Redis 7.0.9) </p> </li> <li> <p> (CVE-2022-35977) Integer overflow in the Redis <code> SETRANGE </code> and <code> SORT </code> / <code> SORT_RO </code> commands can drive Redis to OOM panic. (Redis 7.0.8) </p> </li> <li> <p> (CVE-2022-35951) Executing an <code> XAUTOCLAIM </code> command on a stream key in a specific state, with a specially crafted <code> COUNT </code> argument, may cause an integer overflow, a subsequent heap overflow, and potentially lead to remote code execution. The problem affects Redis versions 7.0.0 or newer. (Redis 7.0.5) </p> </li> <li> <p> (CVE-2022-31144) A specially crafted <code> XAUTOCLAIM </code> command on a stream key in a specific state may result in heap overflow and potentially remote code execution. The problem affects Redis versions 7.0.0 or newer. (Redis 7.0.4) </p> </li> <li> <p> (CVE-2022-24834) A specially crafted Lua script executing in Redis can trigger a heap overflow in the cjson and cmsgpack libraries, and result in heap corruption and potentially remote code execution. The problem exists in all versions of Redis with Lua scripting support, starting from 2.6, and affects only authenticated and authorized users. (Redis 7.0.12) </p> </li> <li> <p> (CVE-2022-24736) An attacker attempting to load a specially crafted Lua script can cause NULL pointer dereference which will result in a crash of the <code> redis-server </code> process. This issue affects all versions of Redis. (Redis 7.0.0) </p> </li> <li> <p> (CVE-2022-24735) By exploiting weaknesses in the Lua script execution environment, an attacker with access to Redis can inject Lua code that will execute with the (potentially higher) privileges of another Redis user. (Redis 7.0.0) </p> </li> </ul> <p> Redis 6.2.x: </p> <ul> <li> <p> (CVE-2023-28856) Authenticated users can use the <code> HINCRBYFLOAT </code> command to create an invalid hash field that will crash Redis on access. (Redis 6.2.12) </p> </li> <li> <p> (CVE-2023-25155) Specially crafted <code> SRANDMEMBER </code> , <code> ZRANDMEMBER </code> , and <code> HRANDFIELD </code> commands can trigger an integer overflow, resulting in a runtime assertion and termination of the Redis server process. (Redis 6.2.11) </p> </li> <li> <p> (CVE-2023-22458) Integer overflow in the Redis <code> HRANDFIELD </code> and <code> ZRANDMEMBER </code> commands can lead to denial-of-service. (Redis 6.2.9) </p> </li> <li> <p> (CVE-2022-36021) String matching commands (like <code> SCAN </code> or <code> KEYS </code> ) with a specially crafted pattern to trigger a denial-of-service attack on Redis, causing it to hang and consume 100% CPU time. (Redis 6.2.11) </p> </li> <li> <p> (CVE-2022-35977) Integer overflow in the Redis <code> SETRANGE </code> and <code> SORT </code> / <code> SORT_RO </code> commands can drive Redis to OOM panic. (Redis 6.2.9) </p> </li> <li> <p> (CVE-2022-24834) A specially crafted Lua script executing in Redis can trigger a heap overflow in the cjson and cmsgpack libraries, and result in heap corruption and potentially remote code execution. The problem exists in all versions of Redis with Lua scripting support, starting from 2.6, and affects only authenticated and authorized users. (Redis 6.2.13) </p> </li> <li> <p> (CVE-2022-24736) An attacker attempting to load a specially crafted Lua script can cause NULL pointer dereference which will result in a crash of the <code> redis-server </code> process. This issue affects all versions of Redis. (Redis 6.2.7) </p> </li> <li> <p> (CVE-2022-24735) By exploiting weaknesses in the Lua script execution environment, an attacker with access to Redis can inject Lua code that will execute with the (potentially higher) privileges of another Redis user. (Redis 6.2.7) </p> </li> <li> <p> (CVE-2021-41099) Integer to heap buffer overflow handling certain string commands and network payloads, when <code> proto-max-bulk-len </code> is manually configured to a non-default, very large value. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32762) Integer to heap buffer overflow issue in <code> redis-cli </code> and <code> redis-sentinel </code> parsing large multi-bulk replies on some older and less common platforms. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32761) An integer overflow bug in Redis version 2.2 or newer can be exploited using the <code> BITFIELD </code> command to corrupt the heap and potentially result with remote code execution. (Redis 6.2.5) </p> </li> <li> <p> (CVE-2021-32687) Integer to heap buffer overflow with intsets, when <code> set-max-intset-entries </code> is manually configured to a non-default, very large value. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32675) Denial Of Service when processing RESP request payloads with a large number of elements on many connections. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32672) Random heap reading issue with Lua Debugger. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32628) Integer to heap buffer overflow handling ziplist-encoded data types, when configuring a large, non-default value for <code> hash-max-ziplist-entries </code> , <code> hash-max-ziplist-value </code> , <code> zset-max-ziplist-entries </code> or <code> zset-max-ziplist-value </code> . (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32627) Integer to heap buffer overflow issue with streams, when configuring a non-default, large value for <code> proto-max-bulk-len </code> and <code> client-query-buffer-limit </code> . (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32626) Specially crafted Lua scripts may result with Heap buffer overflow. (Redis 6.2.6) </p> </li> <li> <p> (CVE-2021-32625) An integer overflow bug in Redis version 6.0 or newer can be exploited using the STRALGO LCS command to corrupt the heap and potentially result with remote code execution. This is a result of an incomplete fix by CVE-2021-29477. (Redis 6.2.4) </p> </li> <li> <p> (CVE-2021-29478) An integer overflow bug in Redis 6.2 could be exploited to corrupt the heap and potentially result with remote code execution. The vulnerability involves changing the default set-max-intset-entries configuration value, creating a large set key that consists of integer values and using the COPY command to duplicate it. The integer overflow bug exists in all versions of Redis starting with 2.6, where it could result with a corrupted RDB or DUMP payload, but not exploited through COPY (which did not exist before 6.2). (Redis 6.2.3) </p> </li> <li> <p> (CVE-2021-29477) An integer overflow bug in Redis version 6.0 or newer could be exploited using the STRALGO LCS command to corrupt the heap and potentially result in remote code execution. The integer overflow bug exists in all versions of Redis starting with 6.0. (Redis 6.2.3) </p> </li> </ul> <p> Redis 6.0.x: </p> <ul> <li> <p> (CVE-2022-24834) A specially crafted Lua script executing in Redis can trigger a heap overflow in the cjson and cmsgpack libraries, and result in heap corruption and potentially remote code execution. The problem exists in all versions of Redis with Lua scripting support, starting from 2.6, and affects only authenticated and authorized users. (Redis 6.0.20) </p> </li> <li> <p> (CVE-2023-28856) Authenticated users can use the <code> HINCRBYFLOAT </code> command to create an invalid hash field that will crash Redis on access. (Redis 6.0.19) </p> </li> <li> <p> (CVE-2023-25155) Specially crafted <code> SRANDMEMBER </code> , <code> ZRANDMEMBER </code> , and <code> HRANDFIELD </code> commands can trigger an integer overflow, resulting in a runtime assertion and termination of the Redis server process. (Redis 6.0.18) </p> </li> <li> <p> (CVE-2022-36021) String matching commands (like <code> SCAN </code> or <code> KEYS </code> ) with a specially crafted pattern to trigger a denial-of-service attack on Redis, causing it to hang and consume 100% CPU time. (Redis 6.0.18) </p> </li> <li> <p> (CVE-2022-35977) Integer overflow in the Redis <code> SETRANGE </code> and <code> SORT </code> / <code> SORT_RO </code> commands can drive Redis to OOM panic. (Redis 6.0.17) </p> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/release-notes/rs-7-4-2-releases/rs-7-4-2-126/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/users/.html
<section class="prose w-full py-12 max-w-none"> <h1> Users requests </h1> <p class="text-lg -mt-5 mb-10"> User requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#get-all-users"> GET </a> </td> <td> <code> /v1/users </code> </td> <td> Get all users </td> </tr> <tr> <td> <a href="#get-user"> GET </a> </td> <td> <code> /v1/users/{uid} </code> </td> <td> Get a single user </td> </tr> <tr> <td> <a href="#put-user"> PUT </a> </td> <td> <code> /v1/users/{uid} </code> </td> <td> Update a user's configuration </td> </tr> <tr> <td> <a href="#post-user"> POST </a> </td> <td> <code> /v1/users </code> </td> <td> Create a new user </td> </tr> <tr> <td> <a href="#delete-user"> DELETE </a> </td> <td> <code> /v1/users/{uid} </code> </td> <td> Delete a user </td> </tr> </tbody> </table> <h2 id="get-all-users"> Get all users </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/users </span></span></code></pre> </div> <p> Get a list of all users. </p> <h3 id="permissions"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_all_users_info"> view_all_users_info </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-all-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /users </span></span></code></pre> </div> <h4 id="headers"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h3 id="get-all-response"> Response </h3> <p> Returns a JSON array of <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user objects </a> . </p> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password_issue_date"</span><span class="p">:</span> <span class="s2">"2017-03-02T09:43:34Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"user@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"John Doe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"bdbs_email_alerts"</span><span class="p">:</span> <span class="p">[</span><span class="s2">"1"</span><span class="p">,</span><span class="s2">"2"</span><span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role"</span><span class="p">:</span> <span class="s2">"admin"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"status"</span><span class="p">:</span> <span class="s2">"active"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">2</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password_issue_date"</span><span class="p">:</span> <span class="s2">"2017-03-02T09:43:34Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"user2@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Jane Poe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role"</span><span class="p">:</span> <span class="s2">"db_viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"status"</span><span class="p">:</span> <span class="s2">"active"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">]</span> </span></span></code></pre> </div> <h3 id="get-all-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> No error </td> </tr> </tbody> </table> <h2 id="get-user"> Get user </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/users/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Get a single user's details. </p> <h3 id="permissions-1"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_user_info"> view_user_info </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-request"> Request </h3> <h4 id="example-http-request-1"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /users/1 </span></span></code></pre> </div> <h4 id="headers-1"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The user's unique ID </td> </tr> </tbody> </table> <h3 id="get-response"> Response </h3> <p> Returns a <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user object </a> that contains the details for the specified user ID. </p> <h4 id="example-json-body-1"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password_issue_date"</span><span class="p">:</span> <span class="s2">"2017-03-07T15:11:08Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role"</span><span class="p">:</span> <span class="s2">"db_viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"bdbs_email_alerts"</span><span class="p">:</span> <span class="p">[</span><span class="s2">"1"</span><span class="p">,</span><span class="s2">"2"</span><span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"user@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"John Doe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"status"</span><span class="p">:</span> <span class="s2">"active"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="get-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.4"> 403 Forbidden </a> </td> <td> Operation is forbidden. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> User does not exist. </td> </tr> </tbody> </table> <h2 id="put-user"> Update user </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /v1/users/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Update an existing user's configuration. </p> <h3 id="permissions-2"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_user"> update_user </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <p> Any user can change their own name, password, or alert preferences. </p> <h3 id="put-request"> Request </h3> <h4 id="example-http-request-2"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /users/1 </span></span></code></pre> </div> <h4 id="example-json-body-2"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">false</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role_uids"</span><span class="p">:</span> <span class="p">[</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">4</span> <span class="p">]</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="headers-2"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters-1"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The user's unique ID </td> </tr> </tbody> </table> <h4 id="request-body"> Request body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user object </a> with updated fields in the request body. </p> <h3 id="put-response"> Response </h3> <p> Returns the updated <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user object </a> . </p> <h4 id="example-json-body-3"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password_issue_date"</span><span class="p">:</span> <span class="s2">"2017-03-07T15:11:08Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"user@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Jane Poe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">false</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role"</span><span class="p">:</span> <span class="s2">"db_viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role_uids"</span><span class="p">:</span> <span class="p">[</span> <span class="mi">2</span><span class="p">,</span> <span class="mi">4</span> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> For <a href="/docs/latest/operate/rs/security/access-control/"> RBAC-enabled clusters </a> , the returned user details include <code> role_uids </code> instead of <code> role </code> . </div> </div> <h3 id="put-error-codes"> Error codes </h3> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> field that provide additional information. The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password_not_complex </td> <td> The given password is not complex enough (Only works when the password_complexity feature is enabled). </td> </tr> <tr> <td> new_password_same_as_current </td> <td> The given new password is identical to the old password. </td> </tr> <tr> <td> email_already_exists </td> <td> The given email is already taken. </td> </tr> <tr> <td> change_last_admin_role_not_allowed </td> <td> At least one user with admin role should exist. </td> </tr> </tbody> </table> <h3 id="put-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, the user is updated. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1"> 400 Bad Request </a> </td> <td> Bad or missing configuration parameters. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> Attempting to change a non-existing user. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> The requested configuration is invalid. </td> </tr> </tbody> </table> <h2 id="post-user"> Create user </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/users </span></span></code></pre> </div> <p> Create a new user. </p> <h3 id="permissions-3"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#create_new_user"> create_new_user </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="post-request"> Request </h3> <h4 id="example-http-request-3"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /users </span></span></code></pre> </div> <h4 id="headers-3"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="body"> Body </h4> <p> Include a single <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user object </a> in the request body. The user object must have an email, password, and role. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> For <a href="/docs/latest/operate/rs/security/access-control/"> RBAC-enabled clusters </a> , use <code> role_uids </code> instead of <code> role </code> in the request body. </div> </div> <p> <code> email_alerts </code> can be configured either as: </p> <ul> <li> <p> <code> true </code> - user will receive alerts for all databases configured in <code> bdbs_email_alerts </code> . The user will receive alerts for all databases by default if <code> bdbs_email_alerts </code> is not configured. <code> bdbs_email_alerts </code> can be a list of database UIDs or <code> [β€˜all’] </code> meaning all databases. </p> </li> <li> <p> <code> false </code> - user will not receive alerts for any databases </p> </li> </ul> <h5 id="example-json-body-4"> Example JSON body </h5> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"newuser@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password"</span><span class="p">:</span> <span class="s2">"my-password"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Pat Doe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"bdbs_email_alerts"</span><span class="p">:</span> <span class="p">[</span><span class="s2">"1"</span><span class="p">,</span><span class="s2">"2"</span><span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role_uids"</span><span class="p">:</span> <span class="p">[</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="post-response"> Response </h3> <p> Returns the newly created <a href="/docs/latest/operate/rs/references/rest-api/objects/user/"> user object </a> . </p> <h4 id="example-json-body-5"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"password_issue_date"</span><span class="p">:</span> <span class="s2">"2017-03-07T15:11:08Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email"</span><span class="p">:</span> <span class="s2">"newuser@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Pat Doe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"email_alerts"</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"bdbs_email_alerts"</span><span class="p">:</span> <span class="p">[</span><span class="s2">"1"</span><span class="p">,</span><span class="s2">"2"</span><span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role"</span><span class="p">:</span> <span class="s2">"db_viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"role_uids"</span><span class="p">:</span> <span class="p">[</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">4</span> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="post-error-codes"> Error codes </h3> <p> When errors are reported, the server may return a JSON object with <code> error_code </code> and <code> message </code> field that provide additional information. </p> <p> The following are possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> password_not_complex </td> <td> The given password is not complex enough (Only works when the password_complexity feature is enabled). </td> </tr> <tr> <td> email_already_exists </td> <td> The given email is already taken. </td> </tr> <tr> <td> name_already_exists </td> <td> The given name is already taken. </td> </tr> </tbody> </table> <h3 id="post-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, user is created. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1"> 400 Bad Request </a> </td> <td> Bad or missing configuration parameters. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10"> 409 Conflict </a> </td> <td> User with the same email already exists. </td> </tr> </tbody> </table> <h3 id="examples"> Examples </h3> <h4 id="curl"> cURL </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ curl -k -X POST -u <span class="s1">'[username]:[password]'</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> -H <span class="s1">'Content-Type: application/json'</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> -d <span class="s1">'{ "email": "newuser@example.com", \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "password": "my-password", \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "name": "Pat Doe", \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "email_alerts": true, \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "bdbs_email_alerts": ["1","2"], \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "role_uids": [ 3, 4 ], \ </span></span></span><span class="line"><span class="cl"><span class="s1"> "auth_method": "regular" }'</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> <span class="s1">'https://[host][:port]/v1/users'</span> </span></span></code></pre> </div> <h4 id="python"> Python </h4> <div class="highlight"> <pre class="chroma"><code class="language-python" data-lang="python"><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">requests</span> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">json</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">url</span> <span class="o">=</span> <span class="s2">"https://[host][:port]/v1/users"</span> </span></span><span class="line"><span class="cl"><span class="n">auth</span> <span class="o">=</span> <span class="p">(</span><span class="s2">"[username]"</span><span class="p">,</span> <span class="s2">"[password]"</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">payload</span> <span class="o">=</span> <span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">({</span> </span></span><span class="line"><span class="cl"> <span class="s2">"email"</span><span class="p">:</span> <span class="s2">"newuser@example.com"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"password"</span><span class="p">:</span> <span class="s2">"my-password"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"name"</span><span class="p">:</span> <span class="s2">"Pat Doe"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"email_alerts"</span><span class="p">:</span> <span class="kc">True</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"bdbs_email_alerts"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="s2">"1"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"2"</span> </span></span><span class="line"><span class="cl"> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="s2">"role_uids"</span><span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="mi">3</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="mi">4</span> </span></span><span class="line"><span class="cl"> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="s2">"auth_method"</span><span class="p">:</span> <span class="s2">"regular"</span> </span></span><span class="line"><span class="cl"><span class="p">})</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">headers</span> <span class="o">=</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="s1">'Content-Type'</span><span class="p">:</span> <span class="s1">'application/json'</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">response</span> <span class="o">=</span> <span class="n">requests</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s2">"POST"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">auth</span><span class="o">=</span><span class="n">auth</span><span class="p">,</span> <span class="n">headers</span><span class="o">=</span><span class="n">headers</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">payload</span><span class="p">,</span> <span class="n">verify</span><span class="o">=</span><span class="kc">False</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">response</span><span class="o">.</span><span class="n">text</span><span class="p">)</span> </span></span></code></pre> </div> <h2 id="delete-user"> Delete user </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /v1/users/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Delete a user. </p> <h3 id="permissions-4"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#delete_user"> delete_user </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="delete-request"> Request </h3> <h4 id="example-http-request-4"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /users/1 </span></span></code></pre> </div> <h4 id="headers-4"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters-2"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The user's unique ID </td> </tr> </tbody> </table> <h3 id="delete-response"> Response </h3> <p> Returns a status code to indicate the success or failure of the user deletion. </p> <h3 id="delete-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, the user is deleted. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> The request is not acceptable. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/users/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/security/encryption/tls/tls-protocols/.html
<section class="prose w-full py-12 max-w-none"> <h1> Configure TLS protocol </h1> <p> You can change TLS protocols to improve the security of your Redis Enterprise cluster and databases. The default settings are in line with industry best practices, but you can customize them to match the security policy of your organization. </p> <h2 id="configure-tls-protocol"> Configure TLS protocol </h2> <p> The communications for which you can modify TLS protocols are: </p> <ul> <li> Control plane - The TLS configuration for cluster administration. </li> <li> Data plane - The TLS configuration for the communication between applications and databases. </li> <li> Discovery service (Sentinel) - The TLS configuration for the <a href="/docs/latest/operate/rs/databases/durability-ha/discovery-service/"> discovery service </a> . </li> </ul> <p> You can configure TLS protocols with the <a href="#edit-tls-ui"> Cluster Manager UI </a> , <a href="/docs/latest/operate/rs/references/cli-utilities/rladmin/cluster/config/"> <code> rladmin </code> </a> , or the <a href="/docs/latest/operate/rs/references/rest-api/requests/cluster/#put-cluster"> REST API </a> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Warning: </div> <ul> <li> <p> After you set the minimum TLS version, Redis Enterprise Software does not accept communications with TLS versions older than the specified version. </p> </li> <li> <p> If you set TLS 1.3 as the minimum TLS version, clients must support TLS 1.3 to connect to Redis Enterprise. </p> </li> </ul> </div> </div> <p> TLS support depends on the operating system. You cannot enable support for protocols or versions that aren't supported by the operating system running Redis Enterprise Software. In addition, updates to the operating system or to Redis Enterprise Software can impact protocol and version support. </p> <p> If you have trouble enabling specific versions of TLS, verify that they're supported by your operating system and that they're configured correctly. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> TLSv1.2 is generally recommended as the minimum TLS version for encrypted communications. Check with your security team to confirm which TLS protocols meet your organization's policies. </div> </div> <h3 id="edit-tls-ui"> Edit TLS settings in the UI </h3> <p> To configure minimum TLS versions using the Cluster Manager UI: </p> <ol> <li> <p> Go to <strong> Cluster &gt; Security </strong> , then select the <strong> TLS </strong> tab. </p> </li> <li> <p> Click <strong> Edit </strong> . </p> </li> <li> <p> Select the minimum TLS version for cluster connections, database connections, and the discovery service: </p> <a href="/docs/latest/images/rs/screenshots/cluster/security-tls-protocols-edit.png" sdata-lightbox="/images/rs/screenshots/cluster/security-tls-protocols-edit.png"> <img alt="Cluster &gt; Security &gt; TLS settings in edit mode in the Cluster Manager UI." src="/docs/latest/images/rs/screenshots/cluster/security-tls-protocols-edit.png"/> </a> </li> <li> <p> Select the TLS mode for the discovery service: </p> <ul> <li> <strong> Allowed </strong> - Allows both TLS and non-TLS connections </li> <li> <strong> Required </strong> - Allows only TLS connections </li> <li> <strong> Disabled </strong> - Allows only non-TLS connections </li> </ul> </li> <li> <p> Click <strong> Save </strong> . </p> </li> </ol> <h3 id="control-plane-tls"> Control plane TLS </h3> <p> To set the minimum TLS protocol for the control plane using <code> rladmin </code> : </p> <ul> <li> Default minimum TLS protocol: TLSv1.2 </li> <li> Syntax: <code> rladmin cluster config min_control_TLS_version &lt;TLS_Version&gt; </code> </li> <li> TLS versions available: <ul> <li> For TLSv1.2 - 1.2 </li> <li> For TLSv1.3 - 1.3 </li> </ul> </li> </ul> <p> For example: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin cluster config min_control_TLS_version 1.2 </span></span></code></pre> </div> <h3 id="data-plane-tls"> Data plane TLS </h3> <p> To set the minimum TLS protocol for the data path using <code> rladmin </code> : </p> <ul> <li> Default minimum TLS protocol: TLSv1.2 </li> <li> Syntax: <code> rladmin cluster config min_data_TLS_version &lt;TLS_Version&gt; </code> </li> <li> TLS versions available: <ul> <li> For TLSv1.2 - 1.2 </li> <li> For TLSv1.3 - 1.3 </li> </ul> </li> </ul> <p> For example: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin cluster config min_data_TLS_version 1.2 </span></span></code></pre> </div> <h3 id="discovery-service-tls"> Discovery service TLS </h3> <p> To enable TLS for the discovery service using <code> rladmin </code> : </p> <ul> <li> Default: Allows both TLS and non-TLS connections </li> <li> Syntax: <code> rladmin cluster config sentinel_tls_mode &lt;ssl_policy&gt; </code> </li> <li> <code> ssl_policy </code> values available: <ul> <li> <code> allowed </code> - Allows both TLS and non-TLS connections </li> <li> <code> required </code> - Allows only TLS connections </li> <li> <code> disabled </code> - Allows only non-TLS connections </li> </ul> </li> </ul> <p> To set the minimum TLS protocol for the discovery service using <code> rladmin </code> : </p> <ul> <li> Default minimum TLS protocol: TLSv1.2 </li> <li> Syntax: <code> rladmin cluster config min_sentinel_TLS_version &lt;TLS_Version&gt; </code> </li> <li> TLS versions available: <ul> <li> For TLSv1.2 - 1.2 </li> <li> For TLSv1.3 - 1.3 </li> </ul> </li> </ul> <p> To enforce a minimum TLS version for the discovery service, run the following commands: </p> <ol> <li> <p> Allow only TLS connections: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin cluster config sentinel_tls_mode required </span></span></code></pre> </div> </li> <li> <p> Set the minimal TLS version: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">rladmin cluster config min_sentinel_TLS_version 1.2 </span></span></code></pre> </div> </li> <li> <p> Restart the discovery service on all cluster nodes to apply your changes: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">supervisorctl restart sentinel_service </span></span></code></pre> </div> </li> </ol> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/security/encryption/tls/tls-protocols/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/tdigest.create/.html
<section class="prose w-full py-12"> <h1 class="command-name"> TDIGEST.CREATE </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">TDIGEST.CREATE key [COMPRESSIONΒ compression]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 2.4.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) </dd> </dl> <p> Allocates memory and initializes a new t-digest sketch. </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> key </code> </summary> is key name for this new t-digest sketch. </details> <h2 id="optional-arguments"> Optional arguments </h2> <details open=""> <summary> <code> COMPRESSION compression </code> </summary> <p> is a controllable tradeoff between accuracy and memory consumption. 100 is a common value for normal uses. 1000 is more accurate. If no value is passed by default the compression will be 100. For more information on scaling of accuracy versus the compression parameter see <a href="https://www.sciencedirect.com/science/article/pii/S2665963820300403"> <em> The t-digest: Efficient estimates of distributions </em> </a> . </p> </details> <h2 id="return-value"> Return value </h2> <p> <a href="/docs/latest/develop/reference/protocol-spec/#simple-strings"> Simple string reply </a> - <code> OK </code> if executed correctly, or [] otherwise. </p> <h2 id="examples"> Examples </h2> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis&gt; TDIGEST.CREATE t COMPRESSION <span class="m">100</span> </span></span><span class="line"><span class="cl">OK</span></span></code></pre> </div> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/tdigest.create/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-deploy/.html
<section class="prose w-full py-12"> <h1> redis-di deploy </h1> <p class="text-lg -mt-5 mb-10"> Deploys the RDI configurations including target </p> <h2 id="usage"> Usage </h2> <pre tabindex="0"><code>Usage: redis-di deploy [OPTIONS] </code></pre> <h2 id="options"> Options </h2> <ul> <li> <p> <code> log_level </code> : </p> <ul> <li> Type: Choice(['DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL']) </li> <li> Default: <code> info </code> </li> <li> Usage: <code> --log-level -l </code> </li> </ul> </li> <li> <p> <code> rdi_host </code> (REQUIRED): </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-host </code> </li> </ul> <p> Host/IP of RDI Database </p> </li> <li> <p> <code> rdi_port </code> (REQUIRED): </p> <ul> <li> Type: &lt;IntRange 1&lt;=x&lt;=65535&gt; </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-port </code> </li> </ul> <p> Port of RDI Database </p> </li> <li> <p> <code> rdi_user </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-user </code> </li> </ul> <p> RDI Database Username </p> </li> <li> <p> <code> rdi_password </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-password </code> </li> </ul> <p> RDI Database Password </p> </li> <li> <p> <code> rdi_key </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-key </code> </li> </ul> <p> Private key file to authenticate with </p> </li> <li> <p> <code> rdi_cert </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-cert </code> </li> </ul> <p> Client certificate file to authenticate with </p> </li> <li> <p> <code> rdi_cacert </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-cacert </code> </li> </ul> <p> CA certificate file to verify with </p> </li> <li> <p> <code> rdi_key_password </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --rdi-key-password </code> </li> </ul> <p> Password for unlocking an encrypted private key </p> </li> <li> <p> <code> directory </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> . </code> </li> <li> Usage: <code> --dir </code> </li> </ul> <p> Directory containing RDI configuration </p> </li> <li> <p> <code> help </code> : </p> <ul> <li> Type: BOOL </li> <li> Default: <code> false </code> </li> <li> Usage: <code> --help </code> </li> </ul> <p> Show this message and exit. </p> </li> </ul> <h2 id="cli-help"> CLI help </h2> <pre tabindex="0"><code>Usage: redis-di deploy [OPTIONS] Deploys the RDI configurations including target Options: -l, --log-level [DEBUG|INFO|WARN|ERROR|CRITICAL] [default: INFO] --rdi-host TEXT Host/IP of RDI Database [required] --rdi-port INTEGER RANGE Port of RDI Database [1&lt;=x&lt;=65535; required] --rdi-user TEXT RDI Database Username --rdi-password TEXT RDI Database Password --rdi-key TEXT Private key file to authenticate with --rdi-cert TEXT Client certificate file to authenticate with --rdi-cacert TEXT CA certificate file to verify with --rdi-key-password TEXT Password for unlocking an encrypted private key --dir TEXT Directory containing RDI configuration [default: .] --help Show this message and exit. </code></pre> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-deploy/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/stop_traffic/.html
<section class="prose w-full py-12 max-w-none"> <h1> Stop database traffic requests </h1> <p class="text-lg -mt-5 mb-10"> REST API requests to stop traffic for a database </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#post-bdbs-actions-stop-traffic"> POST </a> </td> <td> <code> /v1/bdbs/{uid}/actions/stop_traffic </code> </td> <td> Stop database traffic </td> </tr> </tbody> </table> <h2 id="post-bdbs-actions-stop-traffic"> Stop database traffic </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/bdbs/<span class="o">{</span>int: uid<span class="o">}</span>/actions/stop_traffic </span></span></code></pre> </div> <p> Stop handling traffic for the database. </p> <p> Use this action to stop read and write traffic on a database. To resume traffic afterward, use the <a href="/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/resume_traffic/"> <code> resume_traffic </code> </a> action. </p> <h4 id="required-permissions"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_bdb_with_action"> update_bdb_with_action </a> </td> <td> admin <br/> cluster_member <br/> db_member </td> </tr> </tbody> </table> <h3 id="post-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /bdbs/1/actions/stop_traffic </span></span></code></pre> </div> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The unique ID of the database. </td> </tr> </tbody> </table> <h3 id="post-response"> Response </h3> <p> Returns a JSON object with an <code> action_uid </code> . You can track the action's progress with a <a href="/docs/latest/operate/rs/references/rest-api/requests/actions/#get-action"> <code> GET /v1/actions/&lt;action_uid&gt; </code> </a> request. </p> <h4 id="post-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-200-ok"> 200 OK </a> </td> <td> The request is accepted and is being processed. The database state will be <code> active-change-pending </code> until the request has been fully processed. </td> </tr> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-404-not-found"> 404 Not Found </a> </td> <td> Attempting to perform an action on a nonexistent database. </td> </tr> <tr> <td> <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-409-conflict"> 409 Conflict </a> </td> <td> Attempting to change a database while it is busy with another configuration change. This is a temporary condition, and the request should be reattempted later. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/bdbs/actions/stop_traffic/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/clusters/new-cluster-setup/.html
<section class="prose w-full py-12 max-w-none"> <h1> Set up a new cluster </h1> <p class="text-lg -mt-5 mb-10"> How to set up a new cluster using the management UI. </p> <p> A Redis Enterprise Software cluster typically consists of several nodes. For production deployments, we recommend an uneven number of nodes, with a minimum of three. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> In a cluster that consists of only one node, some features and capabilities are not enabled, such as database replication that provides high availability. </div> </div> <p> To set up a new cluster, you must first <a href="/docs/latest/operate/rs/installing-upgrading/"> install the Redis Enterprise Software package </a> and then set up the cluster as described below. After the cluster is created you can <a href="/docs/latest/operate/rs/clusters/add-node/"> add multiple nodes to the cluster </a> . </p> <p> To create a cluster: </p> <ol> <li> <p> In a browser, go to <code> https://&lt;name or IP address of the machine with Redis Enterprise Software installed&gt;:8443 </code> . For example, if you installed Redis Enterprise SoftwareΒ on a machine with IP address 10.0.1.34, go to <a href="https://10.0.1.34:8443"> https://10.0.1.34:8443 </a> . </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> <ul> <li> TheΒ management UI uses a <a href="/docs/latest/operate/rs/security/certificates/updating-certificates/"> self-signed certificate for TLS encryption </a> . </li> <li> If the machine has both an internal IP address and an external IP address, use the external IP address to access the setup UI. </li> </ul> </div> </div> </li> <li> <p> Select <strong> Create new cluster </strong> . </p> </li> <li> <p> Enter an email and password for the administrator account, then select <strong> Next </strong> to proceed to cluster setup. </p> </li> <li> <p> Enter your cluster license key if you have one. Otherwise, the cluster uses the trial license by default. </p> </li> <li> <p> In the <strong> Configuration </strong> section: </p> <ol> <li> <p> For <strong> FQDN (Fully Qualified Domain Name) </strong> , enter a unique name for the cluster. </p> <p> See the <a href="/docs/latest/operate/rs/networking/cluster-dns/"> instructions for DNS setup </a> to make sure your cluster is reachable by name. </p> </li> <li> <p> Choose whether to <a href="/docs/latest/operate/rs/networking/private-public-endpoints/"> <strong> Enable private &amp; public endpoints support </strong> </a> . </p> </li> <li> <p> Choose whether to <a href="/docs/latest/operate/rs/clusters/configure/rack-zone-awareness/"> <strong> Enable rack-zone awareness </strong> </a> . </p> </li> </ol> </li> <li> <p> Click <strong> Next </strong> . </p> </li> <li> <p> Configure storage and network settings: </p> <ol> <li> <p> Enter a path for <a href="/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/"> <em> Ephemeral storage </em> </a> , or leave the default path. </p> </li> <li> <p> Enter a path for <a href="/docs/latest/operate/rs/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage/"> <em> Persistent storage </em> </a> , or leave the default path. </p> </li> <li> <p> To enable <a href="/docs/latest/operate/rs/databases/auto-tiering/"> <em> Auto Tiering </em> </a> , select <strong> Enable flash storage </strong> and enter the path to the flash storage. </p> </li> <li> <p> If the cluster is configured to support <a href="/docs/latest/operate/rs/clusters/configure/rack-zone-awareness/"> rack-zone awareness </a> , set the <strong> Rack-zone ID </strong> for the new node. </p> </li> <li> <p> If your machine has multiple IP addresses, assign a single IPv4 type address for <strong> Node-to-node communication (internal traffic) </strong> and multiple IPv4/IPv6 type addresses for <strong> External traffic </strong> . </p> </li> </ol> </li> <li> <p> Select <strong> Create cluster </strong> . </p> </li> <li> <p> Click <strong> OK </strong> to confirm that you are aware of the replacement of the HTTPS TLS certificate on the node, and proceed through the browser warning. </p> </li> </ol> <p> After a short wait, your cluster is created and you can sign in to the Cluster Manager UI. </p> <p> You can now access any of the management capabilities, including: </p> <ul> <li> <a href="/docs/latest/operate/rs/databases/create/"> Creating a new database </a> </li> <li> <a href="/docs/latest/operate/rs/clusters/add-node/"> Joining a new node to a cluster </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/clusters/new-cluster-setup/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/roles/.html
<section class="prose w-full py-12 max-w-none"> <h1> Roles requests </h1> <p class="text-lg -mt-5 mb-10"> Roles requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#get-all-roles"> GET </a> </td> <td> <code> /v1/roles </code> </td> <td> Get all roles </td> </tr> <tr> <td> <a href="#get-role"> GET </a> </td> <td> <code> /v1/roles/{uid} </code> </td> <td> Get a single role </td> </tr> <tr> <td> <a href="#put-role"> PUT </a> </td> <td> <code> /v1/roles/{uid} </code> </td> <td> Update an existing role </td> </tr> <tr> <td> <a href="#post-role"> POST </a> </td> <td> <code> /v1/roles </code> </td> <td> Create a new role </td> </tr> <tr> <td> <a href="#delete-role"> DELETE </a> </td> <td> <code> /v1/roles/{uid} </code> </td> <td> Delete a role </td> </tr> </tbody> </table> <h2 id="get-all-roles"> Get all roles </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/roles </span></span></code></pre> </div> <p> Get all roles' details. </p> <h3 id="permissions"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_all_roles_info"> view_all_roles_info </a> </td> <td> admin <br/> cluster_member <br/> cluster_viewer <br/> db_member <br/> db_viewer <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-all-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /roles </span></span></code></pre> </div> <h4 id="headers"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h3 id="get-all-response"> Response </h3> <p> Returns a JSON array of <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role objects </a> . </p> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Admin"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">2</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Cluster Member"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"cluster_member"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">3</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"Cluster Viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"cluster_viewer"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">4</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DB Member"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"db_member"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">5</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DB Viewer"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"db_viewer"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">6</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"None"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"none"</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">17</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">]</span> </span></span></code></pre> </div> <h4 id="get-all-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> No error </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.2"> 501 Not Implemented </a> </td> <td> Cluster doesn't support roles yet. </td> </tr> </tbody> </table> <h2 id="get-role"> Get role </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /v1/roles/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Get the details of a single role. </p> <h3 id="permissions-1"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_role_info"> view_role_info </a> </td> <td> admin <br/> cluster_member <br/> cluster_viewer <br/> db_member <br/> db_viewer <br/> user_manager </td> </tr> </tbody> </table> <h3 id="get-request"> Request </h3> <h4 id="example-http-request-1"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">GET /roles/1 </span></span></code></pre> </div> <h4 id="headers-1"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The role's unique ID. </td> </tr> </tbody> </table> <h3 id="get-response"> Response </h3> <p> Returns a <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role object </a> . </p> <h4 id="example-json-body-1"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">17</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="get-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.4"> 403 Forbidden </a> </td> <td> Operation is forbidden. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> Role does not exist. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.2"> 501 Not Implemented </a> </td> <td> Cluster doesn't support roles yet. </td> </tr> </tbody> </table> <h2 id="put-role"> Update role </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /v1/roles/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Update an existing role's details. </p> <h3 id="permissions-2"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#update_role"> update_role </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="put-request"> Request </h3> <h4 id="example-http-request-2"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">PUT /roles/17 </span></span></code></pre> </div> <h4 id="example-json-body-2"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"cluster_member"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="headers-2"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="body"> Body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role object </a> with updated fields in the request body. </p> <h3 id="put-response"> Response </h3> <p> Returns a <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role object </a> with the updated fields. </p> <h4 id="example-json-body-3"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">17</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"cluster_member"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="put-error-codes"> Error codes </h3> <p> Possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> unsupported_resource </td> <td> The cluster is not yet able to handle this resource type. This could happen in a partially upgraded cluster, where some of the nodes are still on a previous version. </td> </tr> <tr> <td> name_already_exists </td> <td> An object of the same type and name exists. </td> </tr> <tr> <td> change_last_admin_role_not_allowed </td> <td> At least one user with admin role should exist. </td> </tr> </tbody> </table> <h4 id="put-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, role is created. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1"> 400 Bad Request </a> </td> <td> Bad or missing configuration parameters. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> Attempting to change a non-existant role. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.2"> 501 Not Implemented </a> </td> <td> Cluster doesn't support roles yet. </td> </tr> </tbody> </table> <h2 id="post-role"> Create role </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /v1/roles </span></span></code></pre> </div> <p> Create a new role. </p> <h3 id="permissions-3"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#create_role"> create_role </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="post-request"> Request </h3> <h4 id="example-http-request-3"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">POST /roles </span></span></code></pre> </div> <h4 id="example-json-body-4"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h4 id="headers-3"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="body-1"> Body </h4> <p> Include a <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role object </a> in the request body. </p> <h3 id="post-response"> Response </h3> <p> Returns the newly created <a href="/docs/latest/operate/rs/references/rest-api/objects/role/"> role object </a> . </p> <h4 id="example-json-body-5"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span><span class="p">:</span> <span class="mi">17</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span></code></pre> </div> <h3 id="post-error-codes"> Error codes </h3> <p> Possible <code> error_code </code> values: </p> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> unsupported_resource </td> <td> The cluster is not yet able to handle this resource type. This could happen in a partially upgraded cluster, where some of the nodes are still on a previous version. </td> </tr> <tr> <td> name_already_exists </td> <td> An object of the same type and name exists </td> </tr> <tr> <td> missing_field </td> <td> A needed field is missing </td> </tr> </tbody> </table> <h4 id="post-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, role is created. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1"> 400 Bad Request </a> </td> <td> Bad or missing configuration parameters. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.2"> 501 Not Implemented </a> </td> <td> Cluster doesn't support roles yet. </td> </tr> </tbody> </table> <h3 id="examples"> Examples </h3> <h4 id="curl"> cURL </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">curl -k -u <span class="s2">"[username]:[password]"</span> -X POST <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> -H <span class="s1">'Content-Type: application/json'</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> -d <span class="s1">'{ "name": "DBA", "management": "admin" }'</span> <span class="se">\ </span></span></span><span class="line"><span class="cl"><span class="se"></span> https://<span class="o">[</span>host<span class="o">][</span>:port<span class="o">]</span>/v1/roles </span></span></code></pre> </div> <h4 id="python"> Python </h4> <div class="highlight"> <pre class="chroma"><code class="language-python" data-lang="python"><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">requests</span> </span></span><span class="line"><span class="cl"><span class="kn">import</span> <span class="nn">json</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">url</span> <span class="o">=</span> <span class="s2">"https://[host][:port]/v1/roles"</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">headers</span> <span class="o">=</span> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="s1">'Content-Type'</span><span class="p">:</span> <span class="s1">'application/json'</span> </span></span><span class="line"><span class="cl"><span class="p">}</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">payload</span> <span class="o">=</span> <span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">({</span> </span></span><span class="line"><span class="cl"> <span class="s2">"name"</span><span class="p">:</span> <span class="s2">"DBA"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="s2">"management"</span><span class="p">:</span> <span class="s2">"admin"</span> </span></span><span class="line"><span class="cl"><span class="p">})</span> </span></span><span class="line"><span class="cl"><span class="n">auth</span><span class="o">=</span><span class="p">(</span><span class="s2">"[username]"</span><span class="p">,</span> <span class="s2">"[password]"</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="n">response</span> <span class="o">=</span> <span class="n">requests</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s2">"POST"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="n">auth</span><span class="o">=</span><span class="n">auth</span><span class="p">,</span> <span class="n">headers</span><span class="o">=</span><span class="n">headers</span><span class="p">,</span> <span class="n">payload</span><span class="o">=</span><span class="n">payload</span><span class="p">,</span> <span class="n">verify</span><span class="o">=</span><span class="kc">False</span><span class="p">)</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl"><span class="nb">print</span><span class="p">(</span><span class="n">response</span><span class="o">.</span><span class="n">text</span><span class="p">)</span> </span></span></code></pre> </div> <h2 id="delete-role"> Delete role </h2> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /v1/roles/<span class="o">{</span>int: uid<span class="o">}</span> </span></span></code></pre> </div> <p> Delete a role object. </p> <h3 id="permissions-4"> Permissions </h3> <table> <thead> <tr> <th> Permission name </th> <th> Roles </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#delete_role"> delete_role </a> </td> <td> admin <br/> user_manager </td> </tr> </tbody> </table> <h3 id="delete-request"> Request </h3> <h4 id="example-http-request-4"> Example HTTP request </h4> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">DELETE /roles/1 </span></span></code></pre> </div> <h4 id="headers-4"> Headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="url-parameters-1"> URL parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> uid </td> <td> integer </td> <td> The role unique ID. </td> </tr> </tbody> </table> <h3 id="delete-response"> Response </h3> <p> Returns a status code to indicate role deletion success or failure. </p> <h4 id="delete-status-codes"> Status codes </h4> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> Success, the role is deleted. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5"> 404 Not Found </a> </td> <td> Role does not exist. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.7"> 406 Not Acceptable </a> </td> <td> The request is not acceptable. </td> </tr> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.2"> 501 Not Implemented </a> </td> <td> Cluster doesn't support roles yet. </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/roles/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/rpop/.html
<section class="prose w-full py-12"> <h1 class="command-name"> RPOP </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">RPOP key [count]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 1.0.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(N) where N is the number of elements returned </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @write </code> <span class="mr-1 last:hidden"> , </span> <code> @list </code> <span class="mr-1 last:hidden"> , </span> <code> @fast </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Removes and returns the last elements of the list stored at <code> key </code> . </p> <p> By default, the command pops a single element from the end of the list. When provided with the optional <code> count </code> argument, the reply will consist of up to <code> count </code> elements, depending on the list's length. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; RPUSH mylist "one" "two" "three" "four" "five" (integer) 5 redis&gt; RPOP mylist "five" redis&gt; RPOP mylist 2 1) "four" 2) "three" redis&gt; LRANGE mylist 0 -1 1) "one" 2) "two" </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="resp2-reply"> RESP2 Reply </h2> <p> One of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#bulk-strings"> Nil reply </a> : if the key does not exist. </li> <li> <a href="../../develop/reference/protocol-spec#bulk-strings"> Bulk string reply </a> : when called without the <em> count </em> argument, the value of the last element. </li> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : when called with the <em> count </em> argument, a list of popped elements. </li> </ul> <h2 id="resp3-reply"> RESP3 Reply </h2> <p> One of the following: </p> <ul> <li> <a href="../../develop/reference/protocol-spec#nulls"> Null reply </a> : if the key does not exist. </li> <li> <a href="../../develop/reference/protocol-spec#bulk-strings"> Bulk string reply </a> : when called without the <em> count </em> argument, the value of the last element. </li> <li> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : when called with the <em> count </em> argument, a list of popped elements. </li> </ul> <br/> <h2> History </h2> <ul> <li> Starting with Redis version 6.2.0: Added the <code> count </code> argument. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/rpop/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/topk.incrby.html
<section class="prose w-full py-12"> <h1 class="command-name"> TOPK.INCRBY </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">TOPK.INCRBY key item increment [item increment ...]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/data-types/probabilistic"> Bloom 2.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(n * k * incr) where n is the number of items, k is the depth and incr is the increment </dd> </dl> <p> Increase the score of an item in the data structure by increment. Multiple items' score can be increased at once. If an item enters the Top-K list, the item which is expelled is returned. </p> <h3 id="parameters"> Parameters </h3> <ul> <li> <strong> key </strong> : Name of sketch where item is added. </li> <li> <strong> item </strong> : Item/s to be added. </li> <li> <strong> increment </strong> : increment to current item score. Increment must be greater or equal to 1. Increment is limited to 100,000 to avoid server freeze. </li> </ul> <h2 id="return"> Return </h2> <p> <a href="/docs/latest/develop/reference/protocol-spec/#arrays"> Array reply </a> of <a href="/docs/latest/develop/reference/protocol-spec/#simple-strings"> Simple string reply </a> - if an element was dropped from the TopK list, <a href="/docs/latest/develop/reference/protocol-spec/#bulk-strings"> Nil reply </a> otherwise.. </p> <p> @example </p> <pre tabindex="0"><code>redis&gt; TOPK.INCRBY topk foo 3 bar 2 42 30 1) (nil) 2) (nil) 3) foo </code></pre> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/topk.incrby/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/amazon-bedrock/.html
<section class="prose w-full py-12 max-w-none"> <h1> Amazon Bedrock </h1> <p class="text-lg -mt-5 mb-10"> Shows how to use your Redis database with Amazon Bedrock to customize foundational models. </p> <p> <a href="https://aws.amazon.com/bedrock/"> Amazon Bedrock </a> streamlines GenAI deployment by offering foundational models (FMs) as a unified API, eliminating complex infrastructure management. It lets you create AI-powered <a href="https://aws.amazon.com/bedrock/agents/"> Agents </a> that execute complex tasks. Through <a href="https://aws.amazon.com/bedrock/knowledge-bases/"> Knowledge Bases </a> within Amazon Bedrock, you can seamlessly tether FMs to your proprietary data sources using retrieval-augmented generation (RAG). This direct integration amplifies the FM's intelligence based on your organization's resources. </p> <p> Amazon Bedrock lets you choose Redis Cloud as the <a href="https://redis.io/solutions/vector-search/"> vector database </a> for your agent's Knowledge Base. Once Redis Cloud is integrated with Amazon Bedrock, it automatically reads text documents from your Amazon Simple Storage Service (S3) buckets. This process lets the large language model (LLM) pinpoint and extract pertinent context in response to user queries, ensuring your AI agents are well-informed and grounded in their responses. </p> <p> For more information about the Redis integration with Amazon Bedrock, see the <a href="https://redis.io/blog/amazon-bedrock-integration-with-redis-enterprise/"> Amazon Bedrock integration blog post </a> . </p> <p> To fully set up Bedrock with Redis Cloud, you will need to do the following: </p> <ol> <li> <p> <a href="/docs/latest/integrate/amazon-bedrock/set-up-redis/"> Set up a Redis Cloud subscription and vector database </a> for Bedrock. </p> </li> <li> <p> <a href="/docs/latest/integrate/amazon-bedrock/create-knowledge-base/"> Create a knowledge base </a> connected to your vector database. </p> </li> <li> <p> <a href="/docs/latest/integrate/amazon-bedrock/create-agent/"> Create an agent </a> connected to your knowledge base. </p> </li> </ol> <h2 id="more-info"> More info </h2> <ul> <li> <a href="https://redis.io/blog/amazon-bedrock-integration-with-redis-enterprise/"> Amazon Bedrock integration blog post </a> </li> <li> <a href="https://github.com/RedisVentures/aws-redis-bedrock-stack/blob/main/README.md"> Detailed steps </a> </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/amazon-bedrock/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/ft.aggregate/.html
<section class="prose w-full py-12"> <h1 class="command-name"> FT.AGGREGATE </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">FT.AGGREGATE index query [VERBATIM] [LOAD count field [field ...]] [TIMEOUT timeout] [ GROUPBY nargs property [property ...] [ REDUCE function nargs arg [arg ...] [AS name] [ REDUCE function nargs arg [arg ...] [AS name] ...]] ...]] [ SORTBY nargs [ property ASC | DESC [ property ASC | DESC ...]] [MAX num] [WITHCOUNT] [ APPLY expression AS name [ APPLY expression AS name ...]] [ LIMIT offset num] [FILTER filter] [ WITHCURSOR [COUNT read_size] [MAXIDLE idle_time]] [ PARAMS nargs name value [ name value ...]] [ADDSCORES] [DIALECT dialect] </pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/interact/search-and-query"> Search 1.1.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) </dd> </dl> <p> Run a search query on an index, and perform aggregate transformations on the results, extracting statistics etc from them </p> <p> <a href="#examples"> Examples </a> </p> <h2 id="required-arguments"> Required arguments </h2> <details open=""> <summary> <code> index </code> </summary> <p> is index name against which the query is executed. You must first create the index using <a href="/docs/latest/commands/ft.create/"> <code> FT.CREATE </code> </a> . </p> </details> <details open=""> <summary> <code> query </code> </summary> <p> is base filtering query that retrieves the documents. It follows the exact same syntax as the search query, including filters, unions, not, optional, and so on. </p> </details> <h2 id="optional-arguments"> Optional arguments </h2> <details open=""> <summary> <code> VERBATIM </code> </summary> <p> if set, does not try to use stemming for query expansion but searches the query terms verbatim. </p> </details> <details open=""> <summary> <code> LOAD {nargs} {identifier} AS {property} … </code> </summary> <p> loads document attributes from the source document. </p> <ul> <li> <code> identifier </code> is either an attribute name for hashes and JSON or a JSON Path expression for JSON. </li> <li> <code> property </code> is the optional name used in the result. If it is not provided, the <code> identifier </code> is used. This should be avoided. </li> <li> If <code> * </code> is used as <code> nargs </code> , all attributes in a document are loaded. </li> </ul> <p> Attributes needed for aggregations should be stored as <code> SORTABLE </code> , where they are available to the aggregation pipeline with very low latency. <code> LOAD </code> hurts the performance of aggregate queries considerably because every processed record needs to execute the equivalent of <a href="/docs/latest/commands/hmget/"> <code> HMGET </code> </a> against a Redis key, which when executed over millions of keys, amounts to high processing times. </p> <details open=""> <summary> <code> GROUPBY {nargs} {property} </code> </summary> <p> groups the results in the pipeline based on one or more properties. Each group should have at least one <em> reducer </em> , a function that handles the group entries, either counting them, or performing multiple aggregate operations (see below). </p> <details open=""> <summary> <code> REDUCE {func} {nargs} {arg} … [AS {name}] </code> </summary> <p> reduces the matching results in each group into a single record, using a reduction function. For example, <code> COUNT </code> counts the number of records in the group. The reducers can have their own property names using the <code> AS {name} </code> optional argument. If a name is not given, the resulting name will be the name of the reduce function and the group properties. For example, if a name is not given to <code> COUNT_DISTINCT </code> by property <code> @foo </code> , the resulting name will be <code> count_distinct(@foo) </code> . </p> <p> See <a href="/docs/latest/develop/interact/search-and-query/advanced-concepts/aggregations#supported-groupby-reducers"> Supported GROUPBY reducers </a> for more details. </p> </details> <details open=""> <summary> <code> SORTBY {nargs} {property} {ASC|DESC} [MAX {num}] </code> </summary> <p> sorts the pipeline up until the point of <code> SORTBY </code> , using a list of properties. </p> <ul> <li> By default, sorting is ascending, but <code> ASC </code> or <code> DESC </code> can be added for each property. </li> <li> <code> nargs </code> is the number of sorting parameters, including <code> ASC </code> and <code> DESC </code> , for example, <code> SORTBY 4 @foo ASC @bar DESC </code> . </li> <li> <code> MAX </code> is used to optimized sorting, by sorting only for the n-largest elements. Although it is not connected to <code> LIMIT </code> , you usually need just <code> SORTBY … MAX </code> for common queries. </li> </ul> <p> Attributes needed for <code> SORTBY </code> should be stored as <code> SORTABLE </code> to be available with very low latency. </p> <p> <strong> Sorting Optimizations </strong> : performance is optimized for sorting operations on <code> DIALECT 4 </code> in different scenarios: </p> <ul> <li> Skip Sorter - applied when there is no sort of any kind. The query can return after it reaches the <code> LIMIT </code> requested results. </li> <li> Partial Range - applied when there is a <code> SORTBY </code> clause over a numeric field, with no filter or filter by the same numeric field, the query iterate on a range large enough to satisfy the <code> LIMIT </code> requested results. </li> <li> Hybrid - applied when there is a <code> SORTBY </code> clause over a numeric field and another non-numeric filter. Some results will get filtered, and the initial range may not be large enough. The iterator is then rewinding with the following ranges, and an additional iteration takes place to collect the <code> LIMIT </code> requested results. </li> <li> No optimization - If there is a sort by score or by non-numeric field, there is no other option but to retrieve all results and compare their values. </li> </ul> <p> <strong> Counts behavior </strong> : optional <code> WITHCOUNT </code> argument returns accurate counts for the query results with sorting. This operation processes all results in order to get an accurate count, being less performant than the optimized option (default behavior on <code> DIALECT 4 </code> ) </p> <details open=""> <summary> <code> APPLY {expr} AS {name} </code> </summary> <p> applies a 1-to-1 transformation on one or more properties and either stores the result as a new property down the pipeline or replaces any property using this transformation. </p> <p> <code> expr </code> is an expression that can be used to perform arithmetic operations on numeric properties, or functions that can be applied on properties depending on their types (see below), or any combination thereof. For example, <code> APPLY "sqrt(@foo)/log(@bar) + 5" AS baz </code> evaluates this expression dynamically for each record in the pipeline and store the result as a new property called <code> baz </code> , which can be referenced by further <code> APPLY </code> / <code> SORTBY </code> / <code> GROUPBY </code> / <code> REDUCE </code> operations down the pipeline. </p> <p> See <a href="/docs/latest/develop/interact/search-and-query/advanced-concepts/aggregations/#apply-expressions"> APPLY expressions </a> for details. </p> </details> <details open=""> <summary> <code> LIMIT {offset} {num} </code> </summary> <p> limits the number of results to return just <code> num </code> results starting at index <code> offset </code> (zero-based). It is much more efficient to use <code> SORTBY … MAX </code> if you are interested in just limiting the output of a sort operation. If a key expires during the query, an attempt to <code> load </code> the key's value will return a null array. </p> <p> However, limit can be used to limit results without sorting, or for paging the n-largest results as determined by <code> SORTBY MAX </code> . For example, getting results 50-100 of the top 100 results is most efficiently expressed as <code> SORTBY 1 @foo MAX 100 LIMIT 50 50 </code> . Removing the <code> MAX </code> from <code> SORTBY </code> results in the pipeline sorting <em> all </em> the records and then paging over results 50-100. </p> </details> <details open=""> <summary> <code> FILTER {expr} </code> </summary> <p> filters the results using predicate expressions relating to values in each result. They are applied post query and relate to the current state of the pipeline. </p> </details> <details open=""> <summary> <code> WITHCURSOR {COUNT} {read_size} [MAXIDLE {idle_time}] </code> </summary> <p> Scan part of the results with a quicker alternative than <code> LIMIT </code> . See <a href="/docs/latest/develop/interact/search-and-query/advanced-concepts/aggregations#cursor-api"> Cursor API </a> for more details. </p> </details> <details open=""> <summary> <code> TIMEOUT {milliseconds} </code> </summary> <p> if set, overrides the timeout parameter of the module. </p> </details> <details open=""> <summary> <code> PARAMS {nargs} {name} {value} </code> </summary> <p> defines one or more value parameters. Each parameter has a name and a value. </p> <p> You can reference parameters in the <code> query </code> by a <code> $ </code> , followed by the parameter name, for example, <code> $user </code> . Each such reference in the search query to a parameter name is substituted by the corresponding parameter value. For example, with parameter definition <code> PARAMS 4 lon 29.69465 lat 34.95126 </code> , the expression <code> @loc:[$lon $lat 10 km] </code> is evaluated to <code> @loc:[29.69465 34.95126 10 km] </code> . You cannot reference parameters in the query string where concrete values are not allowed, such as in field names, for example, <code> @loc </code> . To use <code> PARAMS </code> , set <code> DIALECT </code> to <code> 2 </code> or greater than <code> 2 </code> . </p> </details> <details open=""> <summary> <code> ADDSCORES </code> </summary> <p> The <code> ADDSCORES </code> option exposes the full-text score values to the aggregation pipeline. You can use <code> @__score </code> in a pipeline as shown in the following example: </p> <p> <code> FT.AGGREGATE idx 'hello' ADDSCORES SORTBY 2 @__score DESC </code> </p> </details> <details open=""> <summary> <code> DIALECT {dialect_version} </code> </summary> <p> selects the dialect version under which to execute the query. If not specified, the query will execute under the default dialect version set during module initial loading or via <a href="/docs/latest/commands/ft.config-set/"> <code> FT.CONFIG SET </code> </a> command. </p> </details> <h2 id="return"> Return </h2> <p> FT.AGGREGATE returns an array reply where each row is an array reply and represents a single aggregate result. The <a href="/docs/latest/develop/reference/protocol-spec#resp-integers"> integer reply </a> at position <code> 1 </code> does not represent a valid value. </p> <h3 id="return-multiple-values"> Return multiple values </h3> <p> See <a href="/docs/latest/commands/ft.search#return-multiple-values/"> Return multiple values </a> in <a href="/docs/latest/commands/ft.search/"> <code> FT.SEARCH </code> </a> The <code> DIALECT </code> can be specified as a parameter in the FT.AGGREGATE command. If it is not specified, the <code> DEFAULT_DIALECT </code> is used, which can be set using <a href="/docs/latest/commands/ft.config-set/"> <code> FT.CONFIG SET </code> </a> or by passing it as an argument to the <code> redisearch </code> module when it is loaded. For example, with the following document and index: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">127.0.0.1:6379&gt; JSON.SET doc:1 $ <span class="s1">'[{"arr": [1, 2, 3]}, {"val": "hello"}, {"val": "world"}]'</span> </span></span><span class="line"><span class="cl">OK </span></span><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.CREATE idx ON JSON PREFIX <span class="m">1</span> doc: SCHEMA $..arr AS arr NUMERIC $..val AS val TEXT </span></span><span class="line"><span class="cl">OK </span></span></code></pre> </div> <p> Notice the different replies, with and without <code> DIALECT 3 </code> : </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.AGGREGATE idx * LOAD <span class="m">2</span> arr val </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"arr"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"[1,2,3]"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"val"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"hello"</span> </span></span><span class="line"><span class="cl"> </span></span><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.AGGREGATE idx * LOAD <span class="m">2</span> arr val DIALECT <span class="m">3</span> </span></span><span class="line"><span class="cl">1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">2<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"arr"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"[[1,2,3]]"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"val"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"[\"hello\",\"world\"]"</span> </span></span></code></pre> </div> <h2 id="complexity"> Complexity </h2> <p> Non-deterministic. Depends on the query and aggregations performed, but it is usually linear to the number of results returned. </p> <h2 id="examples"> Examples </h2> <details open=""> <summary> <b> Sort page visits by day </b> </summary> <p> Find visits to the page <code> about.html </code> , group them by the day of the visit, count the number of visits, and sort them by day. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">FT.AGGREGATE idx <span class="s2">"@url:\"about.html\""</span> </span></span><span class="line"><span class="cl"> APPLY <span class="s2">"day(@timestamp)"</span> AS day </span></span><span class="line"><span class="cl"> GROUPBY <span class="m">2</span> @day @country </span></span><span class="line"><span class="cl"> REDUCE count <span class="m">0</span> AS num_visits </span></span><span class="line"><span class="cl"> SORTBY <span class="m">4</span> @day</span></span></code></pre> </div> </details> <details open=""> <summary> <b> Find most books ever published </b> </summary> <p> Find most books ever published in a single year. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">FT.AGGREGATE books-idx * </span></span><span class="line"><span class="cl"> GROUPBY <span class="m">1</span> @published_year </span></span><span class="line"><span class="cl"> REDUCE COUNT <span class="m">0</span> AS num_published </span></span><span class="line"><span class="cl"> GROUPBY <span class="m">0</span> </span></span><span class="line"><span class="cl"> REDUCE MAX <span class="m">1</span> @num_published AS max_books_published_per_year</span></span></code></pre> </div> </details> <details open=""> <summary> <b> Reduce all results </b> </summary> <p> The last example used <code> GROUPBY 0 </code> . Use <code> GROUPBY 0 </code> to apply a <code> REDUCE </code> function over all results from the last step of an aggregation pipeline -- this works on both the initial query and subsequent <code> GROUPBY </code> operations. </p> <p> Search for libraries within 10 kilometers of the longitude -73.982254 and latitude 40.753181 then annotate them with the distance between their location and those coordinates. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl"> FT.AGGREGATE libraries-idx <span class="s2">"@location:[-73.982254 40.753181 10 km]"</span> </span></span><span class="line"><span class="cl"> LOAD <span class="m">1</span> @location </span></span><span class="line"><span class="cl"> APPLY <span class="s2">"geodistance(@location, -73.982254, 40.753181)"</span></span></span></code></pre> </div> <p> Here, notice the required use of <code> LOAD </code> to pre-load the <code> @location </code> attribute because it is a GEO attribute. </p> <p> Next, count GitHub events by user (actor), to produce the most active users. </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">127.0.0.1:6379&gt; FT.AGGREGATE gh <span class="s2">"*"</span> GROUPBY <span class="m">1</span> @actor REDUCE COUNT <span class="m">0</span> AS num SORTBY <span class="m">2</span> @num DESC MAX <span class="m">10</span> </span></span><span class="line"><span class="cl"> 1<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">284784</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"lombiqbot"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"22197"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"codepipeline-test"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"17746"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"direwolf-github"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"10683"</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"ogate"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"6449"</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"openlocalizationtest"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"4759"</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"digimatic"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"3809"</span> </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"gugod"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"3512"</span> </span></span><span class="line"><span class="cl"> 9<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"xdzou"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"3216"</span> </span></span><span class="line"><span class="cl"><span class="o">[</span>10<span class="o">](</span>10<span class="o">))</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"opstest"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"2863"</span> </span></span><span class="line"><span class="cl">11<span class="o">)</span> 1<span class="o">)</span> <span class="s2">"actor"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"jikker"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> <span class="s2">"num"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"2794"</span> </span></span><span class="line"><span class="cl"><span class="o">(</span>0.59s<span class="o">)</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/ft.config-set/"> <code> FT.CONFIG SET </code> </a> | <a href="/docs/latest/commands/ft.search/"> <code> FT.SEARCH </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <ul> <li> <a href="/docs/latest/develop/interact/search-and-query/advanced-concepts/aggregations/"> Aggregations </a> </li> <li> <a href="/docs/latest/develop/interact/search-and-query/"> RediSearch </a> </li> </ul> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/ft.aggregate/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </details> </details> </details> </section>
https://redis.io/docs/latest/operate/rc/supported-regions/.html
<section class="prose w-full py-12 max-w-none"> <h1> Supported Cloud providers and regions </h1> <p> Your choice of cloud provider and region may affect latency between your application and your database, and may affect what connectivity options are available for your database. </p> <p> Redis Cloud supports databases on the following cloud providers: </p> <ul> <li> <a href="#amazon-web-services"> Amazon Web Services (AWS) </a> </li> <li> <a href="#google-cloud"> Google Cloud </a> </li> <li> <a href="#microsoft-azure"> Microsoft Azure </a> </li> </ul> <h2 id="amazon-web-services"> Amazon Web Services </h2> <p> Redis Cloud supports databases in the following Amazon Web Services (AWS) regions. </p> <p> Redis Cloud Pro databases on AWS support <a href="/docs/latest/operate/rc/security/vpc-peering/#aws-vpc-peering"> VPC Peering </a> and <a href="/docs/latest/operate/rc/security/aws-transit-gateway/"> Transit Gateway </a> . </p> <h4 id="americas"> Americas </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> ca-central-1 </code> </td> <td style="text-align:left"> Montreal, Canada </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> sa-east-1 </code> </td> <td style="text-align:left"> Sao Paulo, Brazil </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-east-1 </code> </td> <td style="text-align:left"> Northern Virginia, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-east-2 </code> </td> <td style="text-align:left"> Ohio, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west-1 </code> </td> <td style="text-align:left"> Northern California, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west-2 </code> </td> <td style="text-align:left"> Oregon, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> </tbody> </table> <h4 id="europe"> Europe </h4> <table> <thead> <tr> <th> Region ID </th> <th> Location </th> <th> Redis Cloud Pro </th> <th> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td> <code> eu-central-1 </code> </td> <td> Frankfurt, Germany </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> <code> eu-central-2 </code> </td> <td> Zurich, Switzerland </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td> <code> eu-north-1 </code> </td> <td> Stockholm, Sweden </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td> <code> eu-south-1 </code> </td> <td> Milan, Italy </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td> <code> eu-south-2 </code> </td> <td> Spain </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td> <code> eu-west-1 </code> </td> <td> Ireland </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> <code> eu-west-2 </code> </td> <td> London, UK </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td> <code> eu-west-3 </code> </td> <td> Paris, France </td> <td> <span title="Supported"> βœ… </span> </td> <td> <span title="Supported"> βœ… </span> </td> </tr> </tbody> </table> <h4 id="asia-pacific"> Asia Pacific </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> ap-east-1 </code> </td> <td style="text-align:left"> Hong Kong, China </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-northeast-1 </code> </td> <td style="text-align:left"> Tokyo, Japan </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-northeast-2 </code> </td> <td style="text-align:left"> Seoul, South Korea </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-south-1 </code> </td> <td style="text-align:left"> Mumbai, India </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-south-2 </code> </td> <td style="text-align:left"> Hyderabad, India </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-southeast-1 </code> </td> <td style="text-align:left"> Singapore </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-southeast-2 </code> </td> <td style="text-align:left"> Sydney, Australia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-southeast-3 </code> </td> <td style="text-align:left"> Jakarta, Indonesia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> ap-southeast-4 </code> </td> <td style="text-align:left"> Melbourne, Australia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h4 id="middle-east-and-africa"> Middle East and Africa </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> af-south-1 </code> </td> <td style="text-align:left"> Cape Town, South Africa </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> il-central-1 </code> </td> <td style="text-align:left"> Tel Aviv, Israel </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> me-central-1 </code> </td> <td style="text-align:left"> UAE </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> me-south-1 </code> </td> <td style="text-align:left"> Bahrain </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h2 id="google-cloud"> Google Cloud </h2> <p> Redis Cloud supports databases in the following Google Cloud regions. </p> <p> Redis Cloud Pro databases on Google Cloud support <a href="/docs/latest/operate/rc/security/vpc-peering/#gcp-vpc-peering"> VPC Peering </a> and <a href="/docs/latest/operate/rc/security/private-service-connect/"> Private Service Connect </a> . </p> <h4 id="americas-1"> Americas </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> northamerica-northeast1 </code> </td> <td style="text-align:left"> Montreal, Canada </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> northamerica-northeast2 </code> </td> <td style="text-align:left"> Toronto, Canada </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> southamerica-east1 </code> </td> <td style="text-align:left"> Sao Paulo, Brazil </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> southamerica-west1 </code> </td> <td style="text-align:left"> Santiago, Chile </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-central1 </code> </td> <td style="text-align:left"> Iowa, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-east1 </code> </td> <td style="text-align:left"> South Carolina, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-east4 </code> </td> <td style="text-align:left"> Virginia, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-east5 </code> </td> <td style="text-align:left"> Columbus, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-south1 </code> </td> <td style="text-align:left"> Dallas, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west1 </code> </td> <td style="text-align:left"> Oregon, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west2 </code> </td> <td style="text-align:left"> Los Angeles, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west3 </code> </td> <td style="text-align:left"> Salt Lake City, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> us-west4 </code> </td> <td style="text-align:left"> Las Vegas, USA </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h4 id="europe-1"> Europe </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> europe-central2 </code> </td> <td style="text-align:left"> Warsaw, Poland </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-north1 </code> </td> <td style="text-align:left"> Finland </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-southwest1 </code> </td> <td style="text-align:left"> Madrid, Spain </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west1 </code> </td> <td style="text-align:left"> Belgium </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west2 </code> </td> <td style="text-align:left"> London, UK </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west3 </code> </td> <td style="text-align:left"> Frankfurt, Germany </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west4 </code> </td> <td style="text-align:left"> Netherlands </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west6 </code> </td> <td style="text-align:left"> Zurich, Switzerland </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west8 </code> </td> <td style="text-align:left"> Milan, Italy </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west9 </code> </td> <td style="text-align:left"> Paris, France </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west10 </code> </td> <td style="text-align:left"> Berlin, Germany </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> europe-west12 </code> </td> <td style="text-align:left"> Turin, Italy </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h4 id="asia-pacific-1"> Asia Pacific </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> asia-east1 </code> </td> <td style="text-align:left"> Taiwan </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-east2 </code> </td> <td style="text-align:left"> Hong Kong, China </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-northeast1 </code> </td> <td style="text-align:left"> Tokyo, Japan </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-northeast2 </code> </td> <td style="text-align:left"> Osaka, Japan </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-northeast3 </code> </td> <td style="text-align:left"> Seoul, South Korea </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-south1 </code> </td> <td style="text-align:left"> Mumbai, India </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-south2 </code> </td> <td style="text-align:left"> Delhi, India </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-southeast1 </code> </td> <td style="text-align:left"> Singapore </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> asia-southeast2 </code> </td> <td style="text-align:left"> Jakarta, Indonesia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> australia-southeast1 </code> </td> <td style="text-align:left"> Sydney, Australia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> </tr> <tr> <td style="text-align:left"> <code> australia-southeast2 </code> </td> <td style="text-align:left"> Melbourne, Australia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h4 id="middle-east-and-africa-1"> Middle East and Africa </h4> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> <th style="text-align:left"> Redis Cloud Pro </th> <th style="text-align:left"> Redis Cloud Essentials </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> africa-south1 </code> </td> <td style="text-align:left"> Johannesburg, South Africa </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> me-central1 </code> </td> <td style="text-align:left"> Doha, Qatar </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> me-central2 </code> </td> <td style="text-align:left"> Dammam, Saudi Arabia </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> <tr> <td style="text-align:left"> <code> me-west1 </code> </td> <td style="text-align:left"> Tel Aviv, Israel </td> <td style="text-align:left"> <span title="Supported"> βœ… </span> </td> <td style="text-align:left"> <span title="Not supported"> ❌ </span> </td> </tr> </tbody> </table> <h2 id="microsoft-azure"> Microsoft Azure </h2> <p> Redis Cloud Essentials is available on the following Microsoft Azure regions: </p> <table> <thead> <tr> <th style="text-align:left"> Region ID </th> <th style="text-align:left"> Location </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> east-us </code> </td> <td style="text-align:left"> Virginia, USA </td> </tr> <tr> <td style="text-align:left"> <code> west-us </code> </td> <td style="text-align:left"> California, USA </td> </tr> </tbody> </table> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> Redis Cloud Pro is available on Azure through Azure Cache for Redis Enterprise. See <a href="https://azure.microsoft.com/en-us/pricing/details/cache/"> Azure Cache for Redis pricing </a> to view the list of Azure regions that support Azure Cache for Redis Enterprise. </div> </div> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/supported-regions/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/references/rest-api/requests/endpoints-stats/.html
<section class="prose w-full py-12 max-w-none"> <h1> Endpoints stats requests </h1> <p class="text-lg -mt-5 mb-10"> Endpoint statistics requests </p> <table> <thead> <tr> <th> Method </th> <th> Path </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="#get-endpoints-stats"> GET </a> </td> <td> <code> /v1/endpoints/stats </code> </td> <td> Get stats for all endpoints </td> </tr> </tbody> </table> <h2 id="get-endpoints-stats"> Get all endpoints stats </h2> <pre><code>GET /v1/endpoints/stats </code></pre> <p> Get statistics for all endpoint-proxy links. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> This method will return both endpoints and listeners stats for backwards compatability. </div> </div> <h4 id="required-permissions"> Required permissions </h4> <table> <thead> <tr> <th> Permission name </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/references/rest-api/permissions/#view_endpoint_stats"> view_endpoint_stats </a> </td> </tr> </tbody> </table> <h3 id="get-request"> Request </h3> <h4 id="example-http-request"> Example HTTP request </h4> <pre><code>GET /endpoints/stats?interval=1hour&amp;stime=2014-08-28T10:00:00Z </code></pre> <h4 id="request-headers"> Request headers </h4> <table> <thead> <tr> <th> Key </th> <th> Value </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> Host </td> <td> cnm.cluster.fqdn </td> <td> Domain name </td> </tr> <tr> <td> Accept </td> <td> application/json </td> <td> Accepted media type </td> </tr> </tbody> </table> <h4 id="query-parameters"> Query parameters </h4> <table> <thead> <tr> <th> Field </th> <th> Type </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> interval </td> <td> string </td> <td> Time interval for which we want stats: 1sec/10sec/5min/15min/1hour/12hour/1week (optional) </td> </tr> <tr> <td> stime </td> <td> ISO_8601 </td> <td> Start time from which we want the stats. Should comply with the <a href="https://en.wikipedia.org/wiki/ISO_8601"> ISO_8601 </a> format (optional) </td> </tr> <tr> <td> etime </td> <td> ISO_8601 </td> <td> End time after which we don't want the stats. Should comply with the <a href="https://en.wikipedia.org/wiki/ISO_8601"> ISO_8601 </a> format (optional) </td> </tr> </tbody> </table> <h3 id="get-response"> Response </h3> <p> The <code> uid </code> format in the response is: <code> "BDB_UID:ENDPOINT_UID:PROXY_UID" </code> </p> <p> For example: <code> {"uid": "1:2:3"} </code> means <code> BDB_UID=1 </code> , <code> ENDPOINT_UID=2 </code> , and <code> PROXY_UID=3 </code> </p> <h4 id="example-json-body"> Example JSON body </h4> <div class="highlight"> <pre class="chroma"><code class="language-json" data-lang="json"><span class="line"><span class="cl"><span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span> <span class="p">:</span> <span class="s2">"365:1:1"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"intervals"</span> <span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"interval"</span> <span class="p">:</span> <span class="s2">"10sec"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"egress_bytes"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_get"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"monitor_sessions_count"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_errors"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"stime"</span> <span class="p">:</span> <span class="s2">"2017-01-12T14:59:50Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_connections_received"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_set"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"max_connections_exceeded"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_write_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_flush"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_read_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"conns"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_touch"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_cmds"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"etime"</span> <span class="p">:</span> <span class="s2">"2017-01-12T15:00:00Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"ingress_bytes"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"last_res_time"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_other_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"last_req_time"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_started_res"</span> <span class="p">:</span> <span class="mi">0</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"> <span class="p">]</span> </span></span><span class="line"><span class="cl"> <span class="p">},</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"intervals"</span> <span class="p">:</span> <span class="p">[</span> </span></span><span class="line"><span class="cl"> <span class="p">{</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_read_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"etime"</span> <span class="p">:</span> <span class="s2">"2017-01-12T15:00:00Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_cmds"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_touch"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"conns"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"last_req_time"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_started_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"last_res_time"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"ingress_bytes"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_other_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"egress_bytes"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"interval"</span> <span class="p">:</span> <span class="s2">"10sec"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"auth_errors"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_get"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"monitor_sessions_count"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"read_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"max_connections_exceeded"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"total_connections_received"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_set"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"acc_write_latency"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_req"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"stime"</span> <span class="p">:</span> <span class="s2">"2017-01-12T14:59:50Z"</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"write_res"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"cmd_flush"</span> <span class="p">:</span> <span class="mi">0</span><span class="p">,</span> </span></span><span class="line"><span class="cl"> <span class="nt">"other_res"</span> <span class="p">:</span> <span class="mi">0</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"> <span class="p">],</span> </span></span><span class="line"><span class="cl"> <span class="nt">"uid"</span> <span class="p">:</span> <span class="s2">"333:1:2"</span> </span></span><span class="line"><span class="cl"> <span class="p">}</span> </span></span><span class="line"><span class="cl"><span class="p">]</span> </span></span></code></pre> </div> <h3 id="get-status-codes"> Status codes </h3> <table> <thead> <tr> <th> Code </th> <th> Description </th> </tr> </thead> <tbody> <tr> <td> <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.1"> 200 OK </a> </td> <td> No error </td> </tr> </tbody> </table> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/references/rest-api/requests/endpoints-stats/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/redis-data-integration/quick-start-guide/.html
<section class="prose w-full py-12"> <h1> Quickstart </h1> <p class="text-lg -mt-5 mb-10"> Get started with a simple pipeline example </p> <p> In this tutorial you will learn how to install RDI and set up a pipeline to ingest live data from a <a href="https://www.postgresql.org/"> PostgreSQL </a> database into a Redis database. </p> <h2 id="prerequisites"> Prerequisites </h2> <ul> <li> A Redis Enterprise database that will serve as the pipeline target. The dataset that will be ingested is quite small in size, so a single shard database should be enough. RDI also needs to maintain its own database on the cluster to store state information. <em> This requires Redis Enterprise v6.4 or greater </em> . </li> <li> <a href="/docs/latest/develop/tools/insight/"> Redis Insight </a> to edit your pipeline </li> <li> A virtual machine (VM) with one of the following operating systems: <ul> <li> Ubuntu 20.04 or 22.04 </li> <li> RHEL 8 or 9 </li> </ul> </li> </ul> <h2 id="overview"> Overview </h2> <p> The following diagram shows the structure of the pipeline we will create (see the <a href="/docs/latest/integrate/redis-data-integration/architecture/#overview"> architecture overview </a> to learn how the pipeline works): </p> <a href="/docs/latest/images/rdi/ingest/ingest-qsg.png" sdata-lightbox="/images/rdi/ingest/ingest-qsg.png"> <img src="/docs/latest/images/rdi/ingest/ingest-qsg.png"/> </a> <p> Here, the RDI <em> collector </em> tracks changes in PostgreSQL and writes them to streams in the RDI database in Redis. The <em> stream processor </em> then reads data records from the RDI database streams, processes them, and writes them to the target. </p> <h3 id="install-postgresql"> Install PostgreSQL </h3> <p> We provide a <a href="https://www.docker.com/"> Docker </a> image for an example PostgreSQL database that we will use for the tutorial. Follow the <a href="https://github.com/Redislabs-Solution-Architects/rdi-quickstart-postgres/tree/main"> instructions on our Github page </a> to download the image and start serving the database. The database, which is called <code> chinook </code> , has the <a href="https://www.kaggle.com/datasets/samaxtech/chinook-music-store-data?select=schema_diagram.png"> schema and data </a> for an imaginary online music store and is already set up for the RDI collector to use. </p> <h3 id="install-rdi"> Install RDI </h3> <p> Install RDI using the instructions in the <a href="/docs/latest/integrate/redis-data-integration/installation/install-vm/"> VM installation guide </a> . </p> <p> RDI will create the pipeline template for your chosen source database type at <code> /opt/rdi/config </code> . You will need this pathname later when you prepare the pipeline for deployment (see <a href="#prepare-the-pipeline"> Prepare the pipeline </a> below). </p> <p> At the end of the installation, RDI CLI will prompt you to set the access secrets for both the source PostgreSQL database and the Redis RDI database. RDI needs these to run the pipeline. If you provide admin credentials for your Redis Enterprise cluster here then RDI CLI will create the RDI database for you automatically. Otherwise, you should create this database yourself with the Redis Enterprise management console. A single-shard database with 125MB of RAM will work fine for this tutorial but you can also add a replica if you want (this will double the RAM requirements to 250MB). </p> <h3 id="prepare-the-pipeline"> Prepare the pipeline </h3> <p> During the installation, RDI placed the pipeline templates at <code> /opt/rdi/config </code> . If you go to that folder and run the <code> ll </code> command, you will see the pipeline configuration file, <code> config.yaml </code> , and the <code> jobs </code> folder (see the page about <a href="/docs/latest/integrate/redis-data-integration/data-pipelines/data-pipelines/"> Pipelines </a> for more information). Use Redis Insight to open the <code> config.yaml </code> file and then edit the following settings: </p> <ul> <li> Set the <code> host </code> to <code> localhost </code> and the <code> port </code> to 5432. </li> <li> Under <code> tables </code> , specify the <code> Track </code> table from the source database. </li> <li> Add the details of your target database to the <code> target </code> section. </li> </ul> <p> At this point, the pipeline is ready to deploy. </p> <h3 id="create-context"> Create a context (optional) </h3> <p> To manage and inspect RDI, you can use the <a href="/docs/latest/integrate/redis-data-integration/reference/cli/"> <code> redis-di </code> </a> CLI command, which has several subcommands for different purposes. Most of these commands require you to pass at least two options, <code> --rdi-host </code> and <code> --rdi-port </code> , to specify the host and port of your RDI installation. You can avoid typing these options repeatedly by saving the information in a <em> context </em> . </p> <p> When you activate a context, the saved values of <code> --rdi-host </code> , <code> --rdi-port </code> , and a few other options are passed automatically whenever you use <code> redis-di </code> . If you have more than one RDI installation, you can create a context for each of them and select the one you want to be active using its unique name. </p> <p> To create a context, use the <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-add-context/"> <code> redis-di add-context </code> </a> command: </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis-di add-context --rdi-host &lt;host&gt; --rdi-port &lt;port&gt; --cluster-host &lt;Redis DB host&gt; --cluster-api-port &lt;Redis DB API port&gt; --cluster-user &lt;Redis DB username&gt; &lt;unique-context-name&gt; </span></span></code></pre> </div> <p> These options are required but there are also a few others you can save, such as TLS credentials, if you are using them (see the <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-add-context/"> reference page </a> for details). When you have created a context, use <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-set-context/"> <code> redis-di set-context </code> </a> to activate it: </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis-di set-context &lt;context name&gt; </span></span></code></pre> </div> <p> There are also subcommands to <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-list-contexts/"> list </a> and <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-delete-context/"> delete </a> contexts. </p> <h3 id="deploy-the-pipeline"> Deploy the pipeline </h3> <p> You can use <a href="/docs/latest/develop/tools/insight/rdi-connector/"> Redis Insight </a> to deploy the pipeline by adding a connection to the RDI API endpoint (which has the same IP address as your RDI VM and uses port 8083) and then clicking the <strong> Deploy </strong> button. You can also deploy it with the following command: </p> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">redis-di deploy --dir &lt;path to pipeline folder&gt; </span></span></code></pre> </div> <p> where the path is the one you supplied earlier during the installation. (You may also need to supply <code> --rdi-host </code> and <code> --rdi-port </code> options if you are not using a <a href="#create-context"> context </a> as described above.) RDI first validates your pipeline and then deploys it if the configuration is correct. </p> <p> Once the pipeline is running, you can use Redis Insight to view the data flow using the pipeline metrics. You can also connect to your target database to see the keys that RDI has written there. </p> <p> See <a href="/docs/latest/integrate/redis-data-integration/data-pipelines/deploy/"> Deploy a pipeline </a> for more information about deployment settings. </p> <h3 id="view-rdis-response-to-data-changes"> View RDI's response to data changes </h3> <p> Once the pipeline has loaded a <em> snapshot </em> of all the existing data from the source, it enters <em> change data capture (CDC) </em> mode (see the <a href="/docs/latest/integrate/redis-data-integration/architecture/#overview"> architecture overview </a> and the <a href="/docs/latest/integrate/redis-data-integration/data-pipelines/data-pipelines/#ingest-pipeline-lifecycle"> ingest pipeline lifecycle </a> for more information ). </p> <p> To see the RDI pipeline working in CDC mode: </p> <ul> <li> Create a simulated load on the source database (see <a href="https://github.com/Redislabs-Solution-Architects/rdi-quickstart-postgres?tab=readme-ov-file#generating-load-on-the-database"> Generating load on the database </a> to learn how to do this). </li> <li> Run <a href="/docs/latest/integrate/redis-data-integration/reference/cli/redis-di-status/"> <code> redis-di status --live </code> </a> to see the flow of records. </li> <li> User <a href="/docs/latest/develop/tools/insight/"> Redis Insight </a> to look at the data in the target database. </li> </ul> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/redis-data-integration/quick-start-guide/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/integrate/write-behind/reference/cli/redis-di-scaffold/.html
<section class="prose w-full py-12 max-w-none"> <h1> redis-di scaffold </h1> <p class="text-lg -mt-5 mb-10"> Generates configuration files for Write-behind and Debezium (when ingesting data to Redis) </p> <h2 id="usage"> Usage </h2> <pre tabindex="0"><code>Usage: redis-di scaffold [OPTIONS] </code></pre> <h2 id="options"> Options </h2> <ul> <li> <p> <code> loglevel </code> : </p> <ul> <li> Type: Choice(['DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL']) </li> <li> Default: <code> info </code> </li> <li> Usage: <code> --loglevel -log-level </code> </li> </ul> </li> <li> <p> <code> db_type </code> (REQUIRED): </p> <ul> <li> Type: Choice([&lt;DbType.MYSQL: 'mysql'&gt;, &lt;DbType.ORACLE: 'oracle'&gt;, &lt;DbType.POSTGRESQL: 'postgresql'&gt;, &lt;DbType.REDIS: 'redis'&gt;, &lt;DbType.SQLSERVER: 'sqlserver'&gt;]) </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --db-type </code> </li> </ul> <p> DB type </p> </li> <li> <p> <code> strategy </code> : </p> <ul> <li> Type: Choice([&lt;Strategy.INGEST: 'ingest'&gt;, &lt;Strategy.WRITE_BEHIND: 'write_behind'&gt;]) </li> <li> Default: <code> ingest </code> </li> <li> Usage: <code> --strategy </code> </li> </ul> <p> Strategy </p> <p> Output to directory or stdout </p> </li> <li> <p> <code> directory </code> : </p> <ul> <li> Type: STRING </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --dir </code> </li> </ul> <p> Directory containing Write-behind configuration </p> </li> <li> <p> <code> preview </code> : </p> <ul> <li> Type: Choice(['debezium/application.properties', 'config.yaml']) </li> <li> Default: <code> none </code> </li> <li> Usage: <code> --preview </code> </li> </ul> <p> Print the content of specified config file to CLI output </p> </li> <li> <p> <code> help </code> : </p> <ul> <li> Type: BOOL </li> <li> Default: <code> false </code> </li> <li> Usage: <code> --help </code> </li> </ul> <p> Show this message and exit. </p> </li> </ul> <h2 id="cli-help"> CLI help </h2> <pre tabindex="0"><code>Usage: redis-di scaffold [OPTIONS] Generates configuration files for Write-behind and Debezium (when ingesting data to Redis) Options: -log-level, --loglevel [DEBUG|INFO|WARN|ERROR|CRITICAL] [default: INFO] --db-type [mysql|oracle|postgresql|redis|sqlserver] DB type [required] --strategy [ingest|write_behind] Strategy [default: ingest] Output formats: [mutually_exclusive, required] Output to directory or stdout --dir TEXT Directory containing Write-behind configuration --preview [debezium/application.properties|config.yaml] Print the content of specified config file to CLI output --help Show this message and exit. </code></pre> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/integrate/write-behind/reference/cli/redis-di-scaffold/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/7.4/references/memtier-benchmark/.html
<section class="prose w-full py-12 max-w-none"> <h1> Benchmark an Auto Tiering enabled database </h1> <p> Auto Tiering on Redis Enterprise Software lets you use cost-effective Flash memory as a RAM extension for your database. </p> <p> But what does the performance look like as compared to a memory-only database, one stored solely in RAM? </p> <p> These scenarios use the <code> memtier_benchmark </code> utility to evaluate the performance of a Redis Enterprise Software deployment, including the trial version. </p> <p> The <code> memtier_benchmark </code> utility is located in <code> /opt/redislabs/bin/ </code> of Redis Enterprise Software deployments. To test performance for cloud provider deployments, see the <a href="https://github.com/RedisLabs/memtier_benchmark"> memtier-benchmark GitHub project </a> . </p> <p> For additional, such as assistance with larger clusters, <a href="https://redislabs.com/company/support/"> contact support </a> . </p> <h2 id="benchmark-and-performance-test-considerations"> Benchmark and performance test considerations </h2> <p> These tests assume you're using a trial version of Redis Enterprise Software and want to test the performance of a Auto Tiering enabled database in the following scenarios: </p> <ul> <li> Without replication: Four (4) master shards </li> <li> With replication: Two (2) primary and two replica shards </li> </ul> <p> With the trial version of Redis Enterprise Software you can create a cluster of up to four shards using a combination of database configurations, including: </p> <ul> <li> Four databases, each with a single master shard </li> <li> Two highly available databases with replication enabled (each database has one master shard and one replica shard) </li> <li> One non-replicated clustered database with four master shards </li> <li> One highly available and clustered database with two master shards and two replica shards </li> </ul> <h2 id="test-environment-and-cluster-setup"> Test environment and cluster setup </h2> <p> For the test environment, you need to: </p> <ol> <li> Create a cluster with three nodes. </li> <li> Prepare the flash memory. </li> <li> Configure the load generation tool. </li> </ol> <h3 id="creating-a-threenode-rs-cluster"> Creating a three-node cluster </h3> <p> This performance test requires a three-node cluster. </p> <p> You can run all of these tests on Amazon AWS with these hosts: </p> <ul> <li> <p> 2 x i3.2xlarge (8 vCPU, 61 GiB RAM, up to 10GBit, 1.9TB NMVe SSD) </p> <p> These nodes serve RoF data </p> </li> <li> <p> 1 x m4.large, which acts as a quorum node </p> </li> </ul> <p> To learn how to install Redis Enterprise Software and set up a cluster, see: </p> <ul> <li> <a href="/docs/latest/operate/rs/7.4/installing-upgrading/quickstarts/redis-enterprise-software-quickstart/"> Redis Enterprise Software quickstart </a> for a test installation </li> <li> <a href="/docs/latest/operate/rs/7.4/installing-upgrading/"> Install and upgrade </a> for a production installation </li> </ul> <p> These tests use a quorum node to reduce AWS EC2 instance use while maintaining the three nodes required to support a quorum node in case of node failure. Quorum nodes can be on less powerful instances because they do not have shards or support traffic. </p> <p> As of this writing, i3.2xlarge instances are required because they support NVMe SSDs, which are required to support RoF. Auto Tiering requires Flash-enabled storage, such as NVMe SSDs. </p> <p> For best results, compare performance of a Flash-enabled deployment to the performance in a RAM-only environment, such as a strictly on-premises deployment. </p> <h2 id="prepare-the-flash-memory"> Prepare the flash memory </h2> <p> After you install RS on the nodes, the flash memory attached to the i3.2xlarge instances must be prepared and formatted with the <code> /opt/redislabs/sbin/prepare_flash.sh </code> script. </p> <h2 id="set-up-the-load-generation-tool"> Set up the load generation tool </h2> <p> The memtier_benchmark load generator tool generates the load on the RoF databases. To use this tool, install RS on a dedicated instance that is not part of the RS cluster but is in the same region/zone/subnet of your cluster. We recommend that you use a relatively powerful instance to avoid bottlenecks at the load generation tool itself. </p> <p> For these tests, the load generation host uses a c4.8xlarge instance type. </p> <h2 id="database-configuration-parameters"> Database configuration parameters </h2> <h3 id="create-a-auto-tiering-test-database"> Create a Auto Tiering test database </h3> <p> You can use the Redis Enterprise Cluster Manager UI to create a test database. We recommend that you use a separate database for each test case with these requirements: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> With replication </strong> </th> <th> <strong> Without replication </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Name </td> <td> test-1 </td> <td> test-2 </td> <td> The name of the test database </td> </tr> <tr> <td> Memory limit </td> <td> 100 GB </td> <td> 100 GB </td> <td> The memory limit refers to RAM+Flash, aggregated across all the shards of the database, including master and replica shards. </td> </tr> <tr> <td> RAM limit </td> <td> 0.3 </td> <td> 0.3 </td> <td> RoF always keeps the Redis keys and Redis dictionary in RAM and additional RAM is required for storing hot values. For the purpose of these tests 30% RAM was calculated as an optimal value. </td> </tr> <tr> <td> Replication </td> <td> Enabled </td> <td> Disabled </td> <td> A database with no replication has only master shards. A database with replication has master and replica shards. </td> </tr> <tr> <td> Data persistence </td> <td> None </td> <td> None </td> <td> No data persistence is needed for these tests. </td> </tr> <tr> <td> Database clustering </td> <td> Enabled </td> <td> Enabled </td> <td> A clustered database consists of multiple shards. </td> </tr> <tr> <td> Number of (master) shards </td> <td> 2 </td> <td> 4 </td> <td> Shards are distributed as follows: <br/> - With replication: One master shard and one replica shard on each node <br/> - Without replication: Two master shards on each node </td> </tr> <tr> <td> Other parameters </td> <td> Default </td> <td> Default </td> <td> Keep the default values for the other configuration parameters. </td> </tr> </tbody> </table> <h2 id="data-population"> Data population </h2> <h3 id="populate-the-benchmark-dataset"> Populate the benchmark dataset </h3> <p> The memtier_benchmark load generation tool populates the database. To populate the database with N itemsΒ of 500 Bytes each in size, on the load generation instance run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-maximum<span class="o">=</span><span class="nv">$N</span> -n allkeys -d <span class="m">500</span> --key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>1:0 </span></span></code></pre> </div> <p> Set up a test database: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Database host <br/> (-s) </td> <td> The fully qualified name of the endpoint or the IP shown in the RS database configuration </td> </tr> <tr> <td> Database port <br/> (-p) </td> <td> The endpoint port shown in your database configuration </td> </tr> <tr> <td> Number of items <br/> (–key-maximum) </td> <td> With replication: 75 Million <br/> Without replication: 150 Million </td> </tr> <tr> <td> Item size <br/> (-d) </td> <td> 500 Bytes </td> </tr> </tbody> </table> <h2 id="centralize-the-keyspace"> Centralize the keyspace </h2> <h3 id="centralize-with-repl"> With replication </h3> <p> To create roughly 20.5 million items in RAM for your highly available clustered database with 75 million items, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-minimum<span class="o">=</span><span class="m">27250000</span> --key-maximum<span class="o">=</span><span class="m">47750000</span> -n allkeys </span></span><span class="line"><span class="cl">--key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>0:1 </span></span></code></pre> </div> <p> To verify the database values, use <strong> Values in RAM </strong> metric, which is available from the <strong> Metrics </strong> tab of your database in the Cluster Manager UI. </p> <h3 id="centralize-wo-repl"> Without replication </h3> <p> To create 41 million items in RAM without replication enabled and 150 million items, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --hide-histogram </span></span><span class="line"><span class="cl">--key-minimum<span class="o">=</span><span class="m">54500000</span> --key-maximum<span class="o">=</span><span class="m">95500000</span> -n allkeys </span></span><span class="line"><span class="cl">--key-pattern<span class="o">=</span>P:P --ratio<span class="o">=</span>0:1 </span></span></code></pre> </div> <h2 id="test-runs"> Test runs </h2> <h3 id="generate-load"> Generate load </h3> <h4 id="generate-with-repl"> With replication </h4> <p> We recommend that you do a dry run and double check the RAM Hit Ratio on the <strong> Metrics </strong> screen in the Cluster Manager UI before you write down the test results. </p> <p> To test RoF with an 85% RAM Hit Ratio, run: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --pipeline<span class="o">=</span><span class="m">11</span> -c <span class="m">20</span> -t <span class="m">1</span> </span></span><span class="line"><span class="cl">-d <span class="m">500</span> --key-maximum<span class="o">=</span><span class="m">75000000</span> --key-pattern<span class="o">=</span>G:G --key-stddev<span class="o">=</span><span class="m">5125000</span> </span></span><span class="line"><span class="cl">--ratio<span class="o">=</span>1:1 --distinct-client-seed --randomize --test-time<span class="o">=</span><span class="m">600</span> </span></span><span class="line"><span class="cl">--run-count<span class="o">=</span><span class="m">1</span> --out-file<span class="o">=</span>test.out </span></span></code></pre> </div> <h4 id="generate-wo-repl"> Without replication </h4> <p> Here is the command for 150 million items: </p> <div class="highlight"> <pre class="chroma"><code class="language-sh" data-lang="sh"><span class="line"><span class="cl">$ memtier_benchmark -s <span class="nv">$DB_HOST</span> -p <span class="nv">$DB_PORT</span> --pipeline<span class="o">=</span><span class="m">24</span> -c <span class="m">20</span> -t <span class="m">1</span> </span></span><span class="line"><span class="cl">-d <span class="m">500</span> --key-maximum<span class="o">=</span><span class="m">150000000</span> --key-pattern<span class="o">=</span>G:G --key-stddev<span class="o">=</span><span class="m">10250000</span> </span></span><span class="line"><span class="cl">--ratio<span class="o">=</span>1:1 --distinct-client-seed --randomize --test-time<span class="o">=</span><span class="m">600</span> </span></span><span class="line"><span class="cl">--run-count<span class="o">=</span><span class="m">1</span> --out-file<span class="o">=</span>test.out </span></span></code></pre> </div> <p> Where: </p> <table> <thead> <tr> <th> <strong> Parameter </strong> </th> <th> <strong> Description </strong> </th> </tr> </thead> <tbody> <tr> <td> Access pattern (--key-pattern) and standard deviation (--key-stddev) </td> <td> Controls the RAM Hit ratio after the centralization process is complete </td> </tr> <tr> <td> Number of threads (-t and -c)\ </td> <td> Controls how many connections are opened to the database, whereby the number of connections is the number of threads multiplied by the number of connections per thread (-t) and number of clients per thread (-c) </td> </tr> <tr> <td> Pipelining (--pipeline)\ </td> <td> Pipelining allows you to send multiple requests without waiting for each individual response (-t) and number of clients per thread (-c) </td> </tr> <tr> <td> Read\write ratio (--ratio)\ </td> <td> A value of 1:1 means that you have the same number of write operations as read operations (-t) and number of clients per thread (-c) </td> </tr> </tbody> </table> <h2 id="test-results"> Test results </h2> <h3 id="monitor-the-test-results"> Monitor the test results </h3> <p> You can either monitor the results in the <strong> Metrics </strong> tab of the Cluster Manager UI or with the <code> memtier_benchmark </code> output. However, be aware that: </p> <ul> <li> <p> The memtier_benchmark results include the network latency between the load generator instance and the cluster instances. </p> </li> <li> <p> The metrics shown in the Cluster Manager UI do <em> not </em> include network latency. </p> </li> </ul> <h3 id="expected-results"> Expected results </h3> <p> You should expect to see an average throughput of: </p> <ul> <li> Around 160,000 ops/sec when testing without replication (i.e. Four master shards) </li> <li> Around 115,000 ops/sec when testing with enabled replication (i.e. 2 master and 2 replica shards) </li> </ul> <p> In both cases, the average latency should be below one millisecond. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/7.4/references/memtier-benchmark/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/geopos/.html
<section class="prose w-full py-12"> <h1 class="command-name"> GEOPOS </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">GEOPOS key [member [member ...]]</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available since: </dt> <dd class="m-0"> 3.2.0 </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) for each member requested. </dd> <dt class="font-semibold text-redis-ink-900 m-0"> ACL categories: </dt> <dd class="m-0"> <code> @read </code> <span class="mr-1 last:hidden"> , </span> <code> @geo </code> <span class="mr-1 last:hidden"> , </span> <code> @slow </code> <span class="mr-1 last:hidden"> , </span> </dd> </dl> <p> Return the positions (longitude,latitude) of all the specified members of the geospatial index represented by the sorted set at <em> key </em> . </p> <p> Given a sorted set representing a geospatial index, populated using the <a href="/docs/latest/commands/geoadd/"> <code> GEOADD </code> </a> command, it is often useful to obtain back the coordinates of specified members. When the geospatial index is populated via <a href="/docs/latest/commands/geoadd/"> <code> GEOADD </code> </a> the coordinates are converted into a 52 bit geohash, so the coordinates returned may not be exactly the ones used in order to add the elements, but small errors may be introduced. </p> <p> The command can accept a variable number of arguments so it always returns an array of positions even when a single element is specified. </p> <h2 id="examples"> Examples </h2> <div class="bg-slate-900 border-b border-slate-700 rounded-t-xl px-4 py-3 w-full flex"> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M2.5 10C2.5 5.85786 5.85786 2.5 10 2.5C14.1421 2.5 17.5 5.85786 17.5 10C17.5 14.1421 14.1421 17.5 10 17.5C5.85786 17.5 2.5 14.1421 2.5 10Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L18.6603 17.5L1.33975 17.5L10 2.5Z"> </path> </svg> <svg class="shrink-0 h-[1.0625rem] w-[1.0625rem] fill-slate-50" fill="currentColor" viewbox="0 0 20 20"> <path d="M10 2.5L12.0776 7.9322L17.886 8.22949L13.3617 11.8841L14.8738 17.5L10 14.3264L5.1262 17.5L6.63834 11.8841L2.11403 8.22949L7.92238 7.9322L10 2.5Z"> </path> </svg> </div> <form class="redis-cli overflow-y-auto max-h-80"> <pre tabindex="0">redis&gt; GEOADD Sicily 13.361389 38.115556 "Palermo" 15.087269 37.502669 "Catania" (integer) 2 redis&gt; GEOPOS Sicily Palermo Catania NonExisting 1) 1) "13.36138933897018433" 2) "38.11555639549629859" 2) 1) "15.08726745843887329" 2) "37.50266842333162032" 3) (nil) </pre> <div class="prompt" style=""> <span> redis&gt; </span> <input autocomplete="off" name="prompt" spellcheck="false" type="text"/> </div> </form> <h2 id="resp2-reply"> RESP2 Reply </h2> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : An array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as <a href="../../develop/reference/protocol-spec#bulk-strings"> Nil reply </a> elements of the array. <h2 id="resp3-reply"> RESP3 Reply </h2> <a href="../../develop/reference/protocol-spec#arrays"> Array reply </a> : An array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as <a href="../../develop/reference/protocol-spec#nulls"> Null reply </a> elements of the array. <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/geopos/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rc/accounts/user-profile/.html
<section class="prose w-full py-12 max-w-none"> <h1> Manage user account and profile </h1> <p class="text-lg -mt-5 mb-10"> Describes the how to manage your user account profile and how to switch between Redis Cloud accounts. </p> <p> When you sign in to the <a href="https://cloud.redis.io/"> Redis Cloud console </a> , you use a profile associated with one or more Redis Cloud accounts. </p> <p> This account has a profile with settings that you can manage using the Profile control located near the top, right corner of the Redis Cloud console: </p> <a href="/docs/latest/images/rc/account-selector-single-account.png" sdata-lightbox="/images/rc/account-selector-single-account.png"> <img alt="Use the Profile control to manage your user account profile and to switch between Redis Cloud accounts." src="/docs/latest/images/rc/account-selector-single-account.png" width="300px"/> </a> <p> When you open the Profile control, you can: </p> <ul> <li> <p> Review and manage your user account profile. </p> </li> <li> <p> Sign out from the Redis Cloud console. </p> </li> <li> <p> Switch between Redis Cloud subscriptions administered by your user account. </p> </li> </ul> <h2 id="manage-user-profile"> Manage user profile </h2> <p> To review your user profile settings, select <strong> User profile </strong> from the Profile control. This displays the <strong> User Profile </strong> screen: </p> <a href="/docs/latest/images/rc/user-profile-settings.png" sdata-lightbox="/images/rc/user-profile-settings.png"> <img alt="The User Profile screen lets you manage selected settings associated with your user account." src="/docs/latest/images/rc/user-profile-settings.png" width="75%"/> </a> <p> This screen contains up to three sections, including: </p> <ul> <li> <p> The <em> User details </em> section includes basic information about your account, including <em> First name </em> , <em> Last name </em> , <em> Job title </em> , <em> Email </em> , and the date the account was created. The names and job title can be edited; other settings are read-only. </p> </li> <li> <p> The <em> Password </em> section lets you change the password for accounts created and managed by Redis Cloud. </p> <p> If you're using single sign-on authentication, you cannot change the password using the <em> User Profile </em> screen. Such accounts are managed by an identity provider (IdP). For help changing (or recovering) the passwords for these accounts, consult your identity provider docs. </p> </li> <li> <p> The <strong> Multi-factor authentication (MFA) </strong> section lets you <a href="/docs/latest/operate/rc/security/access-control/multi-factor-authentication/"> manage MFA settings </a> for the current user account. </p> <p> When you activate a mobile device, you can use SMS MFA as a second authentication factor. </p> <p> To use an authentication app as the factor, you need to activate a mobile device and then use that device to enable the app. </p> </li> </ul> <h2 id="sign-out"> Sign out </h2> <p> To sign out from the Redis Cloud console, select <strong> Logout </strong> from the profile control. </p> <h2 id="switch-redis-cloud-accounts"> Switch Redis cloud accounts </h2> <p> When your user account is authorized to manage multiple Redis Cloud accounts, each account is displayed in the Profile control. </p> <a href="/docs/latest/images/rc/account-selector-switch-account.png" sdata-lightbox="/images/rc/account-selector-switch-account.png"> <img alt="To switch between Redis Cloud accounts, select the desired account from the list shown on the Profile control." src="/docs/latest/images/rc/account-selector-switch-account.png" width="300px"/> </a> <p> To switch accounts, select the desired account from the list shown in the Profile control. </p> <div class="alert p-3 relative flex flex-row items-center text-base bg-redis-pencil-200 rounded-md"> <div class="p-2 pr-5"> <svg fill="none" height="21" viewbox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"> <circle cx="10.5" cy="10.5" r="9.75" stroke="currentColor" stroke-width="1.5"> </circle> <path d="M10.5 14V16" stroke="currentColor" stroke-width="2"> </path> <path d="M10.5 5V12" stroke="currentColor" stroke-width="2"> </path> </svg> </div> <div class="p-1 pl-6 border-l border-l-redis-ink-900 border-opacity-50"> <div class="font-medium"> Note: </div> To create another Redis Cloud account associated with the same email address, you need to <a href="/docs/latest/operate/rc/rc-quickstart/"> sign up for Redis Cloud </a> again with a plus address of the email address. For many email providers, you can do this by adding <code> + </code> and any string to the end of your username. For example, if your address is <code> example@example.com </code> , enter <code> example+account2@example.com </code> . </div> </div> <h2 id="save-or-discard-changes"> Save or discard changes </h2> <p> Use the <strong> Discard changes </strong> button to cancel user profile setting changes or the <strong> Save changes </strong> button to save changes. </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rc/accounts/user-profile/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/commands/ft.info.html
<section class="prose w-full py-12"> <h1 class="command-name"> FT.INFO </h1> <div class="font-semibold text-redis-ink-900"> Syntax </div> <pre class="command-syntax">FT.INFO index</pre> <dl class="grid grid-cols-[auto,1fr] gap-2 mb-12"> <dt class="font-semibold text-redis-ink-900 m-0"> Available in: </dt> <dd class="m-0"> <a href="/docs/stack"> Redis Stack </a> / <a href="/docs/interact/search-and-query"> Search 1.0.0 </a> </dd> <dt class="font-semibold text-redis-ink-900 m-0"> Time complexity: </dt> <dd class="m-0"> O(1) </dd> </dl> <p> Returns information and statistics about a given index. </p> <h2 id="required-arguments"> Required arguments </h2> <p> <code> index </code> <br/> is the name of the given index. You must first create the index using <a href="/docs/latest/commands/ft.create/"> <code> FT.CREATE </code> </a> . </p> <h2 id="resp-reply"> RESP reply </h2> <p> <code> FT.INFO </code> returns an array reply with pairs of keys and values. </p> <h2 id="returned-values"> Returned values </h2> <h3 id="general"> General </h3> <table> <thead> <tr> <th style="text-align:left"> Return field name </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> index_name </code> </td> <td style="text-align:left"> The index name that was defined when index was created. </td> </tr> <tr> <td style="text-align:left"> <code> index_options </code> </td> <td style="text-align:left"> The index options selected during <code> FT.CREATE </code> such as <code> FILTER {filter} </code> , <code> LANGUAGE {default_lang} </code> , etc. </td> </tr> <tr> <td style="text-align:left"> <code> index_definition </code> </td> <td style="text-align:left"> Includes <code> key_type </code> , hash or JSON; <code> prefixes </code> , if any; and <code> default_score </code> . </td> </tr> <tr> <td style="text-align:left"> <code> attributes </code> </td> <td style="text-align:left"> The index schema field names, types, and attributes. </td> </tr> <tr> <td style="text-align:left"> <code> num_docs </code> </td> <td style="text-align:left"> The number of documents. </td> </tr> <tr> <td style="text-align:left"> <code> max_doc_id </code> </td> <td style="text-align:left"> The maximum document ID. </td> </tr> <tr> <td style="text-align:left"> <code> num_terms </code> </td> <td style="text-align:left"> The number of distinct terms. </td> </tr> <tr> <td style="text-align:left"> <code> num_records </code> </td> <td style="text-align:left"> The total number of records. </td> </tr> </tbody> </table> <h3 id="various-size-statistics"> Various size statistics </h3> <table> <thead> <tr> <th style="text-align:left"> Statistic </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> inverted_sz_mb </code> </td> <td style="text-align:left"> The memory used by the inverted index, which is the core data structure used for searching in RediSearch. The size is given in megabytes. </td> </tr> <tr> <td style="text-align:left"> <code> vector_index_sz_mb </code> </td> <td style="text-align:left"> The memory used by the vector index, which stores any vectors associated with each document. </td> </tr> <tr> <td style="text-align:left"> <code> total_inverted_index_blocks </code> </td> <td style="text-align:left"> The total number of blocks in the inverted index. </td> </tr> <tr> <td style="text-align:left"> <code> offset_vectors_sz_mb </code> </td> <td style="text-align:left"> The memory used by the offset vectors, which store positional information for terms in documents. </td> </tr> <tr> <td style="text-align:left"> <code> doc_table_size_mb </code> </td> <td style="text-align:left"> The memory used by the document table, which contains metadata about each document in the index. </td> </tr> <tr> <td style="text-align:left"> <code> sortable_values_size_mb </code> </td> <td style="text-align:left"> The memory used by sortable values, which are values associated with documents and used for sorting purposes. </td> </tr> <tr> <td style="text-align:left"> <code> key_table_size_mb </code> </td> <td style="text-align:left"> The memory used by the key table, which stores the mapping between document IDs and Redis keys. </td> </tr> <tr> <td style="text-align:left"> <code> geoshapes_sz_mb </code> </td> <td style="text-align:left"> The memory used by GEO-related fields. </td> </tr> <tr> <td style="text-align:left"> <code> records_per_doc_avg </code> </td> <td style="text-align:left"> The average number of records (including deletions) per document. </td> </tr> <tr> <td style="text-align:left"> <code> bytes_per_record_avg </code> </td> <td style="text-align:left"> The average size of each record in bytes. </td> </tr> <tr> <td style="text-align:left"> <code> offsets_per_term_avg </code> </td> <td style="text-align:left"> The average number of offsets (position information) per term. </td> </tr> <tr> <td style="text-align:left"> <code> offset_bits_per_record_avg </code> </td> <td style="text-align:left"> The average number of bits used for offsets per record. </td> </tr> </tbody> </table> <h3 id="indexing-related-statistics"> Indexing-related statistics </h3> <table> <thead> <tr> <th style="text-align:left"> Statistic </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> hash_indexing_failures </code> </td> <td style="text-align:left"> The number of failures encountered during indexing. </td> </tr> <tr> <td style="text-align:left"> <code> total_indexing_time </code> </td> <td style="text-align:left"> The total time taken for indexing in seconds. </td> </tr> <tr> <td style="text-align:left"> <code> indexing </code> </td> <td style="text-align:left"> Indicates whether the index is currently being generated. </td> </tr> <tr> <td style="text-align:left"> <code> percent_indexed </code> </td> <td style="text-align:left"> The percentage of the index that has been successfully generated (1 means 100%). </td> </tr> <tr> <td style="text-align:left"> <code> number_of_uses </code> </td> <td style="text-align:left"> The number of times the index has been used. </td> </tr> <tr> <td style="text-align:left"> <code> cleaning </code> </td> <td style="text-align:left"> The index deletion flag. A value of <code> 1 </code> indicates index deletion is in progress. </td> </tr> </tbody> </table> <h3 id="garbage-collection-statistics"> Garbage collection statistics </h3> <table> <thead> <tr> <th style="text-align:left"> Statistic </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> bytes_collected </code> </td> <td style="text-align:left"> The number of bytes collected during garbage collection. </td> </tr> <tr> <td style="text-align:left"> <code> total_ms_run </code> </td> <td style="text-align:left"> The total time in milliseconds spent on garbage collection. </td> </tr> <tr> <td style="text-align:left"> <code> total_cycles </code> </td> <td style="text-align:left"> The total number of garbage collection cycles. </td> </tr> <tr> <td style="text-align:left"> <code> average_cycle_time_ms </code> </td> <td style="text-align:left"> The average time in milliseconds for each garbage collection cycle. The value <code> nan </code> indicates that the average cycle time is not available. </td> </tr> <tr> <td style="text-align:left"> <code> last_run_time_ms </code> </td> <td style="text-align:left"> The time in milliseconds taken by the last garbage collection run. </td> </tr> </tbody> </table> <p> The next two GC-related fields are relevant in scenarios where simultaneous changes occurred in the same memory area for both the parent process and the child process, resulting in the parent discarding these changes. </p> <table> <thead> <tr> <th style="text-align:left"> Statistic </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> gc_numeric_trees_missed </code> </td> <td style="text-align:left"> The number of numeric tree nodes whose changes were discarded due to splitting by the parent process during garbage collection. </td> </tr> <tr> <td style="text-align:left"> <code> gc_blocks_denied </code> </td> <td style="text-align:left"> The number of blocks whose changes were discarded (skipped) because they were modified by the parent process during the garbage collection. Notably, as inverted index blocks are append-only, only the last block of an inverted index can be skipped. </td> </tr> </tbody> </table> <h3 id="cursor-statistics"> Cursor statistics </h3> <table> <thead> <tr> <th style="text-align:left"> Statistic </th> <th style="text-align:left"> Definition </th> </tr> </thead> <tbody> <tr> <td style="text-align:left"> <code> global_idle </code> </td> <td style="text-align:left"> The number of idle cursors in the system. </td> </tr> <tr> <td style="text-align:left"> <code> global_total </code> </td> <td style="text-align:left"> The total number of cursors in the system. </td> </tr> <tr> <td style="text-align:left"> <code> index_capacity </code> </td> <td style="text-align:left"> The maximum number of cursors allowed per index. </td> </tr> <tr> <td style="text-align:left"> <code> index_total </code> </td> <td style="text-align:left"> The total number of cursors open on the index. </td> </tr> </tbody> </table> <h3 id="other-statistics"> Other statistics </h3> <ul> <li> Dialect statistics: the number of times the index was searched using each DIALECT, 1 - 4. </li> <li> Index error statistics, including <code> indexing failures </code> , <code> last indexing error </code> , and <code> last indexing error key </code> . </li> <li> Field statistics, including <code> indexing failures </code> , <code> last indexing error </code> , and <code> last indexing error key </code> for each schema field. </li> </ul> <h2 id="example"> Example </h2> <details open=""> <summary> <b> Return statistics about an index </b> </summary> <div class="highlight"> <pre class="chroma"><code class="language-bash" data-lang="bash"><span class="line"><span class="cl">127.0.0.1:6379&gt; ft.info idx:bicycle </span></span><span class="line"><span class="cl"> 1<span class="o">)</span> index_name </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> idx:bicycle </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> index_options </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="o">(</span>empty array<span class="o">)</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> index_definition </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> key_type </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> JSON </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> prefixes </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> 1<span class="o">)</span> bicycle: </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> default_score </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> attributes </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> 1<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.pickup_zone </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> pickup_zone </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> GEOSHAPE </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> coord_system </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> SPHERICAL </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.store_location </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> store_location </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> GEO </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.brand </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> brand </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> TEXT </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> WEIGHT </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.model </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> model </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> TEXT </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> WEIGHT </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.description </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> description </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> TEXT </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> WEIGHT </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.price </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> price </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> NUMERIC </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.condition </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> condition </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> <span class="nb">type</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> TAG </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> SEPARATOR </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> , </span></span><span class="line"><span class="cl"> 9<span class="o">)</span> num_docs </span></span><span class="line"><span class="cl">10<span class="o">)</span> <span class="s2">"10"</span> </span></span><span class="line"><span class="cl">11<span class="o">)</span> max_doc_id </span></span><span class="line"><span class="cl">12<span class="o">)</span> <span class="s2">"10"</span> </span></span><span class="line"><span class="cl">13<span class="o">)</span> num_terms </span></span><span class="line"><span class="cl">14<span class="o">)</span> <span class="s2">"546"</span> </span></span><span class="line"><span class="cl">15<span class="o">)</span> num_records </span></span><span class="line"><span class="cl">16<span class="o">)</span> <span class="s2">"692"</span> </span></span><span class="line"><span class="cl">17<span class="o">)</span> inverted_sz_mb </span></span><span class="line"><span class="cl">18<span class="o">)</span> <span class="s2">"0.003993034362792969"</span> </span></span><span class="line"><span class="cl">19<span class="o">)</span> vector_index_sz_mb </span></span><span class="line"><span class="cl">20<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl">21<span class="o">)</span> total_inverted_index_blocks </span></span><span class="line"><span class="cl">22<span class="o">)</span> <span class="s2">"551"</span> </span></span><span class="line"><span class="cl">23<span class="o">)</span> offset_vectors_sz_mb </span></span><span class="line"><span class="cl">24<span class="o">)</span> <span class="s2">"7.047653198242188e-4"</span> </span></span><span class="line"><span class="cl">25<span class="o">)</span> doc_table_size_mb </span></span><span class="line"><span class="cl">26<span class="o">)</span> <span class="s2">"7.152557373046875e-4"</span> </span></span><span class="line"><span class="cl">27<span class="o">)</span> sortable_values_size_mb </span></span><span class="line"><span class="cl">28<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl">29<span class="o">)</span> key_table_size_mb </span></span><span class="line"><span class="cl">30<span class="o">)</span> <span class="s2">"3.0422210693359375e-4"</span> </span></span><span class="line"><span class="cl">31<span class="o">)</span> geoshapes_sz_mb </span></span><span class="line"><span class="cl">32<span class="o">)</span> <span class="s2">"0.00426483154296875"</span> </span></span><span class="line"><span class="cl">33<span class="o">)</span> records_per_doc_avg </span></span><span class="line"><span class="cl">34<span class="o">)</span> <span class="s2">"69.19999694824219"</span> </span></span><span class="line"><span class="cl">35<span class="o">)</span> bytes_per_record_avg </span></span><span class="line"><span class="cl">36<span class="o">)</span> <span class="s2">"6.0505781173706055"</span> </span></span><span class="line"><span class="cl">37<span class="o">)</span> offsets_per_term_avg </span></span><span class="line"><span class="cl">38<span class="o">)</span> <span class="s2">"1.0679190158843994"</span> </span></span><span class="line"><span class="cl">39<span class="o">)</span> offset_bits_per_record_avg </span></span><span class="line"><span class="cl">40<span class="o">)</span> <span class="s2">"8"</span> </span></span><span class="line"><span class="cl">41<span class="o">)</span> hash_indexing_failures </span></span><span class="line"><span class="cl">42<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl">43<span class="o">)</span> total_indexing_time </span></span><span class="line"><span class="cl">44<span class="o">)</span> <span class="s2">"4.539999961853027"</span> </span></span><span class="line"><span class="cl">45<span class="o">)</span> indexing </span></span><span class="line"><span class="cl">46<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl">47<span class="o">)</span> percent_indexed </span></span><span class="line"><span class="cl">48<span class="o">)</span> <span class="s2">"1"</span> </span></span><span class="line"><span class="cl">49<span class="o">)</span> number_of_uses </span></span><span class="line"><span class="cl">50<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">1</span> </span></span><span class="line"><span class="cl">51<span class="o">)</span> cleaning </span></span><span class="line"><span class="cl">52<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl">53<span class="o">)</span> gc_stats </span></span><span class="line"><span class="cl">54<span class="o">)</span> 1<span class="o">)</span> bytes_collected </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> total_ms_run </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> total_cycles </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> average_cycle_time_ms </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="s2">"nan"</span> </span></span><span class="line"><span class="cl"> 9<span class="o">)</span> last_run_time_ms </span></span><span class="line"><span class="cl"> 10<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl"> 11<span class="o">)</span> gc_numeric_trees_missed </span></span><span class="line"><span class="cl"> 12<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl"> 13<span class="o">)</span> gc_blocks_denied </span></span><span class="line"><span class="cl"> 14<span class="o">)</span> <span class="s2">"0"</span> </span></span><span class="line"><span class="cl">55<span class="o">)</span> cursor_stats </span></span><span class="line"><span class="cl">56<span class="o">)</span> 1<span class="o">)</span> global_idle </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> global_total </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> index_capacity </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">128</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> index_total </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl">57<span class="o">)</span> dialect_stats </span></span><span class="line"><span class="cl">58<span class="o">)</span> 1<span class="o">)</span> dialect_1 </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> dialect_2 </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> dialect_3 </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> dialect_4 </span></span><span class="line"><span class="cl"> 8<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl">59<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl">60<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl">61<span class="o">)</span> field statistics </span></span><span class="line"><span class="cl">62<span class="o">)</span> 1<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.pickup_zone </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> pickup_zone </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.store_location </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> store_location </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.brand </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> brand </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.model </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> model </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.description </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> description </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.price </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> price </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span> </span></span><span class="line"><span class="cl"> 7<span class="o">)</span> 1<span class="o">)</span> identifier </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> $.condition </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> attribute </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> condition </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> Index Errors </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> 1<span class="o">)</span> indexing failures </span></span><span class="line"><span class="cl"> 2<span class="o">)</span> <span class="o">(</span>integer<span class="o">)</span> <span class="m">0</span> </span></span><span class="line"><span class="cl"> 3<span class="o">)</span> last indexing error </span></span><span class="line"><span class="cl"> 4<span class="o">)</span> N/A </span></span><span class="line"><span class="cl"> 5<span class="o">)</span> last indexing error key </span></span><span class="line"><span class="cl"> 6<span class="o">)</span> <span class="s2">"N/A"</span></span></span></code></pre> </div> </details> <h2 id="see-also"> See also </h2> <p> <a href="/docs/latest/commands/ft.create/"> <code> FT.CREATE </code> </a> | <a href="/docs/latest/commands/ft.search/"> <code> FT.SEARCH </code> </a> </p> <h2 id="related-topics"> Related topics </h2> <p> <a href="/docs/latest/develop/interact/search-and-query/"> RediSearch </a> </p> <br/> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/commands/ft.info/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>
https://redis.io/docs/latest/operate/rs/security/.html
<section class="prose w-full py-12 max-w-none"> <h1> Security </h1> <p> Redis Enterprise Software provides various features to secure your Redis Enterprise Software deployment: </p> <table> <thead> <tr> <th> Login and passwords </th> <th> Users and roles </th> <th> Encryption and TLS </th> <th> Certificates and audit </th> </tr> </thead> <tbody> <tr> <td> <a href="/docs/latest/operate/rs/security/access-control/manage-users/login-lockout/"> Password attempts and session timeout </a> </td> <td> <a href="/docs/latest/operate/rs/security/access-control/"> Cluster and database access explained </a> </td> <td> <a href="/docs/latest/operate/rs/security/encryption/tls/enable-tls/"> Enable TLS </a> </td> <td> <a href="/docs/latest/operate/rs/security/certificates/create-certificates/"> Create certificates </a> </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/security/access-control/manage-passwords/password-complexity-rules/"> Password complexity </a> </td> <td> <a href="/docs/latest/operate/rs/security/access-control/create-users/"> Create users </a> </td> <td> <a href="/docs/latest/operate/rs/security/encryption/tls/tls-protocols/"> Configure TLS protocols </a> </td> <td> <a href="/docs/latest/operate/rs/security/certificates/monitor-certificates/"> Monitor certificates </a> </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/security/access-control/manage-passwords/password-expiration/"> Password expiration </a> </td> <td> <a href="/docs/latest/operate/rs/security/access-control/create-combined-roles/"> Create roles </a> </td> <td> <a href="/docs/latest/operate/rs/security/encryption/tls/ciphers/"> Configure cipher suites </a> </td> <td> <a href="/docs/latest/operate/rs/security/certificates/updating-certificates/"> Update certificates </a> </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/security/access-control/manage-users/default-user/"> Default database access </a> </td> <td> <a href="/docs/latest/operate/rs/security/access-control/redis-acl-overview/"> Redis ACLs </a> </td> <td> <a href="/docs/latest/operate/rs/security/encryption/pem-encryption/"> Encrypt private keys on disk </a> </td> <td> <a href="/docs/latest/operate/rs/security/certificates/ocsp-stapling/"> Enable OCSP stapling </a> </td> </tr> <tr> <td> <a href="/docs/latest/operate/rs/security/access-control/manage-passwords/rotate-passwords/"> Rotate user passwords </a> </td> <td> <a href="/docs/latest/operate/rs/security/access-control/ldap/"> Integrate with LDAP </a> </td> <td> <a href="/docs/latest/operate/rs/security/encryption/internode-encryption/"> Internode encryption </a> </td> <td> <a href="/docs/latest/operate/rs/security/audit-events/"> Audit database connections </a> </td> </tr> </tbody> </table> <h2 id="recommended-security-practices"> Recommended security practices </h2> <p> See <a href="/docs/latest/operate/rs/security/recommended-security-practices/"> Recommended security practices </a> to learn how to protect Redis Enterprise Software. </p> <h2 id="redis-trust-center"> Redis Trust Center </h2> <p> Visit our <a href="https://trust.redis.io/"> Trust Center </a> to learn more about Redis security policies. If you find a suspected security bug, you can <a href="https://hackerone.com/redis-vdp?type=team"> submit a report </a> . </p> <form class="text-sm w-full mt-24 pt-5 border-t border-t-redis-pen-700 border-opacity-50" id="page-feedback" name="page-feedback"> <input class="hidden" name="origin" value="https://redis.io/docs/latest/operate/rs/security/"/> <div class="flex flex-row justify-between"> <div class="grid justify-center"> <span class="font-mono"> RATE THIS PAGE </span> <div class="star-rating"> <input id="5-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="5"/> <label class="star" for="5-stars"> β˜… </label> <input id="4-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="4"/> <label class="star" for="4-stars"> β˜… </label> <input id="3-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="3"/> <label class="star" for="3-stars"> β˜… </label> <input id="2-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="2"/> <label class="star" for="2-stars"> β˜… </label> <input id="1-stars" name="rating" onchange="document.querySelector('#feedback-form').classList.remove('hidden')" type="radio" value="1"/> <label class="star" for="1-stars"> β˜… </label> </div> </div> <a class="font-mono no-underline" href="#"> Back to top ↑ </a> </div> <div class="hidden" id="feedback-form"> <div class="grid gap-2"> <textarea class="p-2 mt-1 block w-full h-24 border border-opacity-50 border-redis-ink-900 rounded-md" name="comment" placeholder="Why did you choose this rating?" rows="3"></textarea> <button class="font-mono button text-redis-ink-900 border border-solid border-transparent bg-redis-red-500 hover:bg-redis-red-600 focus:bg-red-600 focus:ring-red-600; w-min justify-self-end" type="submit"> Submit </button> </div> </div> </form> <script> document.addEventListener("DOMContentLoaded", function() { const form = document.querySelector("#page-feedback"); form.addEventListener("submit", function(event) { event.preventDefault(); var xhr = new XMLHttpRequest(); var url = "\/docusight\/api\/rate"; var params = new URLSearchParams(new FormData(form)); xhr.open("POST", url, true); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.onreadystatechange = function() { if (xhr.readyState === 4 && xhr.status === 200) { const responseData = JSON.parse(xhr.responseText); const responseMessage = responseData.response; const newText = document.createTextNode(responseMessage); form.parentNode.replaceChild(newText, form); } }; xhr.send(params); }); }); </script> </section>