Since protoc can be a bit confusing, let be explain
-I <path> tells the compile where to search for the imported file, In my example I have placed them in $HOME/googleapis. You can download these files here. The annotations.proto file is needed in order to describe HTTP routes for the Methods of the Service.
--proto_path=<path> tells the compile where to look for the proto file. If you run this command inside the example/ dir, the path should be ., this flag is required because protoc will otherwise look inside the -I directory.
--go_out and --go-grpc_out invokes the the protoc-gen-go and protoc-gen-go-grpc plugins.
go_out=pahts=<path> and --go-grpc_opt=paths=<path> adds some necessary flags for the go and grpc plugins.