Open zhengxiaochuan-3 opened 7 years ago
I just ran across the same issue. I think this library might need to be updated to work with newer versions of Go?
@tylertreat right, it violates cgo pointer rules rules, which have always been there but now have runtime checks in Go 1.8.
Can upstream make a comment on this? It seems this bug pretty much makes the lmdb backend for the raft package unusable with Go 1.8 (and the lmdb backend is the recommended one).
FWIW, it looks like Consul uses https://github.com/hashicorp/raft-boltdb for its Raft backend, so I wonder if that is the "recommended" one now.
@tylertreat if it's not anymore, I'd say the raft README should be updated:
"To prevent complications with cgo, the primary backend MDBStore is in a separate repository, called raft-mdb. That is the recommended implementation for the LogStore and StableStore."
go version: [root@node-65-76 nvme]# go version go version go1.8.1 linux/amd64