1
0
mirror of https://github.com/go-micro/go-micro.git synced 2024-12-06 08:16:03 +02:00
go-micro/examples/http
2021-04-08 18:31:15 +01:00
..
cli add http demo; http client can call http server; http client can call rpc server (#2149) 2021-04-08 18:31:15 +01:00
rpccli add http demo; http client can call http server; http client can call rpc server (#2149) 2021-04-08 18:31:15 +01:00
srv add http demo; http client can call http server; http client can call rpc server (#2149) 2021-04-08 18:31:15 +01:00
README.md add http demo; http client can call http server; http client can call rpc server (#2149) 2021-04-08 18:31:15 +01:00

http server and http client demo

An example http application

Contents

  • srv - a http server as server of go-mirco service
  • cli - a http client that call http server
  • rpcli - a http client that call rpc server

Run Service

Start http server

go run srv/main.go

Client

Call http client

go run cli/main.go

Run rpc Service

Start greeter service

go run ../greeter/srv/main.go

Client

http client call rpc service

go run rpccli/main.go