Move memory to gossip since that's what it is

This commit is contained in:
Asim
2016-05-06 19:56:02 +01:00
committed by Vasiliy Tolstov
commit 0c6951b47e
4 changed files with 635 additions and 0 deletions

15
options.go Normal file
View File

@@ -0,0 +1,15 @@
package gossip
import (
"github.com/micro/go-micro/registry"
"golang.org/x/net/context"
)
type contextSecretKey struct{}
func SecretKey(k []byte) registry.Option {
return func(o *registry.Options) {
o.Context = context.WithValue(o.Context, contextSecretKey{}, k)
}
}