In grpc-go, when implementing a service, the service interface defines methods contains only Context
and Request
. From the source of the Context
, it is as simple as
type Context interface {
Deadline() (deadline time.Time, ok bool)
Done() <-chan struct{}
Err() error
Value(key interface{}) interface{}
}
So I wonder if it is possible to get some metadata (including remote IP address and other data) to maintain a session.
Thanks.