mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 10:33:35 +00:00
rebase: bump google.golang.org/grpc from 1.46.2 to 1.47.0
Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.46.2 to 1.47.0. - [Release notes](https://github.com/grpc/grpc-go/releases) - [Commits](https://github.com/grpc/grpc-go/compare/v1.46.2...v1.47.0) --- updated-dependencies: - dependency-name: google.golang.org/grpc dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
8d3bb82949
commit
b6d03d2912
40
vendor/google.golang.org/grpc/server.go
generated
vendored
40
vendor/google.golang.org/grpc/server.go
generated
vendored
@ -1801,12 +1801,26 @@ func (s *Server) getCodec(contentSubtype string) baseCodec {
|
||||
return codec
|
||||
}
|
||||
|
||||
// SetHeader sets the header metadata.
|
||||
// When called multiple times, all the provided metadata will be merged.
|
||||
// All the metadata will be sent out when one of the following happens:
|
||||
// - grpc.SendHeader() is called;
|
||||
// - The first response is sent out;
|
||||
// - An RPC status is sent out (error or success).
|
||||
// SetHeader sets the header metadata to be sent from the server to the client.
|
||||
// The context provided must be the context passed to the server's handler.
|
||||
//
|
||||
// Streaming RPCs should prefer the SetHeader method of the ServerStream.
|
||||
//
|
||||
// When called multiple times, all the provided metadata will be merged. All
|
||||
// the metadata will be sent out when one of the following happens:
|
||||
//
|
||||
// - grpc.SendHeader is called, or for streaming handlers, stream.SendHeader.
|
||||
// - The first response message is sent. For unary handlers, this occurs when
|
||||
// the handler returns; for streaming handlers, this can happen when stream's
|
||||
// SendMsg method is called.
|
||||
// - An RPC status is sent out (error or success). This occurs when the handler
|
||||
// returns.
|
||||
//
|
||||
// SetHeader will fail if called after any of the events above.
|
||||
//
|
||||
// The error returned is compatible with the status package. However, the
|
||||
// status code will often not match the RPC status as seen by the client
|
||||
// application, and therefore, should not be relied upon for this purpose.
|
||||
func SetHeader(ctx context.Context, md metadata.MD) error {
|
||||
if md.Len() == 0 {
|
||||
return nil
|
||||
@ -1818,8 +1832,14 @@ func SetHeader(ctx context.Context, md metadata.MD) error {
|
||||
return stream.SetHeader(md)
|
||||
}
|
||||
|
||||
// SendHeader sends header metadata. It may be called at most once.
|
||||
// The provided md and headers set by SetHeader() will be sent.
|
||||
// SendHeader sends header metadata. It may be called at most once, and may not
|
||||
// be called after any event that causes headers to be sent (see SetHeader for
|
||||
// a complete list). The provided md and headers set by SetHeader() will be
|
||||
// sent.
|
||||
//
|
||||
// The error returned is compatible with the status package. However, the
|
||||
// status code will often not match the RPC status as seen by the client
|
||||
// application, and therefore, should not be relied upon for this purpose.
|
||||
func SendHeader(ctx context.Context, md metadata.MD) error {
|
||||
stream := ServerTransportStreamFromContext(ctx)
|
||||
if stream == nil {
|
||||
@ -1833,6 +1853,10 @@ func SendHeader(ctx context.Context, md metadata.MD) error {
|
||||
|
||||
// SetTrailer sets the trailer metadata that will be sent when an RPC returns.
|
||||
// When called more than once, all the provided metadata will be merged.
|
||||
//
|
||||
// The error returned is compatible with the status package. However, the
|
||||
// status code will often not match the RPC status as seen by the client
|
||||
// application, and therefore, should not be relied upon for this purpose.
|
||||
func SetTrailer(ctx context.Context, md metadata.MD) error {
|
||||
if md.Len() == 0 {
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user