update metadata

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
2020-11-18 13:08:50 +03:00
parent 7d3dc63ae4
commit 3fc7db17c3
5 changed files with 27 additions and 36 deletions

View File

@@ -1,12 +1,15 @@
package http
import "github.com/unistack-org/micro/v3/codec"
import (
"github.com/unistack-org/micro/v3/codec"
"github.com/unistack-org/micro/v3/metadata"
)
type httpMessage struct {
topic string
payload interface{}
contentType string
header map[string]string
header metadata.Metadata
body []byte
codec codec.Reader
}
@@ -23,7 +26,7 @@ func (r *httpMessage) ContentType() string {
return r.contentType
}
func (r *httpMessage) Header() map[string]string {
func (r *httpMessage) Header() metadata.Metadata {
return r.header
}