Entwickler-Tools

Redis Guide

Nutze ein Entwickler-Tool für Daten, Code oder Nachschlage-Workflows.

TypeCommandExplanation
Connectionredis-cliConnect to a local Redis server.
Connectionredis-cli -h 127.0.0.1 -p 6379 -a passwordConnect to a Redis server with host, port, and password.
ServerPINGCheck whether Redis is responding.
StringSET user:1:name "Ada"Set a string value.
StringGET user:1:nameRead a string value.
StringSET session:abc "value" EX 3600Set a value with expiration in seconds.
StringINCR counter:visitsIncrement an integer value.
KeyEXISTS user:1:nameCheck whether a key exists.
KeyDEL user:1:nameDelete one or more keys.
KeyTTL session:abcShow remaining expiration time.
HashHSET user:1 email ada@example.com age 36Set fields on a hash.
HashHGETALL user:1Read all fields from a hash.
ListLPUSH queue:emails job-1Push an item to the left of a list.
ListRPOP queue:emailsPop an item from the right of a list.
SetSADD tags:post:1 redis cache databaseAdd unique values to a set.
SetSMEMBERS tags:post:1Read all set members.
Sorted SetZADD leaderboard 100 user:1 90 user:2Add scored members.
Sorted SetZREVRANGE leaderboard 0 9 WITHSCORESRead top scores.
Pub/SubPUBLISH events:user.created "1"Publish a message to a channel.
Pub/SubSUBSCRIBE events:user.createdSubscribe to a channel.
StreamXADD orders * user_id 1 total 39.99Append an entry to a stream.
StreamXRANGE orders - + COUNT 10Read stream entries.
AdminINFOShow server metrics and configuration summary.
AdminFLUSHDBDelete all keys from the current database. Use carefully.

Concepts

Common Redis data types

TypeUse caseExamples
StringCache values, counters, feature flags, sessions.SET, GET, INCR, MGET
HashObject-like field storage.HSET, HGET, HGETALL
ListQueues and ordered collections.LPUSH, RPOP, LRANGE
SetUnique unordered values.SADD, SMEMBERS, SINTER
Sorted SetLeaderboards and ranked data.ZADD, ZRANGE, ZREVRANGE
StreamAppend-only event streams.XADD, XRANGE, XREAD

FAQ

Häufige Fragen

Wofür wird Redis Guide verwendet?

Redis Guide hilft, diesen Workflow direkt im Browser abzuschließen.

Brauche ich ein Konto?

Nein. NovaKit-Tools sind für die direkte Nutzung ohne Konto gedacht.

Kann ich Ergebnisse kopieren oder herunterladen?

Wenn Ausgaben entstehen, bietet die Seite Kopieren-, Download- oder Exportaktionen.

Verwandte Tools

Weiterarbeiten