mirror of https://github.com/grpc/grpc-go.git
grpc: add a warning for unsupported codec (#6658)
This commit is contained in:
parent
3e9b85c6a9
commit
2cf5619c4d
|
@ -1913,6 +1913,7 @@ func (s *Server) getCodec(contentSubtype string) baseCodec {
|
|||
}
|
||||
codec := encoding.GetCodec(contentSubtype)
|
||||
if codec == nil {
|
||||
logger.Warningf("Unsupported codec %q. Defaulting to %q for now. This will start to fail in future releases.", contentSubtype, proto.Name)
|
||||
return encoding.GetCodec(proto.Name)
|
||||
}
|
||||
return codec
|
||||
|
|
Loading…
Reference in New Issue