redix
is a key-value datastore with pluggable storage engines and redis protocol as interface, documentation & learn more
You're welcome!
a very simple pure key => value storage system that speaks Redis protocol with Postgres as storage engine and more
Home Page: https://redix.alash3al.com/
redix
is a key-value datastore with pluggable storage engines and redis protocol as interface, documentation & learn more
You're welcome!
It is documented in BadgerDB user code should periodically call methods for database compaction. Otherwise it will grow indefinitely. And I don't see your code calls those methods.
Thank you for the project!
Hello, tell me what is the status of the project
As per #42 (comment)
conversation about recreating features from v1
this webhook command is still needed, with ability to set headers for auth if possible
will you gave a overview of the storing solution other than let us read the f** code :]
I download the release https://github.com/alash3al/redix/releases/download/v1.8/redix_linux_amd64.zip and when i run it, i have the message ⇨ redix server version: 1.7
.
Should'nt it be 1.8 ?
expire abc 30
unknown commands [expire]
Can the redis instructions be fully compatible?
I know that you have stated it is not the intention of redix to replicate all of redis' commands however when testing it with various apps, in the current state I'm coming up against lots of errors about commands not available.
sometimes it is even a case of the app only needing basic key/value features but I am not able to use Redix because HELLO was not available.
Thank you for the great project!
I am struggling with KEYS & SCAN commands using latest Docker Image. Please take a look at logs, other commands (i.e. EXISTS) works fine:
127.0.0.1:6380> KEYS *
(error) unknown commands [keys]
127.0.0.1:6380> SCAN
(error) unknown commands [scan]
127.0.0.1:6380> EXISTS
(error) EXISTS command must have at least 1 argument: EXISTS <key>
➜ redix ./redix_darwin_amd64 -engine badger
Invalid strorage engine specified
version: redix server version: 1.10
os: macos
the release 1.8 version label show error in cli
redix server version: 1.7
MacBookPro 2018 16G Mem 512G ssd
redis-benchmark -n 1000000 -t set,get -P 16 -p 6380 -q SET: 323519.88 requests per second GET: 1078748.62 requests per second
very good
Originally posted by @withu2018 in https://github.com/alash3al/redix/issue_comments#issuecomment-451419162
Hi Mohammed Al Ashaal,
I wanted to thank you for writing this awesome layer over Badger KV store! Is it possible to have an optional config file? I would like to create .deb and .rpm packages for this great tool so people can easily install and upgrade it.
Thanks again for building this!
How can I standup 2 of these and have them stay in sync ?
Wondering if redcon would help ?
Hi I am actually still keen on using version 1 of this repo which had some very useful features, but it seems that branch is no longer available?
Is it possible to keep that version available somewhere else?
I noted that docker pull alash3al/redix
does pull the old version and so docker pull ghcr.io/alash3al/redix
is needed for v5
I have read that all redis commands are not implemented but i really miss the TTL one.
(Great job, thanks).
when i run command bellow in termnal :
lrange f10.data.4:600030 0 0
it return "(error) invalid offset specified"
is there any example or document for this command.
I use "predis/predis": "^1.1"
with PHP and redix as an IP rate limiter.
Today my server sent ERROR 500, but redix was still alive. So i looked at the web server error log. Here is what I got :
www[5]: PHP Fatal error:
Uncaught Predis\Response\ServerException: db error:
open redix-data/level/0/CURRENT:
too many open files in /flex/storage/xxx/php/vendor/predis/predis/src/Client.php:370
#012
Stack trace:
#012#0
/flex/storage/xxx/php/vendor/predis/predis/src/Client.php(335):
Predis\Client->onErrorResponse(Object(Predis\Command\KeyTimeToLive),
Object(Predis\Response\Error))
#012#1
/flex/storage/xxx/php/vendor/predis/predis/src/Client.php(314):
Predis\Client->executeCommand(Object(Predis\Command\KeyTimeToLive))
#012#2
/flex/storage/xxx/php/myapp/class.ratelimit.redix.php(72):
Predis\Client->__call('ttl', Array)
#012#3
/flex/storage/xxx/php/myapp/script.php(61):
RateLimit->getSleepTime($ipaddr)
#012#4
{main}
#012
thrown in /flex/storage/xxx/php/vendor/predis/predis/src/Client.php on line 370
To solve the issue, I stopped redix, then I did rm -rf redix-data
and started it again.
I'm not sure about what was wrong here. If it helps.
Could you upgrade dependency to newer version (BadgerDB v3.2011.1) ?
when using the official redis go-redis client to try and use pubsub I keep getting an error from this line:
https://github.com/redis/go-redis/blob/84706fbcef7646495eecc6bff22f952114459f1c/pubsub.go#L168
the error message takes the following form:
redis: 2023/06/01 xx:xx:xx pubsub.go:168: redis discarding bad PubSub connection: redis: ping timeout
go get github.com/alash3al/redix
/go/src/github.com/google/flatbuffers/go/builder.go:14:14: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:15:12: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:16:14: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:17:12: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:21:27: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:114:36: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:203:31: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:234:26: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:239:28: undefined: UOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:275:39: undefined: SOffsetT
/go/src/github.com/google/flatbuffers/go/builder.go:275:39: too many errors
Hi, lot of thanks about your work!
I try to use redix with NodeJS app and using popular client module, node_redis. But his architecture needed to use INFO command when obtain client connection. And we cant used it with Redix:
Redix error!
{ ReplyError: Ready check failed: unknown commands [info]
at parseError (/opt/tendermint/app/node_modules/redis-parser/lib/parser.js:193:12)
at parseType (/opt/tendermint/app/node_modules/redis-parser/lib/parser.js:303:14) command: 'INFO' }
Can you add this command with base support of redis-compartability?
docker pull ghcr.io/alash3al/redix ✘ 15:19:47
Using default tag: latest
Error response from daemon: unauthorized
maybe make it publicly readable?
Hi there!
It looks like the Docker build is not working
I tried adding gcc, musl-dev and linux-headers to make the compilation work without luck.
Sending build context to Docker daemon 2.048kB
Step 1/6 : FROM golang:alpine
---> 3289bf11c284
Step 2/6 : RUN apk update && apk add git gcc musl-dev linux-headers
---> Running in 33a80f6ba5fe
fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/community/x86_64/APKINDEX.tar.gz
v3.12.0-138-g44b5946805 [http://dl-cdn.alpinelinux.org/alpine/v3.12/main]
v3.12.0-139-gd0df61068e [http://dl-cdn.alpinelinux.org/alpine/v3.12/community]
OK: 12748 distinct packages available
(1/19) Upgrading musl (1.1.24-r8 -> 1.1.24-r9)
(2/19) Installing libgcc (9.3.0-r2)
(3/19) Installing libstdc++ (9.3.0-r2)
(4/19) Installing binutils (2.34-r1)
(5/19) Installing gmp (6.2.0-r0)
(6/19) Installing isl (0.18-r0)
(7/19) Installing libgomp (9.3.0-r2)
(8/19) Installing libatomic (9.3.0-r2)
(9/19) Installing libgphobos (9.3.0-r2)
(10/19) Installing mpfr4 (4.0.2-r4)
(11/19) Installing mpc1 (1.1.0-r1)
(12/19) Installing gcc (9.3.0-r2)
(13/19) Installing nghttp2-libs (1.41.0-r0)
(14/19) Installing libcurl (7.69.1-r0)
(15/19) Installing expat (2.2.9-r1)
(16/19) Installing pcre2 (10.35-r0)
(17/19) Installing git (2.26.2-r0)
(18/19) Installing linux-headers (5.4.5-r1)
(19/19) Installing musl-dev (1.1.24-r9)
Executing busybox-1.31.1-r16.trigger
OK: 163 MiB in 33 packages
Removing intermediate container 33a80f6ba5fe
---> 6f76eb594f3d
Step 3/6 : RUN go get github.com/alash3al/redix
---> Running in 7d87ffcfc82f
# github.com/alash3al/redix/kvstore/badgerdb
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:29:6: opts.Dir undefined (type func(string) badger.Options has no field or method Dir)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:30:6: opts.ValueDir undefined (type func(string) badger.Options has no field or method ValueDir)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:31:6: opts.Truncate undefined (type func(string) badger.Options has no field or method Truncate)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:32:6: opts.SyncWrites undefined (type func(string) badger.Options has no field or method SyncWrites)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:33:6: opts.TableLoadingMode undefined (type func(string) badger.Options has no field or method TableLoadingMode)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:34:6: opts.ValueLogLoadingMode undefined (type func(string) badger.Options has no field or method ValueLogLoadingMode)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:35:6: opts.NumMemtables undefined (type func(string) badger.Options has no field or method NumMemtables)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:36:6: opts.MaxTableSize undefined (type func(string) badger.Options has no field or method MaxTableSize)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:37:6: opts.NumLevelZeroTables undefined (type func(string) badger.Options has no field or method NumLevelZeroTables)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:38:6: opts.ValueThreshold undefined (type func(string) badger.Options has no field or method ValueThreshold)
src/github.com/alash3al/redix/kvstore/badgerdb/badgerdb.go:38:6: too many errors
After reviewing the code, I wasn't able to find any unit or integration tests. Are there plans to add them? It's a compelling project, though personally it's hard to see it as production ready without tests.
when trying to connect to redix with the redis-tui client it shows there are missing commands info
and scan
Err unknown command info
Err unknown command scan
this feature request is low-priority as the normal redis cli and keydb-cli binaries do work.
during regular set/get:
panic: FATAL: terminating connection due to idle-session timeout (SQLSTATE 57P05)
panic: FATAL: Terminated long-running connection (SQLSTATE 57000)
during pub/sub:
(error) ERR database::notification::err FATAL: terminating connection due to idle-session timeout (SQLSTATE 57P05)
above sql error codes are received when redix is left idle for about 5-10 minutes and then a new command issued.
I think the default expected behaviour would be that it would naturally maintain the connection unless there was a config setting which you could determine how long to wait in idle before disconnecting.
tested with the stand-alone binary, not within a docker container.
When I run go build
in the project, it raises errors:
# github.com/alash3al/redix/kvstore/bolt
kvstore/bolt/bolt.go:13:2: imported and not used: "go.etcd.io/bbolt" as bolt
kvstore/bolt/bolt.go:18:17: undefined: bbolt
# github.com/alash3al/redix
./commands_utils.go:23:10: assignment mismatch: 2 variables but 1 values
./init.go:27:3: undefined: "github.com/dgraph-io/badger".SetLogger
So looks like we have 3 issues here:
go.etcd.io/bbolt
imported as bolt(defined in the package), but never used. Considering kvstore/bolt/bolt.go package is also named bolt, we rename it to 'bbolt'satori/go.uuid
v1.2.0 uuid.NewV4()
returns only one valuedgraph-io/badger
v1.5.4 does not contains the method SetLogger, remove it.redis-benchmark -n 1000000 -t set,get -P 16 -q
Intel(R) Xeon(R) CPU E5-2682 v4 @ 2.50GHz 2 Core
4G RAM
SSDB Disk
redis-5.0.3
SET: 548245.62 requests per second
GET: 671140.94 requests per second
redix V1.7
SET: 6992.27 requests per second
GET: 188323.92 requests per second
redix V1.8 (use leveldb -engine=level)
SET: 166334.00 requests per second
GET: 280190.53 requests per second
ssdb 1.9.7
SET: 34694.52 requests per second
GET: 35812.77 requests per second
How to set password connection ?
Example:
./redix_linux_amd64 -password
Thank you for your support
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.