initial import

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
2021-01-13 09:06:45 +03:00
commit d439d06eaa
20 changed files with 1545 additions and 0 deletions

20
options.go Normal file
View File

@@ -0,0 +1,20 @@
package service
import (
"github.com/unistack-org/micro/v3/client"
"github.com/unistack-org/micro/v3/config"
)
type clientKey struct{}
// Client to call config service
func Client(c client.Client) config.Option {
return config.SetOption(clientKey{}, c)
}
type serviceKey struct{}
// Service to which data load
func Service(s string) config.Option {
return config.SetOption(serviceKey{}, s)
}