README ¶ etcd go连接etcd示例 安装etcd的官方文档https://etcd.io/docs/v3.2/install/ 下面以Windows下的安装为例,步骤如下: # 下载Windows版etcd安装包,本例中下载的版本为etcd-v3.4.23-windows-amd64.zip https://github.com/etcd-io/etcd/releases/ # 解压etcd压缩包到D:/soft/etcd 转到D:/soft/etcd文件夹下,启动etcd服务 cd D:/soft/etcd etcd.exe 使用etcdctl.exe测试写入和读取 etcdctl.exe --help etcdctl.exe put test hello etcdctl.exe get test # 更新test的命令也很简单,执行下面的命令即可 etcdctl.exe put test hi etcdctl.exe endpoint status -w json | jq 引入etcd的go依赖包 go mod init github.com/fastbpmn/go-study/etcd go get go.etcd.io/etcd/client/v3 如果不习惯使用命令行,可以下载etcd的客户端https://github.com/gtamas/etcdmanager/releases Expand ▾ Collapse ▴ Documentation ¶ There is no documentation for this package. Source Files ¶ View all Source files main.go Click to show internal directories. Click to hide internal directories.