etcd 报错及解决
go build 时报错:go: go.etcd.io/bbolt@v1.3.5 used for two different module paths (github.com/coreos/bbolt and go.etcd.io/bbolt)
报错时 go.mod 配置:
replace (
github.com/coreos/bbolt => go.etcd.io/bbolt v1.3.5
google.golang.org/grpc => google.golang.org/grpc v1.26.0
)
解决方法:go.etcd.io/bbolt 的版本 v1.3.5,变成:v1.3.6
replace (
github.com/coreos/bbolt => go.etcd.io/bbolt v1.3.6
google.golang.org/grpc => google.golang.org/grpc v1.26.0
)
参考:https://github.com/etcd-io/etcd/issues/11749#issuecomment-1065146905