<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Reference on Mimus</title><link>https://mimus.pgsty.com/docs/redis/reference/</link><description>Recent content in Reference on Mimus</description><generator>Hugo</generator><language>en-US</language><lastBuildDate>Sun, 06 Dec 2026 15:37:05 +0800</lastBuildDate><atom:link href="https://mimus.pgsty.com/docs/redis/reference/index.xml" rel="self" type="application/rss+xml"/><item><title>Limits</title><link>https://mimus.pgsty.com/docs/redis/reference/limits/</link><guid>https://mimus.pgsty.com/docs/redis/reference/limits/</guid><description>&lt;p&gt;Gateway limits bound request frames, reply frames, and PostgreSQL wire buffers in the &lt;code&gt;pgredis&lt;/code&gt; Go process. Extension limits bound temporary workspace allocations, shared-memory rings, and session tables inside PostgreSQL 18. Neither replaces OS or PostgreSQL cluster-wide memory limits (&lt;code&gt;shared_buffers&lt;/code&gt;, &lt;code&gt;work_mem&lt;/code&gt;, container cgroup limits).&lt;/p&gt;&#10;&lt;h2 id="gateway"&gt;Gateway buffer limits&#10;&lt;/h2&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Resource&lt;/th&gt;&#10; &lt;th scope="col"&gt;Flag&lt;/th&gt;&#10; &lt;th scope="col" style="text-align: right"&gt;Default limit&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Single bulk argument&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-bulk-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;512 MiB&lt;/code&gt; (&lt;code&gt;536,870,912&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Total argument bytes in one request frame&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-frame-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;1 GiB + 1 MiB&lt;/code&gt; (&lt;code&gt;1,074,790,400&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Unauthenticated request header (&lt;code&gt;AUTH&lt;/code&gt; pending)&lt;/td&gt;&#10; &lt;td&gt;Built-in&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;10&lt;/code&gt; arguments, &lt;code&gt;16,384&lt;/code&gt; bytes per bulk argument&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Complete wire reply (including &lt;code&gt;EXEC&lt;/code&gt; array)&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-reply-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;1 GiB + 1 MiB&lt;/code&gt; (&lt;code&gt;1,074,790,400&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Shared live input payload and bookkeeping&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-input-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;2 GiB&lt;/code&gt; (&lt;code&gt;2,147,483,648&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Shared live output payload and workspace&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-output-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;2 GiB&lt;/code&gt; (&lt;code&gt;2,147,483,648&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Shared PostgreSQL receive buffer budget&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-pg-read-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;2 GiB&lt;/code&gt; (&lt;code&gt;2,147,483,648&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Single PostgreSQL wire message body&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;-max-pg-message-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;1 GiB - 2 B&lt;/code&gt; (&lt;code&gt;1,073,741,822&lt;/code&gt; bytes)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;Local &lt;code&gt;pgx&lt;/code&gt; read-budget patch:&lt;/strong&gt; During &lt;code&gt;make build&lt;/code&gt;, &lt;code&gt;scripts/prepare_pgx.py&lt;/code&gt; applies &lt;code&gt;patches/pgx-v5.11.0-read-budget.patch&lt;/code&gt; to the Go driver so oversized PostgreSQL wire messages and shared &lt;code&gt;-max-pg-read-bytes&lt;/code&gt; budgets are enforced before allocating full message bodies in memory.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Post-commit output rejection:&lt;/strong&gt; A mutating SQL statement can commit inside PostgreSQL before the gateway rejects an oversized reply against &lt;code&gt;-max-reply-bytes&lt;/code&gt; or &lt;code&gt;-max-output-bytes&lt;/code&gt;. Callers that lose a connection or receive an output-budget error must treat the write outcome as &lt;a href="https://mimus.pgsty.com/docs/redis/reference/transactions/#unknown"&gt;&lt;code&gt;UNKNOWN&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="extension"&gt;Extension workspace and session limits&#10;&lt;/h2&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table class="wide expand td-table--wide"&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Component&lt;/th&gt;&#10; &lt;th scope="col" style="text-align: right"&gt;Default limit&lt;/th&gt;&#10; &lt;th scope="col"&gt;Behavior when exceeded&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Per-backend C workspace and reply budget&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;2 GiB&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Raises a PostgreSQL error and rolls back the statement or savepoint.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Shared preload memory budget (&lt;code&gt;shared_preload_libraries&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;2 GiB&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Bounds shared allocations across backends.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;MONITOR&lt;/code&gt; shared-memory ring&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;4 MiB&lt;/code&gt; / &lt;code&gt;4,096&lt;/code&gt; entries&lt;/td&gt;&#10; &lt;td&gt;Drops stalled &lt;code&gt;MONITOR&lt;/code&gt; cursors that fall behind the ring head.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Pub/Sub queue per client&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;1 MiB&lt;/code&gt; / &lt;code&gt;1,024&lt;/code&gt; frames&lt;/td&gt;&#10; &lt;td&gt;Marks the session failed and closes the subscriber connection.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Total retained Pub/Sub payload&lt;/td&gt;&#10; &lt;td style="text-align: right"&gt;&lt;code&gt;64 MiB&lt;/code&gt; (&lt;code&gt;4,096&lt;/code&gt; sessions, &lt;code&gt;16,384&lt;/code&gt; subscriptions)&lt;/td&gt;&#10; &lt;td&gt;Rejects new publications/registrations and fails overflowing routes.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;p&gt;In &lt;code&gt;SET ... GET&lt;/code&gt; and &lt;code&gt;GETSET&lt;/code&gt;, the C extension releases the temporary replacement copy as soon as storage consumes it and before constructing the old-value reply, allowing full 512 MiB replacements within the default 2 GiB backend budget.&lt;/p&gt;</description></item><item><title>Configuration</title><link>https://mimus.pgsty.com/docs/redis/reference/configuration/</link><guid>https://mimus.pgsty.com/docs/redis/reference/configuration/</guid><description>&lt;p&gt;Configuration is split between command-line flags on the &lt;code&gt;pgredis&lt;/code&gt; Go gateway executable (&lt;code&gt;cmd/pgredis/main.go&lt;/code&gt;) and database-level settings managed by PostgreSQL and the &lt;code&gt;pg_redis&lt;/code&gt; extension (&lt;code&gt;v0.1.0-rc1&lt;/code&gt;, schema &lt;code&gt;0.54&lt;/code&gt;, commit &lt;code&gt;11411411d72ab45456904cc602cefbb13b68ff25&lt;/code&gt;).&lt;/p&gt;&#10;&lt;h2 id="flags"&gt;Gateway CLI flags&#10;&lt;/h2&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table class="wide expand td-table--wide"&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Flag&lt;/th&gt;&#10; &lt;th scope="col"&gt;Default&lt;/th&gt;&#10; &lt;th scope="col"&gt;Description&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-listen&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;127.0.0.1:56379&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;RESP listener address (Mimus assigns &lt;code&gt;6379&lt;/code&gt; in standard deployments).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-pg&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;postgres://127.0.0.1:55432/pgredis?sslmode=disable&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;PostgreSQL connection URL without credentials.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-auth-mode&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;native&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Authentication mode: &lt;code&gt;native&lt;/code&gt; (PostgreSQL roles) or &lt;code&gt;redis-acl&lt;/code&gt; (&lt;code&gt;redis._acl_user&lt;/code&gt;).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-acl-service-user&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;(empty)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Bound PostgreSQL &lt;code&gt;LOGIN&lt;/code&gt; role used when &lt;code&gt;-auth-mode redis-acl&lt;/code&gt; is active.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-acl-service-password-file&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;(empty)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;File containing the ACL service role password (one trailing newline stripped); falls back to &lt;code&gt;PGREDIS_ACL_SERVICE_PASSWORD&lt;/code&gt;.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-default-user&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;app&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;PostgreSQL &lt;code&gt;LOGIN&lt;/code&gt; role used for single-argument &lt;code&gt;AUTH &amp;lt;password&amp;gt;&lt;/code&gt; in &lt;code&gt;native&lt;/code&gt; mode.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-client-default-resp&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;2&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Initial wire protocol for new connections and &lt;code&gt;RESET&lt;/code&gt; (&lt;code&gt;2&lt;/code&gt; or &lt;code&gt;3&lt;/code&gt;).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-clients&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;1024&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Maximum concurrent RESP client connections.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-pools&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;8&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Maximum cached PostgreSQL identity connection pools.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-pool-size&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;4&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Maximum PostgreSQL backend connections per identity pool (&lt;code&gt;1..2147483647&lt;/code&gt;).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-tls-cert&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;(empty)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Server TLS certificate path (required when &lt;code&gt;-listen&lt;/code&gt; is non-loopback).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-tls-key&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;(empty)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Server TLS private key path (required when &lt;code&gt;-listen&lt;/code&gt; is non-loopback).&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-bulk-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;536870912&lt;/code&gt; (&lt;code&gt;512 MiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Maximum bytes for a single request bulk argument.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-frame-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;1074790400&lt;/code&gt; (&lt;code&gt;1 GiB + 1 MiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Maximum sum of argument bytes in a single request frame.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-reply-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;1074790400&lt;/code&gt; (&lt;code&gt;1 GiB + 1 MiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Maximum wire bytes for a complete reply, including &lt;code&gt;EXEC&lt;/code&gt; child replies.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-input-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;2147483648&lt;/code&gt; (&lt;code&gt;2 GiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Shared budget across connections for live input payloads and bookkeeping.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-output-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;2147483648&lt;/code&gt; (&lt;code&gt;2 GiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Shared budget across connections for live replies, workspace, and bookkeeping.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-pg-read-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;2147483648&lt;/code&gt; (&lt;code&gt;2 GiB&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Shared budget for PostgreSQL receive buffers and &lt;code&gt;DataRow&lt;/code&gt; metadata.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-max-pg-message-bytes&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;1073741822&lt;/code&gt; (&lt;code&gt;1 GiB - 2 B&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Maximum bytes in a single PostgreSQL wire message body.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-frame-read-timeout&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;30s&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Deadline to finish reading a frame after its first byte arrives.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-command-timeout&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;30s&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Per-command execution timeout against PostgreSQL.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-write-timeout&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;10s&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Deadline for writing a reply frame to the client socket.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-tls-handshake-timeout&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;5s&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Deadline for completing a client TLS handshake.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;-version&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;false&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Print &lt;code&gt;pgredis 0.1.0&lt;/code&gt; and exit.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;p&gt;The &lt;code&gt;-pg&lt;/code&gt; URL must never contain a password. In &lt;code&gt;native&lt;/code&gt; mode, clients supply their PostgreSQL role credentials via &lt;code&gt;AUTH&lt;/code&gt; or &lt;code&gt;HELLO ... AUTH&lt;/code&gt;. In &lt;code&gt;redis-acl&lt;/code&gt; mode, the gateway connects with &lt;code&gt;-acl-service-user&lt;/code&gt; and verifies per-user hashes inside &lt;code&gt;redis._acl_user&lt;/code&gt;.&lt;/p&gt;</description></item><item><title>Streams and consumer groups</title><link>https://mimus.pgsty.com/docs/redis/reference/streams/</link><guid>https://mimus.pgsty.com/docs/redis/reference/streams/</guid><description>&lt;p&gt;A Redis Stream stores append-only entries ordered by a two-part identifier (&lt;code&gt;milliseconds-sequence&lt;/code&gt;). Each entry contains an ordered list of binary field/value pairs. Consumer groups allow multiple workers to partition a stream, track unacknowledged work in a Pending Entries List (PEL), and transfer stalled entries.&lt;/p&gt;&#10;&lt;p&gt;For an end-to-end transactional example combining SQL tables with Redis Streams, see the &lt;a href="https://mimus.pgsty.com/docs/redis/tutorial/outbox/"&gt;Transactional outbox tutorial&lt;/a&gt;.&lt;/p&gt;&#10;&lt;h2 id="entries"&gt;Entries, IDs, and trimming&#10;&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;Full 128-bit ID domain:&lt;/strong&gt; Stream IDs consist of two unsigned 64-bit integers (&lt;code&gt;ms-seq&lt;/code&gt;). &lt;code&gt;pgredis&lt;/code&gt; preserves the full &lt;code&gt;uint64&lt;/code&gt; range for both components inside &lt;code&gt;redis._stream&lt;/code&gt;.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Entry payload fidelity:&lt;/strong&gt; Field/value pairs retain their exact insertion order, duplicate field names within the same entry, and arbitrary binary bytes (including &lt;code&gt;NUL&lt;/code&gt;).&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Write, read, and trim commands:&lt;/strong&gt; Use &lt;code&gt;XADD&lt;/code&gt; to append entries (&lt;code&gt;NOMKSTREAM&lt;/code&gt;, &lt;code&gt;MAXLEN&lt;/code&gt;, &lt;code&gt;MINID&lt;/code&gt;), &lt;code&gt;XRANGE&lt;/code&gt; and &lt;code&gt;XREVRANGE&lt;/code&gt; to query ID intervals (&lt;code&gt;-&lt;/code&gt;, &lt;code&gt;+&lt;/code&gt;, exclusive &lt;code&gt;(&lt;/code&gt; bounds, &lt;code&gt;COUNT&lt;/code&gt;), &lt;code&gt;XLEN&lt;/code&gt; to read the entry count, and &lt;code&gt;XDEL&lt;/code&gt; or &lt;code&gt;XTRIM&lt;/code&gt; to remove entries.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Approximate trimming and &lt;code&gt;XSETID&lt;/code&gt;:&lt;/strong&gt; Approximate trimming (&lt;code&gt;MAXLEN ~&lt;/code&gt; or &lt;code&gt;MINID ~&lt;/code&gt;) follows internal stream node boundaries configured by &lt;code&gt;stream-node-max-entries&lt;/code&gt; and &lt;code&gt;stream-node-max-bytes&lt;/code&gt;, so it may retain more entries than the requested threshold. &lt;code&gt;XSETID&lt;/code&gt; updates stream metadata (&lt;code&gt;last_generated_id&lt;/code&gt;, &lt;code&gt;entries_added&lt;/code&gt;, &lt;code&gt;max_deleted_entry_id&lt;/code&gt;) without inserting an entry or waking blocked readers.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="groups"&gt;Consumer groups and pending entries&#10;&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;Group lifecycle:&lt;/strong&gt; &lt;code&gt;XGROUP CREATE&lt;/code&gt; (&lt;code&gt;MKSTREAM&lt;/code&gt;, &lt;code&gt;ENTRIESREAD&lt;/code&gt;), &lt;code&gt;XGROUP SETID&lt;/code&gt;, &lt;code&gt;XGROUP DESTROY&lt;/code&gt;, &lt;code&gt;XGROUP CREATECONSUMER&lt;/code&gt;, and &lt;code&gt;XGROUP DELCONSUMER&lt;/code&gt; manage consumer group state in &lt;code&gt;redis._stream_group&lt;/code&gt;.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Reading and acknowledging:&lt;/strong&gt; &lt;code&gt;XREADGROUP GROUP &amp;lt;group&amp;gt; &amp;lt;consumer&amp;gt; ... STREAMS &amp;lt;key&amp;gt; &amp;gt;&lt;/code&gt; delivers new entries and records them in &lt;code&gt;redis._stream_pel&lt;/code&gt; unless &lt;code&gt;NOACK&lt;/code&gt; is specified. &lt;code&gt;XACK&lt;/code&gt; removes acknowledged entries from the PEL.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Inspecting and claiming stalled work:&lt;/strong&gt; &lt;code&gt;XPENDING&lt;/code&gt; inspects unacknowledged entries by ID range, idle time (&lt;code&gt;IDLE&lt;/code&gt;), and consumer. &lt;code&gt;XCLAIM&lt;/code&gt; and &lt;code&gt;XAUTOCLAIM&lt;/code&gt; transfer ownership of pending entries to another consumer and increment delivery counters.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Deleted entries in the PEL:&lt;/strong&gt; If an entry is deleted with &lt;code&gt;XDEL&lt;/code&gt; while still referenced in &lt;code&gt;redis._stream_pel&lt;/code&gt;, historical &lt;code&gt;XREADGROUP&lt;/code&gt; (&lt;code&gt;0&lt;/code&gt;) or &lt;code&gt;XCLAIM&lt;/code&gt; calls return a nil/empty payload for that ID, matching Redis 7.2.4. Known gaps in &lt;code&gt;v0.1.0-rc1&lt;/code&gt;: &lt;code&gt;XINFO GROUPS&lt;/code&gt; computes &lt;code&gt;lag&lt;/code&gt; from stream length rather than adjusting for &lt;code&gt;XDEL&lt;/code&gt;, and &lt;code&gt;XAUTOCLAIM&lt;/code&gt; has one cursor formatting difference when draining an empty queue (&lt;code&gt;99/101&lt;/code&gt; in &lt;code&gt;unit/type/stream-cgroups&lt;/code&gt;; see &lt;a href="https://mimus.pgsty.com/docs/redis/status/#known-issues"&gt;Status&lt;/a&gt;).&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="blocking"&gt;Blocking reads&#10;&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;RESP connections:&lt;/strong&gt; &lt;code&gt;XREAD BLOCK &amp;lt;ms&amp;gt;&lt;/code&gt; and &lt;code&gt;XREADGROUP BLOCK &amp;lt;ms&amp;gt;&lt;/code&gt; wait for matching &lt;code&gt;XADD&lt;/code&gt; commits. Inside &lt;code&gt;MULTI&lt;/code&gt;/&lt;code&gt;EXEC&lt;/code&gt;, &lt;code&gt;BLOCK&lt;/code&gt; options run non-blockingly as immediate reads; external clients blocked on a stream wake only after an &lt;code&gt;EXEC&lt;/code&gt; batch or SQL transaction commits.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;SQL transactions:&lt;/strong&gt; Ordinary &lt;code&gt;redis.command&lt;/code&gt; calls cannot block and commit a caller&amp;rsquo;s transaction while waiting. SQL callers use &lt;a href="https://mimus.pgsty.com/docs/redis/reference/sql/#sessions"&gt;&lt;code&gt;redis.blocking_begin&lt;/code&gt;, &lt;code&gt;redis.blocking_poll&lt;/code&gt;, and &lt;code&gt;redis.blocking_cancel&lt;/code&gt;&lt;/a&gt; across transactions.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Restart behavior:&lt;/strong&gt; Stream entries, consumer group offsets (&lt;code&gt;last_delivered_id&lt;/code&gt;), and PEL records persist in PostgreSQL WAL and survive restarts and &lt;code&gt;pg_dump&lt;/code&gt; / &lt;code&gt;pg_restore&lt;/code&gt;, whereas active &lt;code&gt;BLOCK&lt;/code&gt; network waits are transient and require clients to reconnect.&lt;/li&gt;&#10;&lt;/ul&gt;</description></item><item><title>Pub/Sub and keyspace events</title><link>https://mimus.pgsty.com/docs/redis/reference/pubsub/</link><guid>https://mimus.pgsty.com/docs/redis/reference/pubsub/</guid><description>&lt;p&gt;&lt;code&gt;pgredis&lt;/code&gt; implements Redis Pub/Sub channels (&lt;code&gt;SUBSCRIBE&lt;/code&gt;, &lt;code&gt;UNSUBSCRIBE&lt;/code&gt;, &lt;code&gt;PUBLISH&lt;/code&gt;), pattern subscriptions (&lt;code&gt;PSUBSCRIBE&lt;/code&gt;, &lt;code&gt;PUNSUBSCRIBE&lt;/code&gt;), standalone sharded Pub/Sub (&lt;code&gt;SSUBSCRIBE&lt;/code&gt;, &lt;code&gt;SUNSUBSCRIBE&lt;/code&gt;, &lt;code&gt;SPUBLISH&lt;/code&gt;), introspection (&lt;code&gt;PUBSUB CHANNELS&lt;/code&gt;, &lt;code&gt;PUBSUB NUMSUB&lt;/code&gt;, &lt;code&gt;PUBSUB NUMPAT&lt;/code&gt;, &lt;code&gt;PUBSUB SHARDCHANNELS&lt;/code&gt;, &lt;code&gt;PUBSUB SHARDNUMSUB&lt;/code&gt;), and keyspace notifications (&lt;code&gt;notify-keyspace-events&lt;/code&gt;).&lt;/p&gt;&#10;&lt;h2 id="lifecycle"&gt;Subscriptions and transactional delivery&#10;&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;Commit-ordered registration:&lt;/strong&gt; The gateway confirms &lt;code&gt;SUBSCRIBE&lt;/code&gt;, &lt;code&gt;PSUBSCRIBE&lt;/code&gt;, or &lt;code&gt;SSUBSCRIBE&lt;/code&gt; only after PostgreSQL commits the subscription registration in &lt;code&gt;redis._pubsub_session&lt;/code&gt;. Any &lt;code&gt;PUBLISH&lt;/code&gt; or &lt;code&gt;SPUBLISH&lt;/code&gt; committed afterwards reaches the subscriber.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Transactional publishing:&lt;/strong&gt; Because &lt;code&gt;PUBLISH&lt;/code&gt; inserts into &lt;code&gt;redis._pubsub_event&lt;/code&gt; inside the publisher&amp;rsquo;s PostgreSQL transaction, rolling back a SQL transaction or aborting &lt;code&gt;EXEC&lt;/code&gt; discards any messages published inside that transaction. Publishing the same payload twice in committed transactions delivers two distinct messages.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Sharded Pub/Sub scope:&lt;/strong&gt; &lt;code&gt;SSUBSCRIBE&lt;/code&gt;, &lt;code&gt;SUNSUBSCRIBE&lt;/code&gt;, and &lt;code&gt;SPUBLISH&lt;/code&gt; operate within the standalone PostgreSQL database; they do not route messages across a Redis Cluster.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;SQL session API:&lt;/strong&gt; SQL callers use &lt;a href="https://mimus.pgsty.com/docs/redis/reference/sql/#sessions"&gt;&lt;code&gt;redis.pubsub_open&lt;/code&gt;, &lt;code&gt;redis.pubsub_change&lt;/code&gt;, &lt;code&gt;redis.pubsub_poll&lt;/code&gt;, and &lt;code&gt;redis.pubsub_cancel&lt;/code&gt;&lt;/a&gt;. Commit the subscription transaction before publishing from another connection. &lt;code&gt;pubsub_poll&lt;/code&gt; deletes delivered messages in its own transaction, and a rollback restores them.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="events"&gt;Keyspace notifications&#10;&lt;/h2&gt;&#10;&lt;p&gt;&lt;code&gt;CONFIG SET notify-keyspace-events &amp;lt;flags&amp;gt;&lt;/code&gt; enables keyspace (&lt;code&gt;__keyspace@&amp;lt;db&amp;gt;__:&amp;lt;key&amp;gt;&lt;/code&gt;) and keyevent (&lt;code&gt;__keyevent@&amp;lt;db&amp;gt;__:&amp;lt;event&amp;gt;&lt;/code&gt;) notifications across all 16 logical Redis databases in the current PostgreSQL database (requires &lt;code&gt;redis._admin()&lt;/code&gt; capability):&lt;/p&gt;</description></item><item><title>Transactions and retries</title><link>https://mimus.pgsty.com/docs/redis/reference/transactions/</link><guid>https://mimus.pgsty.com/docs/redis/reference/transactions/</guid><description>&lt;p&gt;SQL callers and Redis wire clients share the same PostgreSQL storage tables and WAL, but they enter transactions through different boundaries.&lt;/p&gt;&#10;&lt;h2 id="multi"&gt;MULTI, EXEC, and WATCH&#10;&lt;/h2&gt;&#10;&lt;p&gt;&lt;code&gt;MULTI&lt;/code&gt; starts a command queue in the Go gateway. &lt;code&gt;EXEC&lt;/code&gt; dispatches the queued commands inside a single PostgreSQL &lt;code&gt;READ COMMITTED&lt;/code&gt; transaction. An idle &lt;code&gt;MULTI&lt;/code&gt; or &lt;code&gt;WATCH&lt;/code&gt; session on a client connection does not hold an open PostgreSQL transaction in the background.&lt;/p&gt;</description></item><item><title>SQL API</title><link>https://mimus.pgsty.com/docs/redis/reference/sql/</link><guid>https://mimus.pgsty.com/docs/redis/reference/sql/</guid><description>&lt;p&gt;The &lt;code&gt;pg_redis&lt;/code&gt; extension exposes SQL functions in schema &lt;code&gt;redis&lt;/code&gt; so PostgreSQL transactions, stored procedures, and triggers can execute Redis commands in the same transaction as relational tables. Every function returns wire-formatted RESP replies as &lt;code&gt;bytea&lt;/code&gt;.&lt;/p&gt;&#10;&lt;p&gt;For step-by-step examples, see &lt;a href="https://mimus.pgsty.com/docs/redis/tutorial/sql-rollback/"&gt;SQL rollback&lt;/a&gt;, &lt;a href="https://mimus.pgsty.com/docs/redis/tutorial/binary-data/"&gt;Binary keys and values&lt;/a&gt;, and &lt;a href="https://mimus.pgsty.com/docs/redis/tutorial/outbox/"&gt;Transactional outbox&lt;/a&gt;.&lt;/p&gt;&#10;&lt;h2 id="commands"&gt;Command functions&#10;&lt;/h2&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table class="wide expand td-table--wide"&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Function&lt;/th&gt;&#10; &lt;th scope="col"&gt;Arguments&lt;/th&gt;&#10; &lt;th scope="col"&gt;Description&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;redis.command(text[], integer DEFAULT 0)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Command and arguments as &lt;code&gt;text[]&lt;/code&gt;, followed by logical database number (&lt;code&gt;0..15&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Executes one command and returns a RESP2 reply as &lt;code&gt;bytea&lt;/code&gt;.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;&lt;code&gt;redis.command_bin(bytea[], integer DEFAULT 0)&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Command and arguments as &lt;code&gt;bytea[]&lt;/code&gt;, followed by logical database number (&lt;code&gt;0..15&lt;/code&gt;)&lt;/td&gt;&#10; &lt;td&gt;Binary-safe entry point for &lt;code&gt;NUL&lt;/code&gt; (&lt;code&gt;\x00&lt;/code&gt;) bytes or non-UTF-8 payloads; returns a RESP2 reply as &lt;code&gt;bytea&lt;/code&gt;.&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;div class="td-code td-code--untitled" id="td-code-d3cd2a84-fence-0" data-td-code data-td-code-auto-id&#10; data-td-language="sql" data-td-line-count="5"&gt;&#10; &lt;div class="td-code__viewport" id="td-code-d3cd2a84-fence-0-viewport" data-td-code-viewport&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;encode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;command&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;ARRAY&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;PING&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;]),&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;hex&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;&#10;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="c1"&gt;-- 2b504f4e470d0a (+PONG\r\n)&#10;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;&#10;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;convert_from&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;command&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;ARRAY&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;GET&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;example:key&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;UTF8&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;&#10;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="c1"&gt;-- Reads example:key from logical database 1&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&#10;&lt;/div&gt;&#10;&lt;p&gt;Calling &lt;code&gt;redis.command&lt;/code&gt; invokes &lt;code&gt;redis.command_bin&lt;/code&gt; internally, so the calling PostgreSQL role requires &lt;code&gt;USAGE ON SCHEMA redis&lt;/code&gt;, &lt;code&gt;EXECUTE&lt;/code&gt; on both functions, and &lt;code&gt;EXECUTE&lt;/code&gt; on the required capability marker (&lt;code&gt;redis._read()&lt;/code&gt;, &lt;code&gt;redis._write()&lt;/code&gt;, or &lt;code&gt;redis._admin()&lt;/code&gt;). See &lt;a href="https://mimus.pgsty.com/docs/redis/operations/security/#permissions"&gt;Authentication and permissions&lt;/a&gt; for the complete &lt;code&gt;GRANT&lt;/code&gt; list.&lt;/p&gt;</description></item><item><title>Data types</title><link>https://mimus.pgsty.com/docs/redis/reference/data-types/</link><guid>https://mimus.pgsty.com/docs/redis/reference/data-types/</guid><description>&lt;p&gt;&lt;code&gt;pgredis&lt;/code&gt; implements command families for the core Redis 7.2.4 data types and derived structures inside PostgreSQL 18 tables. Every key has one metadata row in &lt;code&gt;redis._keyspace&lt;/code&gt; and stores its payload in the matching typed table. See &lt;a href="https://mimus.pgsty.com/docs/redis/architecture/storage/"&gt;Storage&lt;/a&gt; for the underlying table layout and &lt;a href="https://mimus.pgsty.com/docs/redis/reference/commands/"&gt;Commands&lt;/a&gt; for the per-command list.&lt;/p&gt;&#10;&lt;h2 id="core"&gt;Core types&#10;&lt;/h2&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table class="wide expand td-table--wide"&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Type&lt;/th&gt;&#10; &lt;th scope="col"&gt;Backing table&lt;/th&gt;&#10; &lt;th scope="col"&gt;Primary use&lt;/th&gt;&#10; &lt;th scope="col"&gt;Representative commands&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;String&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._string&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Byte sequences, integers, floats, or bitmaps&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;SET&lt;/code&gt;, &lt;code&gt;GET&lt;/code&gt;, &lt;code&gt;MSET&lt;/code&gt;, &lt;code&gt;MGET&lt;/code&gt;, &lt;code&gt;INCR&lt;/code&gt;, &lt;code&gt;INCRBYFLOAT&lt;/code&gt;, &lt;code&gt;LCS&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Hash&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._hash&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Field/value maps under one key&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;HSET&lt;/code&gt;, &lt;code&gt;HGET&lt;/code&gt;, &lt;code&gt;HMGET&lt;/code&gt;, &lt;code&gt;HGETALL&lt;/code&gt;, &lt;code&gt;HINCRBY&lt;/code&gt;, &lt;code&gt;HRANDFIELD&lt;/code&gt;, &lt;code&gt;HSCAN&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;List&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._list&lt;/code&gt;, &lt;code&gt;redis._list_length&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Ordered sequences of elements (duplicates allowed)&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;LPUSH&lt;/code&gt;, &lt;code&gt;RPUSH&lt;/code&gt;, &lt;code&gt;LPOP&lt;/code&gt;, &lt;code&gt;LRANGE&lt;/code&gt;, &lt;code&gt;LINDEX&lt;/code&gt;, &lt;code&gt;LINSERT&lt;/code&gt;, &lt;code&gt;BLMOVE&lt;/code&gt;, &lt;code&gt;BLPOP&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Set&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._set&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Unordered collections of unique members&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;SADD&lt;/code&gt;, &lt;code&gt;SREM&lt;/code&gt;, &lt;code&gt;SMEMBERS&lt;/code&gt;, &lt;code&gt;SISMEMBER&lt;/code&gt;, &lt;code&gt;SUNION&lt;/code&gt;, &lt;code&gt;SINTER&lt;/code&gt;, &lt;code&gt;SSCAN&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Sorted set&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._zset&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Unique members ordered by &lt;code&gt;float8&lt;/code&gt; score, then raw member bytes&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;ZADD&lt;/code&gt;, &lt;code&gt;ZRANGE&lt;/code&gt;, &lt;code&gt;ZREM&lt;/code&gt;, &lt;code&gt;ZSCORE&lt;/code&gt;, &lt;code&gt;ZRANK&lt;/code&gt;, &lt;code&gt;ZUNIONSTORE&lt;/code&gt;, &lt;code&gt;BZPOPMIN&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Stream&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;redis._stream&lt;/code&gt;, &lt;code&gt;redis._stream_group&lt;/code&gt;, &lt;code&gt;redis._stream_pel&lt;/code&gt;&lt;/td&gt;&#10; &lt;td&gt;Append-only entries ordered by &lt;code&gt;(ms, seq)&lt;/code&gt; ID with consumer groups&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;XADD&lt;/code&gt;, &lt;code&gt;XRANGE&lt;/code&gt;, &lt;code&gt;XREAD&lt;/code&gt;, &lt;code&gt;XGROUP&lt;/code&gt;, &lt;code&gt;XREADGROUP&lt;/code&gt;, &lt;code&gt;XACK&lt;/code&gt;, &lt;code&gt;XAUTOCLAIM&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;p&gt;Keys, string values, hash fields, list elements, set members, and sorted-set members are stored as &lt;code&gt;bytea&lt;/code&gt; and preserve arbitrary binary sequences, including &lt;code&gt;NUL&lt;/code&gt; (&lt;code&gt;\x00&lt;/code&gt;) bytes. When calling from SQL with non-UTF-8 or &lt;code&gt;NUL&lt;/code&gt;-containing bytes, use &lt;a href="https://mimus.pgsty.com/docs/redis/tutorial/binary-data/"&gt;&lt;code&gt;redis.command_bin&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Commands</title><link>https://mimus.pgsty.com/docs/redis/reference/commands/</link><guid>https://mimus.pgsty.com/docs/redis/reference/commands/</guid><description>&lt;p&gt;This page is generated from &lt;code&gt;spec/commands.json&lt;/code&gt; in the &lt;code&gt;pgredis&lt;/code&gt; repository (&lt;code&gt;v0.1.0-rc1&lt;/code&gt;, schema &lt;code&gt;0.54&lt;/code&gt;, commit &lt;code&gt;11411411d72ab45456904cc602cefbb13b68ff25&lt;/code&gt;), which tracks 392 Redis 7.2.4 command and subcommand entries:&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;305 entries&lt;/strong&gt; are marked &lt;code&gt;partial-slice&lt;/code&gt; (implemented in the C extension, Go gateway, or both).&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;87 entries&lt;/strong&gt; are marked &lt;code&gt;pending&lt;/code&gt; (32 Cluster, 22 Sentinel, 19 Scripting, and 14 Server commands that return explicit unsupported errors).&lt;/li&gt;&#10;&lt;li&gt;All 392 entries carry &lt;code&gt;compatibility_verified: false&lt;/code&gt; in the specification file: &lt;code&gt;partial-slice&lt;/code&gt; records implementation presence, not full certification. See &lt;a href="https://mimus.pgsty.com/docs/redis/compatibility/"&gt;Compatibility&lt;/a&gt; and &lt;a href="https://mimus.pgsty.com/docs/redis/status/"&gt;Status&lt;/a&gt; for dated test results.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;In the arity column, a positive integer is the exact argument count including the command word, and a negative integer is the minimum argument count (for example, &lt;code&gt;-3&lt;/code&gt; for &lt;code&gt;SET&lt;/code&gt; means at least command, key, and value).&lt;/p&gt;</description></item></channel></rss>