Skip to content
Snippets Groups Projects
Commit dc53cee1 authored by panty's avatar panty Committed by GitHub
Browse files

Merge pull request #398 from pantianying/user_add_attachment

user can add attachment
parents fd4b2977 d6977bc4
No related branches found
No related tags found
No related merge requests found
......@@ -140,6 +140,14 @@ func (p *Proxy) Implement(v common.RPCService) {
inv.SetAttachments(k, value)
}
// add user setAttachment
atm := invCtx.Value("attachment")
if m, ok := atm.(map[string]string); ok {
for k, value := range m {
inv.SetAttachments(k, value)
}
}
result := p.invoke.Invoke(invCtx, inv)
err = result.Error()
......
......@@ -17,9 +17,11 @@
package config
import "context"
// GenericService ...
type GenericService struct {
Invoke func(req []interface{}) (interface{}, error) `dubbo:"$invoke"`
Invoke func(ctx context.Context, req []interface{}) (interface{}, error) `dubbo:"$invoke"`
referenceStr string
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment