Skip to content

Commit

Permalink
UPSTREAM: 74956: apiserver: switch authorization to use protobuf client
Browse files Browse the repository at this point in the history
  • Loading branch information
mfojtik authored and soltysh committed Sep 7, 2021
1 parent 14f549a commit e1876f9
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -219,5 +219,10 @@ func (s *DelegatingAuthorizationOptions) getClient() (kubernetes.Interface, erro
clientConfig.Burst = 400
clientConfig.Timeout = s.ClientTimeout

return kubernetes.NewForConfig(clientConfig)
// make the client use protobuf
protoConfig := rest.CopyConfig(clientConfig)
protoConfig.AcceptContentTypes = "application/vnd.kubernetes.protobuf,application/json"
protoConfig.ContentType = "application/vnd.kubernetes.protobuf"

return kubernetes.NewForConfig(protoConfig)
}

0 comments on commit e1876f9

Please sign in to comment.