Closed Aeosoul closed 4 years ago
`package main
import ( "log" "time"
"github.com/micro/go-micro/v2" "github.com/micro/go-plugins/registry/etcdv3"
)
func main() { registre := etcdv3.NewRegistry()
service := micro.NewService( micro.Registry(registre), micro.Name("greeter"), micro.RegisterTTL(time.Second*30), micro.RegisterInterval(time.Second*15), ) service.Init() if err := service.Run(); err != nil { log.Fatal(err) }
} ` windows上运行 错误信息: D:\Golang\project\demo\src\AlarmService\etcdtest> go run .\main.go --registry=etcdv3 --registry_address=127.0.0.1:2379
....\github.com\go-git\go-git\v5\plumbing\transport\ssh\common.go:147:15: undefined: proxy.Dial
已解决
`package main
import ( "log" "time"
)
func main() { registre := etcdv3.NewRegistry()
} ` windows上运行 错误信息: D:\Golang\project\demo\src\AlarmService\etcdtest> go run .\main.go --registry=etcdv3 --registry_address=127.0.0.1:2379
github.com/go-git/go-git/v5/plumbing/transport/ssh
....\github.com\go-git\go-git\v5\plumbing\transport\ssh\common.go:147:15: undefined: proxy.Dial