We do not use Redis. The client was a go-redis fork and still said so
everywhere: `package redis`, `redis.NewClient`, `redis://`, `extra/redisotel`.
Consumers wrote `redis.Client` against a Valkey-backed store called KV.
package redis -> package kv (93 decls)
redis.X -> kv.X (2,794 call sites)
"redis: …" errors -> "kv: …" (206)
extra/redis{otel,cmd,prometheus,census} -> extra/kv{otel,cmd,prometheus,census}
redis:// , rediss:// -> kv:// , kvs:// (ParseURL)
Redis*/*Redis* idents -> KV*/*KV*
REDIS_VERSION, REDIS_ENDPOINTS_CONFIG_PATH -> KV_*
I previously argued this rename was unsafe because much of it was "wire
contract". That was wrong, and the categorisation shows why: RESP command names
are GET/SET/HSET — they never contain the word. Of 5,771 occurrences only two
kinds were server-visible at all: the ParseURL scheme (we choose what we pass;
our configs already use kv://) and the CLIENT SETINFO lib-name label, which the
server merely records. Nothing here changes a byte of protocol.
Two things deliberately keep the old spelling:
RediSearch — names a specific external module the FT.* commands map to.
StoreDist — contains the letters by accident (sto-reDis-t), not the word.
Breaking for consumers by design: every import site must move redis.X -> kv.X.
Minor bump, never a major — this module stays v9 forever.
KV lives in its own org now, like hanzokms / hanzos3 / hanzo-ds. The repo moved
hanzoai/kv-go -> hanzokv/go, so the module path follows: a Go module path must
match where the repo actually is, or the proxy cannot resolve it.
The name is `go`, not `kv-go`, following the hanzo-ds convention — that org
holds go, mock, native, sqlbuilder, sqlparser, each named for its language or
concern with the ORG supplying the product noun. Repeating "kv" inside a repo
that already lives under hanzokv is the compound-word habit we are dropping.
349 occurrences across 188 files: the root module, all four extra/* modules,
every example module, imports throughout the tree, and the docs. Builds clean.
The package is still `package redis` and the extra dirs are still named
redis*. That rename is deliberately NOT bundled here: it is 5,771 occurrences,
it breaks all 11 consumers at once, and a large share are WIRE CONTRACTS rather
than branding — the redis:// scheme parser, the "redis: nil" error string, RESP
command names. Renaming those breaks protocol compatibility with the Valkey
server. It needs the same our-vocabulary-vs-the-wire split the argo sweep used,
as its own change.
GitHub keeps the old path redirecting, and versions already published under
github.com/hanzoai/kv-go/v9 stay resolvable, so nothing breaks the moment this
lands. Consumers move on their own schedule.
Update module path from github.com/redis/go-redis/v9 to
github.com/hanzoai/kv-go/v9 for use as the Hanzo KV Go SDK.
- Update go.mod module declaration
- Update all Go imports across 260 files
- Update all submodule go.mod files (extra/*, example/*, internal/customvet)
* add cas/cad commands
* feat(command): Add SetIFDEQ, SetIFDNE and *Get cmds
Decided to move the *Get argument as a separate methods, since the
response will be always the previous value, but in the case where
the previous value is `OK` there result may be ambiguous.
* fix tests
* matchValue to be interface{}
* Only Args approach for DelEx
* use uint64 for digest, add example
* test only for 8.4
* Add support for new bitop operations
* chore(ci): Add 8.2 pre build for CI
* feat(info): add new client info keys
* fixed tests
* added godocs for bitop commands
---------
Co-authored-by: Nedyalko Dyakov <[email protected]>
Co-authored-by: Nedyalko Dyakov <[email protected]>
* fix(txpipeline): keyless commands should take the slot of the keyed commands
* fix(txpipeline): extract only keyed cmds from all cmds
* chore(test): Add tests for keyless cmds and txpipeline
* fix(cmdSlot): Add preferred random slot
* fix(cmdSlot): Add shortlist of keyless cmds
* chore(test): Fix ring test
* fix(keylessCommands): Add list of keyless commands
Add list of keyless Commands based on the Commands output
for redis 8
* chore(txPipeline): refactor slottedCommands impl
* fix(osscluster): typo
* feat: support vectorset
* fix: char encoding error
* use `any` instread of `interface{}`
* update vectorset API
Signed-off-by: fukua95 <[email protected]>
* refact: MapStringFloat64Cmd -> VectorInfoSliceCmd
Signed-off-by: fukua95 <[email protected]>
* update:
* the type of vector attribute: string -> VectorAttributeMarshaller
* Add a new API VRemAttr
* mark the APIs are experimental
Signed-off-by: fukua95 <[email protected]>
* trigger CI again
Signed-off-by: fukua95 <[email protected]>
* rename a API: VRemAttr -> VClearAttributes
Signed-off-by: fukua95 <[email protected]>
* add test
Signed-off-by: fukua95 <[email protected]>
* feat(vectorset): improve VSetAttr API and add comprehensive test suite
- Simplify VSetAttr to accept interface{} with automatic JSON marshalling
- Remove VectorAttributeMarshaller interface for simpler API
- Add comprehensive unit tests for all vectorset commands
---------
Signed-off-by: fukua95 <[email protected]>
Co-authored-by: Nedyalko Dyakov <[email protected]>
* xinfo-groups: support nil lag in XINFO GROUPS
* Add test
* docs: clarify XInfoGroup.Lag field behavior with Nil values
* docs: clarify XInfoGroup.Lag field behavior
* migrate golangci-lint config to v2 format
* chore: skip CI on migration [skip ci]
* Bump golangci version
* Address several golangci-lint/staticcheck warnings
* change staticchecks settings
* Add tests for unified config in Redis 8
* WIP: fix reading FT.CONFIG with RESP3
* add more tests
* use search-timeout
* move deprecated warnings on the bottom
* Add 8.0m3 image in docker compose
* Add new key `io-thread` in client info
Redis 8.0 introduces new key `io-thread` in the response
for client info. The key needs to be parsed. If an unknown key
is observed, the client will return an error.
* improve readibility
* Revert "Add 8.0m3 image in docker compose"
This reverts commit 787c41f42917fb7d3ca3471d9941304695a9b3c8.
* add dockers directory to gitignore
* Fix monitor on go 1.19
* Remove exmaple tests when go 1.19
* Fix typo
* Fix typo
* Skip exmaple test
* Skip exmaple test
* Guard Peek call with mutex for thread safety
* add helpers to set library name and library info without risk of panic if we try to set both
* refactor code to use helpers
* add example
* refactor tests
* fix testable example
* simplify example
* rename exampl
* fix ring.go
* update example
---------
Co-authored-by: ofekshenawa <[email protected]>
Add an extended version of Info() to parse the results from a call to redis.Info so that it’s simpler to operate on any given item in the result.
Signed-off-by: Nic Gibson <[email protected]>
* run go fix ./...
Signed-off-by: Tiago Peczenyj <[email protected]>
* run make fmt
Signed-off-by: Tiago Peczenyj <[email protected]>
* fix go vet ./... issues
* Update README.md
Reorder imports with the rules defined in the Makefile
as if we run `make fmt`
* run gofumpt -w .
* update Makefile to use gofumpt instead gofmt
* increment makefile
* format test
* format tests
Signed-off-by: Tiago Peczenyj <[email protected]>
---------
Signed-off-by: Tiago Peczenyj <[email protected]>
Co-authored-by: ofekshenawa <[email protected]>
* feat: merge master
* feat: revert ring.go
* feat: add ClientSetInfo command
* fix: test and cmd:
* fix: test and cmd
* fix: test and cmd
* fix: test and cmd
* feat: redesigning the API
* fix: panic test
* fix: panic test
---------
Co-authored-by: Anuragkillswitch <[email protected]>
Co-authored-by: ofekshenawa <[email protected]>
* fix: In the response of the XInfoStreamFull command, the "entries-read" field may be nil
Signed-off-by: monkey92t <[email protected]>
* add XInfoStreamFull test
Signed-off-by: monkey92t <[email protected]>
* add test XInfoStreamFull entries_read = nil
Signed-off-by: monkey92t <[email protected]>
---------
Signed-off-by: monkey92t <[email protected]>
* feat: initial set up for LCSCmd
* feat: adding test for LCS with no additional params
* feat: adding test for LCS with LEN param
* feat: resolving conflicts in command.go
* fix: changing reply and query structure
* feat: commands test for lcs and lcs with len
* fix: using dynamic args length
* fix: read
* fix: Cmd init
* sorting out the LCS commands
Signed-off-by: monkey92t <[email protected]>
* fix: Adding error case test
* fix: adding correct error message
* fix: removed blank lines
---------
Signed-off-by: monkey92t <[email protected]>
Co-authored-by: Anuragkillswitch <[email protected]>
Co-authored-by: monkey92t <[email protected]>
* Implements function load, load replace and flush
* Implements `FUNCTIONS LIST`
* Fixes ineffectual assignment to err
* Extends other tests from the `FUNCTION` group
* Changes RdsFunction to Function
* Renames FunctionList command, for consistency
* Small fixes after review
* More fixes after review
* Implements the `LIBRARYNAME` and `WITHCODE` args for `FUNCTION LIST`
* Implements `FUNCTION DUMP`. Solves https://github.com/redis/go-redis/issues/2396
* Use a pointer instead of value for `First()`
* Implements `FUNCTION RESTORE`. Closes#2401.
* chore: tidy code
Signed-off-by: monkey92t <[email protected]>
---------
Signed-off-by: monkey92t <[email protected]>
Co-authored-by: monkey92t <[email protected]>