MCPcopy
hub / github.com/CodisLabs/codis

github.com/CodisLabs/codis @3.2.2 sqlite

repository ↗ · DeepWiki ↗ · release 3.2.2 ↗
1,380 symbols 4,953 edges 131 files 0 documented · 0%
README

Gitter Build Status

Codis is a proxy based high performance Redis cluster solution written in Go. It is production-ready and widely used at wandoujia.com and many companies. You can see Codis Releases for latest and most stable realeases.

Donation

Donate if you want to help us maintaining this project. Thank you! See this issue for details

Compared with Twemproxy and Redis Cluster

CodisTwemproxyRedis Cluster
resharding without restarting clusterYesNoYes
pipelineYesYesNo
hash tags for multi-key operationsYesYesYes
multi-key operations while reshardingYes-No(details)
Redis clients supportingAny clientsAny clientsClients have to support cluster protocol

"Resharding" means migrating the data in one slot from one redis server to another, usually happens while increasing/decreasing the number of redis servers.

Other Features

  • GUI website dashboard & admin tools
  • Supports most of Redis commands, Fully compatible with Twemproxy(https://github.com/twitter/twemproxy)
  • Proxies can register on zk/etcd, clients can avoid dead proxies, see "High Availability" section.

Tutorial

简体中文 English (WIP)

FAQ

简体中文 English (WIP)

High Availability

简体中文 English (WIP)

Architecture

architecture

Snapshots

Proxy proxy

Slots slots

Group group

Sentinel sentinel

Benchmarks

See benchmark results

Authors

Active authors: * @spinlock9 微博@斯宾洛克 * @yangzhe1991 微博@_杨肉_

Emeritus authors: * @goroutine 微博@goroutine * @c4pt0r 微博@Dongxu_Huang

Thanks: * @ivanzhaowy * @Apache9 微博@Apache9

License

Codis is licensed under MIT, see MIT-LICENSE.txt


You are welcome to use Codis in your product, and feel free to let us know~ :)

Extension points exported contracts — how you extend this code

TestCase (Interface)
(no doc) [15 implementers]
extern/deprecated/redis-test/utils.go
ConfigLoader (Interface)
(no doc) [5 implementers]
cmd/fe/main.go
Client (Interface)
(no doc) [3 implementers]
pkg/models/client.go
Slice (Interface)
(no doc) [2 implementers]
pkg/utils/unsafe2/slice.go
Delay (Interface)
(no doc) [1 implementers]
pkg/proxy/delay.go

Core symbols most depended-on inside this repo

Debugf
called by 168
pkg/utils/log/log.go
Warnf
called by 125
pkg/utils/log/log.go
Errorf
called by 124
pkg/utils/log/log.go
Close
called by 117
pkg/models/client.go
PanicErrorf
called by 114
pkg/utils/log/log.go
WarnErrorf
called by 56
pkg/utils/log/log.go
Panicf
called by 48
pkg/utils/log/log.go
Do
called by 47
pkg/utils/redis/client.go

Shape

Method 818
Function 415
Struct 107
Class 18
TypeAlias 16
Interface 6

Languages

Go94%
Python5%
TypeScript1%

Modules by API surface

pkg/topom/topom_api.go85 symbols
pkg/utils/log/log.go76 symbols
extern/deprecated/redis-test/utils.go54 symbols
pkg/models/store.go39 symbols
pkg/proxy/proxy_api.go36 symbols
pkg/utils/redis/client.go35 symbols
pkg/utils/redis/sentinel.go31 symbols
pkg/proxy/proxy.go30 symbols
pkg/proxy/backend.go28 symbols
pkg/proxy/session.go27 symbols
pkg/proxy/stats.go24 symbols
pkg/utils/bufio2/bufio.go22 symbols

Dependencies from manifests, versioned

angular1.4.8 · 1×
angular-ui-bootstrap0.14.3 · 1×
bootstrap3.3.6 · 1×
bootstrap-dialog1.34.6 · 1×
highcharts4.1.10 · 1×
highcharts-ng0.0.11 · 1×
jquery2.1.4 · 1×
sha2560.2.0 · 1×

For agents

$ claude mcp add codis \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact