mirror of
https://github.com/go-micro/go-micro.git
synced 2025-08-04 21:42:57 +02:00
Update README.md
This commit is contained in:
14
README.md
14
README.md
@@ -75,14 +75,16 @@ func (h *Say) Hello(ctx context.Context, req *Request, rsp *Response) error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// create the service
|
func main() {
|
||||||
service := micro.New("helloworld")
|
// create the service
|
||||||
|
service := micro.New("helloworld")
|
||||||
|
|
||||||
// register handler
|
// register handler
|
||||||
service.Handle(new(Say))
|
service.Handle(new(Say))
|
||||||
|
|
||||||
// run the service
|
// run the service
|
||||||
service.Run()
|
service.Run()
|
||||||
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
Optionally set fixed address
|
Optionally set fixed address
|
||||||
|
Reference in New Issue
Block a user