Skip to content

Commit

Permalink
Merge pull request kubernetes#4149 from olagacek/master
Browse files Browse the repository at this point in the history
Allow overriding userAgent in Custom GCE client in gce cloud provider.
  • Loading branch information
k8s-ci-robot committed Jun 17, 2021
2 parents 1b502e0 + 6fd23f9 commit 6e3e05d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -107,13 +107,14 @@ func NewAutoscalingGceClientV1(client *http.Client, projectId string, userAgent

// NewCustomAutoscalingGceClientV1 creates a new client using custom server url and timeouts
// for communicating with GCE v1 API.
func NewCustomAutoscalingGceClientV1(client *http.Client, projectId, serverUrl string,
func NewCustomAutoscalingGceClientV1(client *http.Client, projectId, serverUrl, userAgent string,
waitTimeout, pollInterval time.Duration, deletionPollInterval time.Duration) (*autoscalingGceClientV1, error) {
gceService, err := gce.New(client)
if err != nil {
return nil, err
}
gceService.BasePath = serverUrl
gceService.UserAgent = userAgent

return &autoscalingGceClientV1{
projectId: projectId,
Expand Down

0 comments on commit 6e3e05d

Please sign in to comment.