drop AuthTLS option and use client TLSConfig option
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
11
options.go
11
options.go
@@ -3,7 +3,6 @@ package grpc
|
||||
|
||||
import (
|
||||
"context"
|
||||
"crypto/tls"
|
||||
|
||||
"github.com/unistack-org/micro/v3/client"
|
||||
"google.golang.org/grpc"
|
||||
@@ -72,16 +71,6 @@ func Codec(contentType string, c encoding.Codec) client.Option {
|
||||
}
|
||||
}
|
||||
|
||||
// AuthTLS should be used to setup a secure authentication using TLS
|
||||
func AuthTLS(t *tls.Config) client.Option {
|
||||
return func(o *client.Options) {
|
||||
if o.Context == nil {
|
||||
o.Context = context.Background()
|
||||
}
|
||||
o.Context = context.WithValue(o.Context, tlsAuth{}, t)
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// MaxRecvMsgSize set the maximum size of message that client can receive.
|
||||
//
|
||||
|
Reference in New Issue
Block a user