https://github.com/ctripcorp/crdt-module
https://github.com/ctripcorp/crdt-module
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/ctripcorp/crdt-module
- Owner: ctripcorp
- Created: 2019-11-13T07:03:52.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-07-08T06:35:33.000Z (almost 2 years ago)
- Last Synced: 2025-07-04T16:21:17.261Z (11 months ago)
- Language: C
- Size: 4.01 MB
- Stars: 9
- Watchers: 11
- Forks: 3
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## How to
### Set up
#### at startup
`redis-server <$conf-file> --loadmodule /crdt.so`
#### already started
`redis-cli module load /crdt.so`
### Use
`redis-cli set key val`
`redis-cli get key`
`redis-cli crdt.get key`
## Develop
### Mem Alloc/Free
- For temporary used mem/struct, using `Redis Module's` auto memory alloc.
- For permanent used mem/struct, pass a flag to tell function whether to copy or take directly
### Mem Leak Check
``` makefile
make distclean
make OPTIMIZATION=-O0 MALLOC=libc
tclsh8.5 tests/test_crdt.tcl --valgrind --clients 1
```