* Add guidance on unstable RESP3 support for RediSearch commands to README (#3177)
* Add UnstableResp3 to docs
* Add RawVal and RawResult to wordlist
* Explain more about SetVal
* Add UnstableResp to wordlist
* Eliminate redundant dial mutex causing unbounded connection queue contention (#3088)
* Eliminate redundant dial mutex causing unbounded connection queue contention
* Dialer connection timeouts unit test
---------
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
* SortByWithCount FTSearchOptions fix (#3201)
* SortByWithCount FTSearchOptions fix
* FTSearch test fix
* Another FTSearch test fix
* Another FTSearch test fix
---------
Co-authored-by: Christopher Golling <Chris.Golling@aexp.com>
* Fix race condition in clusterNodes.Addrs() (#3219)
Resolve a race condition in the clusterNodes.Addrs() method.
Previously, the method returned a reference to a string slice, creating
the potential for concurrent reads by the caller while the slice was
being modified by the garbage collection process.
Co-authored-by: Nedyalko Dyakov <nedyalko.dyakov@gmail.com>
* chore: fix some comments (#3226)
Signed-off-by: zhuhaicity <zhuhai@52it.net>
Co-authored-by: Nedyalko Dyakov <nedyalko.dyakov@gmail.com>
* fix(aggregate, search): ft.aggregate bugfixes (#3263)
* fix: rearange args for ft.aggregate
apply should be before any groupby or sortby
* improve test
* wip: add scorer and addscores
* enable all tests
* fix ftsearch with count test
* make linter happy
* Addscores is available in later redisearch releases.
For safety state it is available in redis ce 8
* load an apply seem to break scorer and addscores
* fix: add unstableresp3 to cluster client (#3266)
* fix: add unstableresp3 to cluster client
* propagate unstableresp3
* proper test that will ignore error, but fail if client panics
* add separate test for clusterclient constructor
* fix: flaky ClientKillByFilter test (#3268)
* Reinstate read-only lock on hooks access in dialHook (#3225)
* use limit when limitoffset is zero (#3275)
* remove redis 8 comments
* update package versions
* use latest golangci-lint
* fix(search&aggregate):fix error overwrite and typo #3220 (#3224)
* fix (#3220)
* LOAD has NO AS param(https://redis.io/docs/latest/commands/ft.aggregate/)
* fix typo: WITHCOUT -> WITHCOUNT
* fix (#3220):
* Compatible with known RediSearch issue in test
* fix (#3220)
* fixed the calculation bug of the count of load params
* test should not include special condition
* return errors when they occur
---------
Co-authored-by: Nedyalko Dyakov <nedyalko.dyakov@gmail.com>
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
* Recognize byte slice for key argument in cluster client hash slot computation (#3049)
Co-authored-by: Vladyslav Vildanov <117659936+vladvildanov@users.noreply.github.com>
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
---------
Signed-off-by: zhuhaicity <zhuhai@52it.net>
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
Co-authored-by: LINKIWI <LINKIWI@users.noreply.github.com>
Co-authored-by: Cgol9 <chris.golling@verizon.net>
Co-authored-by: Christopher Golling <Chris.Golling@aexp.com>
Co-authored-by: Shawn Wang <62313353+shawnwgit@users.noreply.github.com>
Co-authored-by: ZhuHaiCheng <zhuhai@52it.net>
Co-authored-by: herodot <54836727+bitsark@users.noreply.github.com>
Co-authored-by: Vladyslav Vildanov <117659936+vladvildanov@users.noreply.github.com>
* 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 <104765379+ofekshenawa@users.noreply.github.com>
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 <nic.gibson@redis.com>
* run go fix ./...
Signed-off-by: Tiago Peczenyj <tpeczenyj@weborama.com>
* run make fmt
Signed-off-by: Tiago Peczenyj <tpeczenyj@weborama.com>
* 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 <tpeczenyj@weborama.com>
---------
Signed-off-by: Tiago Peczenyj <tpeczenyj@weborama.com>
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
* 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 <70265851+Anuragkillswitch@users.noreply.github.com>
Co-authored-by: ofekshenawa <104765379+ofekshenawa@users.noreply.github.com>
* fix: In the response of the XInfoStreamFull command, the "entries-read" field may be nil
Signed-off-by: monkey92t <golang@88.com>
* add XInfoStreamFull test
Signed-off-by: monkey92t <golang@88.com>
* add test XInfoStreamFull entries_read = nil
Signed-off-by: monkey92t <golang@88.com>
---------
Signed-off-by: monkey92t <golang@88.com>
* 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 <golang@88.com>
* fix: Adding error case test
* fix: adding correct error message
* fix: removed blank lines
---------
Signed-off-by: monkey92t <golang@88.com>
Co-authored-by: Anuragkillswitch <70265851+Anuragkillswitch@users.noreply.github.com>
Co-authored-by: monkey92t <golang@88.com>
* 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 <golang@88.com>
---------
Signed-off-by: monkey92t <golang@88.com>
Co-authored-by: monkey92t <golang@88.com>