Configure golang-micro development environment

Configure golang-micro development environment

Solve the problem that some packages cannot be downloaded by the wall

Go directly to GitHub to download the source code and put it in the corresponding directory

src/google.golang.org

  1. genproto
https://codeload.github.com/juelite/google.golang.org-genproto/zip/master
 
  1. grpc
https://github.com/grpc/grpc-go
 

src/golang.org.x

  1. net
https://godoc.org/golang.org/x/net
 
  1. text
https://godoc.org/golang.org/x/text
 

src/github.com/golang

  1. protobuf
https://github.com/golang/protobuf
 

Protocol Compiler Installation

For non-C++ users, the easiest way to install the protocol compiler is to download the pre-built binary file from the following page, then unzip it, and add the bin path to the environment variable path:

download link:

https://github.com/protocolbuffers/protobuf/releases
 

(1) Windows: Enter system properties -> environment variables -> system variables -> path parameter and add F:\protobuf\bin

(2) linux: Unzip under the GOPATH path, get the absolute path, and add the path parameter.

export PATH=$PATH:$GOPATH/protoc/bin 
 

test

Test the example, open the client and server sides

This completes the installation and deployment of golang-micro, as well as filling the hole. .