Move context to metadata

This commit is contained in:
Asim
2016-01-28 17:55:28 +00:00
parent cd9801891e
commit 9ae0956cea
13 changed files with 60 additions and 60 deletions

View File

@@ -5,8 +5,8 @@ import (
"github.com/micro/go-micro/client"
"github.com/micro/go-micro/cmd"
c "github.com/micro/go-micro/context"
example "github.com/micro/go-micro/examples/server/proto/example"
"github.com/micro/go-micro/metadata"
"golang.org/x/net/context"
)
@@ -17,7 +17,7 @@ func pub(i int) {
})
// create context with metadata
ctx := c.WithMetadata(context.Background(), map[string]string{
ctx := metadata.NewContext(context.Background(), map[string]string{
"X-User-Id": "john",
"X-From-Id": "script",
})