https://github.com/einar-hjortdal/redis
a library for V programs to connect and interface with Redis-compatible databases
https://github.com/einar-hjortdal/redis
Last synced: about 1 year ago
JSON representation
a library for V programs to connect and interface with Redis-compatible databases
- Host: GitHub
- URL: https://github.com/einar-hjortdal/redis
- Owner: einar-hjortdal
- License: ncsa
- Archived: true
- Created: 2023-06-16T14:44:47.000Z (almost 3 years ago)
- Default Branch: pending
- Last Pushed: 2024-09-20T14:52:00.000Z (over 1 year ago)
- Last Synced: 2024-11-18T21:46:52.388Z (over 1 year ago)
- Language: V
- Homepage:
- Size: 68.4 KB
- Stars: 7
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-v - redis - Connect and interface with Redis-compatible databases. (Libraries / Database clients)
README
| :warning: WARNING |
|:----------------------------|
| Because of the change in license of Redis, I have moved to [Redict](https://redict.io/). I have forked this project [here](https://github.com/einar-hjortdal/redict). |
# redis
Redis library for the V language.
## Features
- RESP version 3 only
- [Commands](src/cmdable.v)
- Aumtomatic connection pool
## Usage
Install with `v install Coachonko.redis`
```V
import coachonko.redis
// Configure.
mut ro := redis.Options{
// refer to the options.v file
}
// Create a new client.
client := new_client(mut opts)
// Issue commands as Client methods.
// Supported commands are listed in the `cmdable.v` file.
mut result := client.set('test_key', 'test_value', 0)!
// Get the value from results
result = client.get('test_key')!
println(result.val())
```
## Notes
This library is developed against [Redict](https://redict.io/).
Pull requests are very welcome. Please look at [CONTRIBUTING.md](./CONTRIBUTING.md) and at [TODO.md](./TODO.md)
files. Open issues for problems you encounter, reach out to me and the other contributors on [V's Discord](https://discord.gg/vlang).