foo test service
This commit is contained in:
20
services/foo/subscriber/foo.go
Normal file
20
services/foo/subscriber/foo.go
Normal file
@ -0,0 +1,20 @@
|
||||
package subscriber
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/micro/go-micro/util/log"
|
||||
|
||||
foo "foo/proto/foo"
|
||||
)
|
||||
|
||||
type Foo struct{}
|
||||
|
||||
func (e *Foo) Handle(ctx context.Context, msg *foo.Message) error {
|
||||
log.Log("Handler Received message: ", msg.Say)
|
||||
return nil
|
||||
}
|
||||
|
||||
func Handler(ctx context.Context, msg *foo.Message) error {
|
||||
log.Log("Function Received message: ", msg.Say)
|
||||
return nil
|
||||
}
|
Reference in New Issue
Block a user