chore(all): auto-regenerate gapics (#6365)
* chore(all): auto-regenerate gapics
This is an auto-generated regeneration of the gapic clients by
cloud.google.com/go/internal/gapicgen. Once the corresponding genproto PR is
submitted, genbot will update this PR with a newer dependency to the newer
version of genproto and assign reviewers to this PR.
If you have been assigned to review this PR, please:
- Ensure that the version of genproto in go.mod has been updated.
- Ensure that CI is passing. If it's failing, it requires your manual attention.
- Approve and submit this PR if you believe it's ready to ship.
Corresponding genproto PR: https://github.com/googleapis/go-genproto/pull/863
Changes:
feat(vmmigration): Rename product feat: API updates
PiperOrigin-RevId: 461817256
Source-Link: https://github.com/googleapis/googleapis/commit/215f812fbe99bf78290f843d08b8d5c78aa7115d
feat(assuredworkloads): Updated the method signature of analyzeWorkloadMove for v1beta API to accept project as source. AnalyzeWorkloadMove now also returns information about org policy differences between the project and target folder
Committer: @ketanbshah
PiperOrigin-RevId: 461626403
Source-Link: https://github.com/googleapis/googleapis/commit/6aee59cd91487ae5a3cd5a5768a4b42b4587dd25
feat(assuredworkloads): Updated the method signature of analyzeWorkloadMove for v1beta API
PiperOrigin-RevId: 461625367
Source-Link: https://github.com/googleapis/googleapis/commit/d108c5e550ec20c0e24a8b04dc52e76e33022e90
diff --git a/assuredworkloads/apiv1beta1/assured_workloads_client.go b/assuredworkloads/apiv1beta1/assured_workloads_client.go
index 2ebf6c9..f20abe9 100644
--- a/assuredworkloads/apiv1beta1/assured_workloads_client.go
+++ b/assuredworkloads/apiv1beta1/assured_workloads_client.go
@@ -48,11 +48,16 @@
// CallOptions contains the retry settings for each method of Client.
type CallOptions struct {
- CreateWorkload []gax.CallOption
- UpdateWorkload []gax.CallOption
- DeleteWorkload []gax.CallOption
- GetWorkload []gax.CallOption
- ListWorkloads []gax.CallOption
+ CreateWorkload []gax.CallOption
+ UpdateWorkload []gax.CallOption
+ RestrictAllowedServices []gax.CallOption
+ RestrictAllowedResources []gax.CallOption
+ DeleteWorkload []gax.CallOption
+ GetWorkload []gax.CallOption
+ AnalyzeWorkloadMove []gax.CallOption
+ ListWorkloads []gax.CallOption
+ GetOperation []gax.CallOption
+ ListOperations []gax.CallOption
}
func defaultGRPCClientOptions() []option.ClientOption {
@@ -69,8 +74,10 @@
func defaultCallOptions() *CallOptions {
return &CallOptions{
- CreateWorkload: []gax.CallOption{},
- UpdateWorkload: []gax.CallOption{},
+ CreateWorkload: []gax.CallOption{},
+ UpdateWorkload: []gax.CallOption{},
+ RestrictAllowedServices: []gax.CallOption{},
+ RestrictAllowedResources: []gax.CallOption{},
DeleteWorkload: []gax.CallOption{
gax.WithRetry(func() gax.Retryer {
return gax.OnCodes([]codes.Code{
@@ -93,6 +100,17 @@
})
}),
},
+ AnalyzeWorkloadMove: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnCodes([]codes.Code{
+ codes.Unavailable,
+ }, gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ })
+ }),
+ },
ListWorkloads: []gax.CallOption{
gax.WithRetry(func() gax.Retryer {
return gax.OnCodes([]codes.Code{
@@ -104,13 +122,37 @@
})
}),
},
+ GetOperation: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnCodes([]codes.Code{
+ codes.Unavailable,
+ }, gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ })
+ }),
+ },
+ ListOperations: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnCodes([]codes.Code{
+ codes.Unavailable,
+ }, gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ })
+ }),
+ },
}
}
func defaultRESTCallOptions() *CallOptions {
return &CallOptions{
- CreateWorkload: []gax.CallOption{},
- UpdateWorkload: []gax.CallOption{},
+ CreateWorkload: []gax.CallOption{},
+ UpdateWorkload: []gax.CallOption{},
+ RestrictAllowedServices: []gax.CallOption{},
+ RestrictAllowedResources: []gax.CallOption{},
DeleteWorkload: []gax.CallOption{
gax.WithRetry(func() gax.Retryer {
return gax.OnHTTPCodes(gax.Backoff{
@@ -131,6 +173,16 @@
http.StatusServiceUnavailable)
}),
},
+ AnalyzeWorkloadMove: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnHTTPCodes(gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ },
+ http.StatusServiceUnavailable)
+ }),
+ },
ListWorkloads: []gax.CallOption{
gax.WithRetry(func() gax.Retryer {
return gax.OnHTTPCodes(gax.Backoff{
@@ -141,6 +193,26 @@
http.StatusServiceUnavailable)
}),
},
+ GetOperation: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnHTTPCodes(gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ },
+ http.StatusServiceUnavailable)
+ }),
+ },
+ ListOperations: []gax.CallOption{
+ gax.WithRetry(func() gax.Retryer {
+ return gax.OnHTTPCodes(gax.Backoff{
+ Initial: 200 * time.Millisecond,
+ Max: 30000 * time.Millisecond,
+ Multiplier: 1.30,
+ },
+ http.StatusServiceUnavailable)
+ }),
+ },
}
}
@@ -152,9 +224,14 @@
CreateWorkload(context.Context, *assuredworkloadspb.CreateWorkloadRequest, ...gax.CallOption) (*CreateWorkloadOperation, error)
CreateWorkloadOperation(name string) *CreateWorkloadOperation
UpdateWorkload(context.Context, *assuredworkloadspb.UpdateWorkloadRequest, ...gax.CallOption) (*assuredworkloadspb.Workload, error)
+ RestrictAllowedServices(context.Context, *assuredworkloadspb.RestrictAllowedServicesRequest, ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedServicesResponse, error)
+ RestrictAllowedResources(context.Context, *assuredworkloadspb.RestrictAllowedResourcesRequest, ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedResourcesResponse, error)
DeleteWorkload(context.Context, *assuredworkloadspb.DeleteWorkloadRequest, ...gax.CallOption) error
GetWorkload(context.Context, *assuredworkloadspb.GetWorkloadRequest, ...gax.CallOption) (*assuredworkloadspb.Workload, error)
+ AnalyzeWorkloadMove(context.Context, *assuredworkloadspb.AnalyzeWorkloadMoveRequest, ...gax.CallOption) (*assuredworkloadspb.AnalyzeWorkloadMoveResponse, error)
ListWorkloads(context.Context, *assuredworkloadspb.ListWorkloadsRequest, ...gax.CallOption) *WorkloadIterator
+ GetOperation(context.Context, *longrunningpb.GetOperationRequest, ...gax.CallOption) (*longrunningpb.Operation, error)
+ ListOperations(context.Context, *longrunningpb.ListOperationsRequest, ...gax.CallOption) *OperationIterator
}
// Client is a client for interacting with Assured Workloads API.
@@ -215,9 +292,32 @@
return c.internalClient.UpdateWorkload(ctx, req, opts...)
}
+// RestrictAllowedServices restrict the list of services allowed in the Workload environment.
+// The current list of allowed services can be found at
+// https://cloud.google.com/assured-workloads/docs/supported-products (at https://cloud.google.com/assured-workloads/docs/supported-products)
+// In addition to assuredworkloads.workload.update permission, the user should
+// also have orgpolicy.policy.set permission on the folder resource
+// to use this functionality.
+func (c *Client) RestrictAllowedServices(ctx context.Context, req *assuredworkloadspb.RestrictAllowedServicesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedServicesResponse, error) {
+ return c.internalClient.RestrictAllowedServices(ctx, req, opts...)
+}
+
+// RestrictAllowedResources restrict the list of resources allowed in the Workload environment.
+// The current list of allowed products can be found at
+// https://cloud.google.com/assured-workloads/docs/supported-products (at https://cloud.google.com/assured-workloads/docs/supported-products)
+// In addition to assuredworkloads.workload.update permission, the user should
+// also have orgpolicy.policy.set permission on the folder resource
+// to use this functionality.
+func (c *Client) RestrictAllowedResources(ctx context.Context, req *assuredworkloadspb.RestrictAllowedResourcesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedResourcesResponse, error) {
+ return c.internalClient.RestrictAllowedResources(ctx, req, opts...)
+}
+
// DeleteWorkload deletes the workload. Make sure that workload’s direct children are already
// in a deleted state, otherwise the request will fail with a
// FAILED_PRECONDITION error.
+// In addition to assuredworkloads.workload.delete permission, the user should
+// also have orgpolicy.policy.set permission on the deleted folder to remove
+// Assured Workloads OrgPolicies.
func (c *Client) DeleteWorkload(ctx context.Context, req *assuredworkloadspb.DeleteWorkloadRequest, opts ...gax.CallOption) error {
return c.internalClient.DeleteWorkload(ctx, req, opts...)
}
@@ -227,11 +327,27 @@
return c.internalClient.GetWorkload(ctx, req, opts...)
}
+// AnalyzeWorkloadMove analyze if the source Assured Workloads can be moved to the target Assured
+// Workload
+func (c *Client) AnalyzeWorkloadMove(ctx context.Context, req *assuredworkloadspb.AnalyzeWorkloadMoveRequest, opts ...gax.CallOption) (*assuredworkloadspb.AnalyzeWorkloadMoveResponse, error) {
+ return c.internalClient.AnalyzeWorkloadMove(ctx, req, opts...)
+}
+
// ListWorkloads lists Assured Workloads under a CRM Node.
func (c *Client) ListWorkloads(ctx context.Context, req *assuredworkloadspb.ListWorkloadsRequest, opts ...gax.CallOption) *WorkloadIterator {
return c.internalClient.ListWorkloads(ctx, req, opts...)
}
+// GetOperation is a utility method from google.longrunning.Operations.
+func (c *Client) GetOperation(ctx context.Context, req *longrunningpb.GetOperationRequest, opts ...gax.CallOption) (*longrunningpb.Operation, error) {
+ return c.internalClient.GetOperation(ctx, req, opts...)
+}
+
+// ListOperations is a utility method from google.longrunning.Operations.
+func (c *Client) ListOperations(ctx context.Context, req *longrunningpb.ListOperationsRequest, opts ...gax.CallOption) *OperationIterator {
+ return c.internalClient.ListOperations(ctx, req, opts...)
+}
+
// gRPCClient is a client for interacting with Assured Workloads API over gRPC transport.
//
// Methods, except Close, may be called concurrently. However, fields must not be modified concurrently with method calls.
@@ -253,6 +369,8 @@
// Users should not Close this client.
LROClient **lroauto.OperationsClient
+ operationsClient longrunningpb.OperationsClient
+
// The x-goog-* metadata to be sent with each request.
xGoogMetadata metadata.MD
}
@@ -287,6 +405,7 @@
disableDeadlines: disableDeadlines,
client: assuredworkloadspb.NewAssuredWorkloadsServiceClient(connPool),
CallOptions: &client.CallOptions,
+ operationsClient: longrunningpb.NewOperationsClient(connPool),
}
c.setGoogleClientInfo()
@@ -457,6 +576,38 @@
return resp, nil
}
+func (c *gRPCClient) RestrictAllowedServices(ctx context.Context, req *assuredworkloadspb.RestrictAllowedServicesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedServicesResponse, error) {
+ ctx = insertMetadata(ctx, c.xGoogMetadata)
+ opts = append((*c.CallOptions).RestrictAllowedServices[0:len((*c.CallOptions).RestrictAllowedServices):len((*c.CallOptions).RestrictAllowedServices)], opts...)
+ var resp *assuredworkloadspb.RestrictAllowedServicesResponse
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.client.RestrictAllowedServices(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return resp, nil
+}
+
+func (c *gRPCClient) RestrictAllowedResources(ctx context.Context, req *assuredworkloadspb.RestrictAllowedResourcesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedResourcesResponse, error) {
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
+
+ ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+ opts = append((*c.CallOptions).RestrictAllowedResources[0:len((*c.CallOptions).RestrictAllowedResources):len((*c.CallOptions).RestrictAllowedResources)], opts...)
+ var resp *assuredworkloadspb.RestrictAllowedResourcesResponse
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.client.RestrictAllowedResources(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return resp, nil
+}
+
func (c *gRPCClient) DeleteWorkload(ctx context.Context, req *assuredworkloadspb.DeleteWorkloadRequest, opts ...gax.CallOption) error {
if _, ok := ctx.Deadline(); !ok && !c.disableDeadlines {
cctx, cancel := context.WithTimeout(ctx, 60000*time.Millisecond)
@@ -481,9 +632,7 @@
defer cancel()
ctx = cctx
}
- md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
-
- ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+ ctx = insertMetadata(ctx, c.xGoogMetadata)
opts = append((*c.CallOptions).GetWorkload[0:len((*c.CallOptions).GetWorkload):len((*c.CallOptions).GetWorkload)], opts...)
var resp *assuredworkloadspb.Workload
err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
@@ -497,10 +646,28 @@
return resp, nil
}
-func (c *gRPCClient) ListWorkloads(ctx context.Context, req *assuredworkloadspb.ListWorkloadsRequest, opts ...gax.CallOption) *WorkloadIterator {
- md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "parent", url.QueryEscape(req.GetParent())))
+func (c *gRPCClient) AnalyzeWorkloadMove(ctx context.Context, req *assuredworkloadspb.AnalyzeWorkloadMoveRequest, opts ...gax.CallOption) (*assuredworkloadspb.AnalyzeWorkloadMoveResponse, error) {
+ if _, ok := ctx.Deadline(); !ok && !c.disableDeadlines {
+ cctx, cancel := context.WithTimeout(ctx, 60000*time.Millisecond)
+ defer cancel()
+ ctx = cctx
+ }
+ ctx = insertMetadata(ctx, c.xGoogMetadata)
+ opts = append((*c.CallOptions).AnalyzeWorkloadMove[0:len((*c.CallOptions).AnalyzeWorkloadMove):len((*c.CallOptions).AnalyzeWorkloadMove)], opts...)
+ var resp *assuredworkloadspb.AnalyzeWorkloadMoveResponse
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.client.AnalyzeWorkloadMove(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return resp, nil
+}
- ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+func (c *gRPCClient) ListWorkloads(ctx context.Context, req *assuredworkloadspb.ListWorkloadsRequest, opts ...gax.CallOption) *WorkloadIterator {
+ ctx = insertMetadata(ctx, c.xGoogMetadata)
opts = append((*c.CallOptions).ListWorkloads[0:len((*c.CallOptions).ListWorkloads):len((*c.CallOptions).ListWorkloads)], opts...)
it := &WorkloadIterator{}
req = proto.Clone(req).(*assuredworkloadspb.ListWorkloadsRequest)
@@ -542,6 +709,73 @@
return it
}
+func (c *gRPCClient) GetOperation(ctx context.Context, req *longrunningpb.GetOperationRequest, opts ...gax.CallOption) (*longrunningpb.Operation, error) {
+ if _, ok := ctx.Deadline(); !ok && !c.disableDeadlines {
+ cctx, cancel := context.WithTimeout(ctx, 60000*time.Millisecond)
+ defer cancel()
+ ctx = cctx
+ }
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
+
+ ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+ opts = append((*c.CallOptions).GetOperation[0:len((*c.CallOptions).GetOperation):len((*c.CallOptions).GetOperation)], opts...)
+ var resp *longrunningpb.Operation
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.operationsClient.GetOperation(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return resp, nil
+}
+
+func (c *gRPCClient) ListOperations(ctx context.Context, req *longrunningpb.ListOperationsRequest, opts ...gax.CallOption) *OperationIterator {
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
+
+ ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+ opts = append((*c.CallOptions).ListOperations[0:len((*c.CallOptions).ListOperations):len((*c.CallOptions).ListOperations)], opts...)
+ it := &OperationIterator{}
+ req = proto.Clone(req).(*longrunningpb.ListOperationsRequest)
+ it.InternalFetch = func(pageSize int, pageToken string) ([]*longrunningpb.Operation, string, error) {
+ resp := &longrunningpb.ListOperationsResponse{}
+ if pageToken != "" {
+ req.PageToken = pageToken
+ }
+ if pageSize > math.MaxInt32 {
+ req.PageSize = math.MaxInt32
+ } else if pageSize != 0 {
+ req.PageSize = int32(pageSize)
+ }
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.operationsClient.ListOperations(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, "", err
+ }
+
+ it.Response = resp
+ return resp.GetOperations(), resp.GetNextPageToken(), nil
+ }
+ fetch := func(pageSize int, pageToken string) (string, error) {
+ items, nextPageToken, err := it.InternalFetch(pageSize, pageToken)
+ if err != nil {
+ return "", err
+ }
+ it.items = append(it.items, items...)
+ return nextPageToken, nil
+ }
+
+ it.pageInfo, it.nextFunc = iterator.NewPageInfo(fetch, it.bufLen, it.takeBuf)
+ it.pageInfo.MaxSize = int(req.GetPageSize())
+ it.pageInfo.Token = req.GetPageToken()
+
+ return it
+}
+
// CreateWorkload creates Assured Workload.
func (c *restClient) CreateWorkload(ctx context.Context, req *assuredworkloadspb.CreateWorkloadRequest, opts ...gax.CallOption) (*CreateWorkloadOperation, error) {
m := protojson.MarshalOptions{AllowPartial: true, UseEnumNumbers: true}
@@ -683,9 +917,138 @@
return resp, nil
}
+// RestrictAllowedServices restrict the list of services allowed in the Workload environment.
+// The current list of allowed services can be found at
+// https://cloud.google.com/assured-workloads/docs/supported-products (at https://cloud.google.com/assured-workloads/docs/supported-products)
+// In addition to assuredworkloads.workload.update permission, the user should
+// also have orgpolicy.policy.set permission on the folder resource
+// to use this functionality.
+func (c *restClient) RestrictAllowedServices(ctx context.Context, req *assuredworkloadspb.RestrictAllowedServicesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedServicesResponse, error) {
+ baseUrl, err := url.Parse(c.endpoint)
+ if err != nil {
+ return nil, err
+ }
+ baseUrl.Path += fmt.Sprintf("")
+
+ params := url.Values{}
+ params.Add("name", fmt.Sprintf("%v", req.GetName()))
+ params.Add("restrictionType", fmt.Sprintf("%v", req.GetRestrictionType()))
+
+ baseUrl.RawQuery = params.Encode()
+
+ // Build HTTP headers from client and context metadata.
+ headers := buildHeaders(ctx, c.xGoogMetadata, metadata.Pairs("Content-Type", "application/json"))
+ opts = append((*c.CallOptions).RestrictAllowedServices[0:len((*c.CallOptions).RestrictAllowedServices):len((*c.CallOptions).RestrictAllowedServices)], opts...)
+ unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
+ resp := &assuredworkloadspb.RestrictAllowedServicesResponse{}
+ e := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ if settings.Path != "" {
+ baseUrl.Path = settings.Path
+ }
+ httpReq, err := http.NewRequest("", baseUrl.String(), nil)
+ if err != nil {
+ return err
+ }
+ httpReq = httpReq.WithContext(ctx)
+ httpReq.Header = headers
+
+ httpRsp, err := c.httpClient.Do(httpReq)
+ if err != nil {
+ return err
+ }
+ defer httpRsp.Body.Close()
+
+ if err = googleapi.CheckResponse(httpRsp); err != nil {
+ return err
+ }
+
+ buf, err := ioutil.ReadAll(httpRsp.Body)
+ if err != nil {
+ return err
+ }
+
+ if err := unm.Unmarshal(buf, resp); err != nil {
+ return maybeUnknownEnum(err)
+ }
+
+ return nil
+ }, opts...)
+ if e != nil {
+ return nil, e
+ }
+ return resp, nil
+}
+
+// RestrictAllowedResources restrict the list of resources allowed in the Workload environment.
+// The current list of allowed products can be found at
+// https://cloud.google.com/assured-workloads/docs/supported-products (at https://cloud.google.com/assured-workloads/docs/supported-products)
+// In addition to assuredworkloads.workload.update permission, the user should
+// also have orgpolicy.policy.set permission on the folder resource
+// to use this functionality.
+func (c *restClient) RestrictAllowedResources(ctx context.Context, req *assuredworkloadspb.RestrictAllowedResourcesRequest, opts ...gax.CallOption) (*assuredworkloadspb.RestrictAllowedResourcesResponse, error) {
+ m := protojson.MarshalOptions{AllowPartial: true, UseEnumNumbers: true}
+ jsonReq, err := m.Marshal(req)
+ if err != nil {
+ return nil, err
+ }
+
+ baseUrl, err := url.Parse(c.endpoint)
+ if err != nil {
+ return nil, err
+ }
+ baseUrl.Path += fmt.Sprintf("/v1beta1/%v:restrictAllowedResources", req.GetName())
+
+ // Build HTTP headers from client and context metadata.
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
+
+ headers := buildHeaders(ctx, c.xGoogMetadata, md, metadata.Pairs("Content-Type", "application/json"))
+ opts = append((*c.CallOptions).RestrictAllowedResources[0:len((*c.CallOptions).RestrictAllowedResources):len((*c.CallOptions).RestrictAllowedResources)], opts...)
+ unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
+ resp := &assuredworkloadspb.RestrictAllowedResourcesResponse{}
+ e := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ if settings.Path != "" {
+ baseUrl.Path = settings.Path
+ }
+ httpReq, err := http.NewRequest("POST", baseUrl.String(), bytes.NewReader(jsonReq))
+ if err != nil {
+ return err
+ }
+ httpReq = httpReq.WithContext(ctx)
+ httpReq.Header = headers
+
+ httpRsp, err := c.httpClient.Do(httpReq)
+ if err != nil {
+ return err
+ }
+ defer httpRsp.Body.Close()
+
+ if err = googleapi.CheckResponse(httpRsp); err != nil {
+ return err
+ }
+
+ buf, err := ioutil.ReadAll(httpRsp.Body)
+ if err != nil {
+ return err
+ }
+
+ if err := unm.Unmarshal(buf, resp); err != nil {
+ return maybeUnknownEnum(err)
+ }
+
+ return nil
+ }, opts...)
+ if e != nil {
+ return nil, e
+ }
+ return resp, nil
+}
+
// DeleteWorkload deletes the workload. Make sure that workload’s direct children are already
// in a deleted state, otherwise the request will fail with a
// FAILED_PRECONDITION error.
+// In addition to assuredworkloads.workload.delete permission, the user should
+// also have orgpolicy.policy.set permission on the deleted folder to remove
+// Assured Workloads OrgPolicies.
func (c *restClient) DeleteWorkload(ctx context.Context, req *assuredworkloadspb.DeleteWorkloadRequest, opts ...gax.CallOption) error {
baseUrl, err := url.Parse(c.endpoint)
if err != nil {
@@ -733,12 +1096,15 @@
if err != nil {
return nil, err
}
- baseUrl.Path += fmt.Sprintf("/v1beta1/%v", req.GetName())
+ baseUrl.Path += fmt.Sprintf("")
+
+ params := url.Values{}
+ params.Add("name", fmt.Sprintf("%v", req.GetName()))
+
+ baseUrl.RawQuery = params.Encode()
// Build HTTP headers from client and context metadata.
- md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
-
- headers := buildHeaders(ctx, c.xGoogMetadata, md, metadata.Pairs("Content-Type", "application/json"))
+ headers := buildHeaders(ctx, c.xGoogMetadata, metadata.Pairs("Content-Type", "application/json"))
opts = append((*c.CallOptions).GetWorkload[0:len((*c.CallOptions).GetWorkload):len((*c.CallOptions).GetWorkload)], opts...)
unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
resp := &assuredworkloadspb.Workload{}
@@ -746,7 +1112,70 @@
if settings.Path != "" {
baseUrl.Path = settings.Path
}
- httpReq, err := http.NewRequest("GET", baseUrl.String(), nil)
+ httpReq, err := http.NewRequest("", baseUrl.String(), nil)
+ if err != nil {
+ return err
+ }
+ httpReq = httpReq.WithContext(ctx)
+ httpReq.Header = headers
+
+ httpRsp, err := c.httpClient.Do(httpReq)
+ if err != nil {
+ return err
+ }
+ defer httpRsp.Body.Close()
+
+ if err = googleapi.CheckResponse(httpRsp); err != nil {
+ return err
+ }
+
+ buf, err := ioutil.ReadAll(httpRsp.Body)
+ if err != nil {
+ return err
+ }
+
+ if err := unm.Unmarshal(buf, resp); err != nil {
+ return maybeUnknownEnum(err)
+ }
+
+ return nil
+ }, opts...)
+ if e != nil {
+ return nil, e
+ }
+ return resp, nil
+}
+
+// AnalyzeWorkloadMove analyze if the source Assured Workloads can be moved to the target Assured
+// Workload
+func (c *restClient) AnalyzeWorkloadMove(ctx context.Context, req *assuredworkloadspb.AnalyzeWorkloadMoveRequest, opts ...gax.CallOption) (*assuredworkloadspb.AnalyzeWorkloadMoveResponse, error) {
+ baseUrl, err := url.Parse(c.endpoint)
+ if err != nil {
+ return nil, err
+ }
+ baseUrl.Path += fmt.Sprintf("")
+
+ params := url.Values{}
+ if req.GetProject() != "" {
+ params.Add("project", fmt.Sprintf("%v", req.GetProject()))
+ }
+ if req.GetSource() != "" {
+ params.Add("source", fmt.Sprintf("%v", req.GetSource()))
+ }
+ params.Add("target", fmt.Sprintf("%v", req.GetTarget()))
+
+ baseUrl.RawQuery = params.Encode()
+
+ // Build HTTP headers from client and context metadata.
+ headers := buildHeaders(ctx, c.xGoogMetadata, metadata.Pairs("Content-Type", "application/json"))
+ opts = append((*c.CallOptions).AnalyzeWorkloadMove[0:len((*c.CallOptions).AnalyzeWorkloadMove):len((*c.CallOptions).AnalyzeWorkloadMove)], opts...)
+ unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
+ resp := &assuredworkloadspb.AnalyzeWorkloadMoveResponse{}
+ e := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ if settings.Path != "" {
+ baseUrl.Path = settings.Path
+ }
+ httpReq, err := http.NewRequest("", baseUrl.String(), nil)
if err != nil {
return err
}
@@ -799,7 +1228,151 @@
if err != nil {
return nil, "", err
}
- baseUrl.Path += fmt.Sprintf("/v1beta1/%v/workloads", req.GetParent())
+ baseUrl.Path += fmt.Sprintf("")
+
+ params := url.Values{}
+ if req.GetFilter() != "" {
+ params.Add("filter", fmt.Sprintf("%v", req.GetFilter()))
+ }
+ if req.GetPageSize() != 0 {
+ params.Add("pageSize", fmt.Sprintf("%v", req.GetPageSize()))
+ }
+ if req.GetPageToken() != "" {
+ params.Add("pageToken", fmt.Sprintf("%v", req.GetPageToken()))
+ }
+ params.Add("parent", fmt.Sprintf("%v", req.GetParent()))
+
+ baseUrl.RawQuery = params.Encode()
+
+ // Build HTTP headers from client and context metadata.
+ headers := buildHeaders(ctx, c.xGoogMetadata, metadata.Pairs("Content-Type", "application/json"))
+ e := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ if settings.Path != "" {
+ baseUrl.Path = settings.Path
+ }
+ httpReq, err := http.NewRequest("", baseUrl.String(), nil)
+ if err != nil {
+ return err
+ }
+ httpReq.Header = headers
+
+ httpRsp, err := c.httpClient.Do(httpReq)
+ if err != nil {
+ return err
+ }
+ defer httpRsp.Body.Close()
+
+ if err = googleapi.CheckResponse(httpRsp); err != nil {
+ return err
+ }
+
+ buf, err := ioutil.ReadAll(httpRsp.Body)
+ if err != nil {
+ return err
+ }
+
+ if err := unm.Unmarshal(buf, resp); err != nil {
+ return maybeUnknownEnum(err)
+ }
+
+ return nil
+ }, opts...)
+ if e != nil {
+ return nil, "", e
+ }
+ it.Response = resp
+ return resp.GetWorkloads(), resp.GetNextPageToken(), nil
+ }
+
+ fetch := func(pageSize int, pageToken string) (string, error) {
+ items, nextPageToken, err := it.InternalFetch(pageSize, pageToken)
+ if err != nil {
+ return "", err
+ }
+ it.items = append(it.items, items...)
+ return nextPageToken, nil
+ }
+
+ it.pageInfo, it.nextFunc = iterator.NewPageInfo(fetch, it.bufLen, it.takeBuf)
+ it.pageInfo.MaxSize = int(req.GetPageSize())
+ it.pageInfo.Token = req.GetPageToken()
+
+ return it
+}
+
+// GetOperation is a utility method from google.longrunning.Operations.
+func (c *restClient) GetOperation(ctx context.Context, req *longrunningpb.GetOperationRequest, opts ...gax.CallOption) (*longrunningpb.Operation, error) {
+ baseUrl, err := url.Parse(c.endpoint)
+ if err != nil {
+ return nil, err
+ }
+ baseUrl.Path += fmt.Sprintf("/v1beta1/%v", req.GetName())
+
+ // Build HTTP headers from client and context metadata.
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "name", url.QueryEscape(req.GetName())))
+
+ headers := buildHeaders(ctx, c.xGoogMetadata, md, metadata.Pairs("Content-Type", "application/json"))
+ opts = append((*c.CallOptions).GetOperation[0:len((*c.CallOptions).GetOperation):len((*c.CallOptions).GetOperation)], opts...)
+ unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
+ resp := &longrunningpb.Operation{}
+ e := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ if settings.Path != "" {
+ baseUrl.Path = settings.Path
+ }
+ httpReq, err := http.NewRequest("GET", baseUrl.String(), nil)
+ if err != nil {
+ return err
+ }
+ httpReq = httpReq.WithContext(ctx)
+ httpReq.Header = headers
+
+ httpRsp, err := c.httpClient.Do(httpReq)
+ if err != nil {
+ return err
+ }
+ defer httpRsp.Body.Close()
+
+ if err = googleapi.CheckResponse(httpRsp); err != nil {
+ return err
+ }
+
+ buf, err := ioutil.ReadAll(httpRsp.Body)
+ if err != nil {
+ return err
+ }
+
+ if err := unm.Unmarshal(buf, resp); err != nil {
+ return maybeUnknownEnum(err)
+ }
+
+ return nil
+ }, opts...)
+ if e != nil {
+ return nil, e
+ }
+ return resp, nil
+}
+
+// ListOperations is a utility method from google.longrunning.Operations.
+func (c *restClient) ListOperations(ctx context.Context, req *longrunningpb.ListOperationsRequest, opts ...gax.CallOption) *OperationIterator {
+ it := &OperationIterator{}
+ req = proto.Clone(req).(*longrunningpb.ListOperationsRequest)
+ unm := protojson.UnmarshalOptions{AllowPartial: true, DiscardUnknown: true}
+ it.InternalFetch = func(pageSize int, pageToken string) ([]*longrunningpb.Operation, string, error) {
+ resp := &longrunningpb.ListOperationsResponse{}
+ if pageToken != "" {
+ req.PageToken = pageToken
+ }
+ if pageSize > math.MaxInt32 {
+ req.PageSize = math.MaxInt32
+ } else if pageSize != 0 {
+ req.PageSize = int32(pageSize)
+ }
+ baseUrl, err := url.Parse(c.endpoint)
+ if err != nil {
+ return nil, "", err
+ }
+ baseUrl.Path += fmt.Sprintf("/v1beta1/%v/operations", req.GetName())
params := url.Values{}
if req.GetFilter() != "" {
@@ -851,7 +1424,7 @@
return nil, "", e
}
it.Response = resp
- return resp.GetWorkloads(), resp.GetNextPageToken(), nil
+ return resp.GetOperations(), resp.GetNextPageToken(), nil
}
fetch := func(pageSize int, pageToken string) (string, error) {
@@ -952,6 +1525,53 @@
return op.lro.Name()
}
+// OperationIterator manages a stream of *longrunningpb.Operation.
+type OperationIterator struct {
+ items []*longrunningpb.Operation
+ pageInfo *iterator.PageInfo
+ nextFunc func() error
+
+ // Response is the raw response for the current page.
+ // It must be cast to the RPC response type.
+ // Calling Next() or InternalFetch() updates this value.
+ Response interface{}
+
+ // InternalFetch is for use by the Google Cloud Libraries only.
+ // It is not part of the stable interface of this package.
+ //
+ // InternalFetch returns results from a single call to the underlying RPC.
+ // The number of results is no greater than pageSize.
+ // If there are no more results, nextPageToken is empty and err is nil.
+ InternalFetch func(pageSize int, pageToken string) (results []*longrunningpb.Operation, nextPageToken string, err error)
+}
+
+// PageInfo supports pagination. See the google.golang.org/api/iterator package for details.
+func (it *OperationIterator) PageInfo() *iterator.PageInfo {
+ return it.pageInfo
+}
+
+// Next returns the next result. Its second return value is iterator.Done if there are no more
+// results. Once Next returns Done, all subsequent calls will return Done.
+func (it *OperationIterator) Next() (*longrunningpb.Operation, error) {
+ var item *longrunningpb.Operation
+ if err := it.nextFunc(); err != nil {
+ return item, err
+ }
+ item = it.items[0]
+ it.items = it.items[1:]
+ return item, nil
+}
+
+func (it *OperationIterator) bufLen() int {
+ return len(it.items)
+}
+
+func (it *OperationIterator) takeBuf() interface{} {
+ b := it.items
+ it.items = nil
+ return b
+}
+
// WorkloadIterator manages a stream of *assuredworkloadspb.Workload.
type WorkloadIterator struct {
items []*assuredworkloadspb.Workload
diff --git a/assuredworkloads/apiv1beta1/assured_workloads_client_example_test.go b/assuredworkloads/apiv1beta1/assured_workloads_client_example_test.go
index 6ace5c5..44733b1 100644
--- a/assuredworkloads/apiv1beta1/assured_workloads_client_example_test.go
+++ b/assuredworkloads/apiv1beta1/assured_workloads_client_example_test.go
@@ -22,6 +22,7 @@
assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
"google.golang.org/api/iterator"
assuredworkloadspb "google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1"
+ longrunningpb "google.golang.org/genproto/googleapis/longrunning"
)
func ExampleNewClient() {
@@ -93,6 +94,46 @@
_ = resp
}
+func ExampleClient_RestrictAllowedServices() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.RestrictAllowedServicesRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#RestrictAllowedServicesRequest.
+ }
+ resp, err := c.RestrictAllowedServices(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+func ExampleClient_RestrictAllowedResources() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.RestrictAllowedResourcesRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#RestrictAllowedResourcesRequest.
+ }
+ resp, err := c.RestrictAllowedResources(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
func ExampleClient_DeleteWorkload() {
ctx := context.Background()
c, err := assuredworkloads.NewClient(ctx)
@@ -131,6 +172,26 @@
_ = resp
}
+func ExampleClient_AnalyzeWorkloadMove() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.AnalyzeWorkloadMoveRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#AnalyzeWorkloadMoveRequest.
+ }
+ resp, err := c.AnalyzeWorkloadMove(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
func ExampleClient_ListWorkloads() {
ctx := context.Background()
c, err := assuredworkloads.NewClient(ctx)
@@ -156,3 +217,49 @@
_ = resp
}
}
+
+func ExampleClient_GetOperation() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &longrunningpb.GetOperationRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/longrunning#GetOperationRequest.
+ }
+ resp, err := c.GetOperation(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+func ExampleClient_ListOperations() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &longrunningpb.ListOperationsRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/longrunning#ListOperationsRequest.
+ }
+ it := c.ListOperations(ctx, req)
+ for {
+ resp, err := it.Next()
+ if err == iterator.Done {
+ break
+ }
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+ }
+}
diff --git a/assuredworkloads/apiv1beta1/gapic_metadata.json b/assuredworkloads/apiv1beta1/gapic_metadata.json
index dd0ab7e..177f326 100644
--- a/assuredworkloads/apiv1beta1/gapic_metadata.json
+++ b/assuredworkloads/apiv1beta1/gapic_metadata.json
@@ -10,6 +10,11 @@
"grpc": {
"libraryClient": "Client",
"rpcs": {
+ "AnalyzeWorkloadMove": {
+ "methods": [
+ "AnalyzeWorkloadMove"
+ ]
+ },
"CreateWorkload": {
"methods": [
"CreateWorkload"
@@ -20,16 +25,36 @@
"DeleteWorkload"
]
},
+ "GetOperation": {
+ "methods": [
+ "GetOperation"
+ ]
+ },
"GetWorkload": {
"methods": [
"GetWorkload"
]
},
+ "ListOperations": {
+ "methods": [
+ "ListOperations"
+ ]
+ },
"ListWorkloads": {
"methods": [
"ListWorkloads"
]
},
+ "RestrictAllowedResources": {
+ "methods": [
+ "RestrictAllowedResources"
+ ]
+ },
+ "RestrictAllowedServices": {
+ "methods": [
+ "RestrictAllowedServices"
+ ]
+ },
"UpdateWorkload": {
"methods": [
"UpdateWorkload"
@@ -40,6 +65,11 @@
"rest": {
"libraryClient": "Client",
"rpcs": {
+ "AnalyzeWorkloadMove": {
+ "methods": [
+ "AnalyzeWorkloadMove"
+ ]
+ },
"CreateWorkload": {
"methods": [
"CreateWorkload"
@@ -50,16 +80,36 @@
"DeleteWorkload"
]
},
+ "GetOperation": {
+ "methods": [
+ "GetOperation"
+ ]
+ },
"GetWorkload": {
"methods": [
"GetWorkload"
]
},
+ "ListOperations": {
+ "methods": [
+ "ListOperations"
+ ]
+ },
"ListWorkloads": {
"methods": [
"ListWorkloads"
]
},
+ "RestrictAllowedResources": {
+ "methods": [
+ "RestrictAllowedResources"
+ ]
+ },
+ "RestrictAllowedServices": {
+ "methods": [
+ "RestrictAllowedServices"
+ ]
+ },
"UpdateWorkload": {
"methods": [
"UpdateWorkload"
diff --git a/assuredworkloads/go.mod b/assuredworkloads/go.mod
index 30789eb..b18c877 100644
--- a/assuredworkloads/go.mod
+++ b/assuredworkloads/go.mod
@@ -5,8 +5,8 @@
require (
cloud.google.com/go v0.102.1
github.com/googleapis/gax-go/v2 v2.4.0
- google.golang.org/api v0.86.0
- google.golang.org/genproto v0.0.0-20220706132729-d86698d07c53
+ google.golang.org/api v0.87.0
+ google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f
google.golang.org/grpc v1.47.0
google.golang.org/protobuf v1.28.0
)
diff --git a/assuredworkloads/go.sum b/assuredworkloads/go.sum
index 1cfb9e5..df87a96 100644
--- a/assuredworkloads/go.sum
+++ b/assuredworkloads/go.sum
@@ -499,8 +499,8 @@
google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw=
google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg=
google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o=
-google.golang.org/api v0.86.0 h1:ZAnyOHQFIuWso1BodVfSaRyffD74T9ERGFa3k1fNk/U=
-google.golang.org/api v0.86.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
+google.golang.org/api v0.87.0 h1:pUQVF/F+X7Tl1lo4LJoJf5BOpjtmINU80p9XpYTU2p4=
+google.golang.org/api v0.87.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -589,8 +589,8 @@
google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
-google.golang.org/genproto v0.0.0-20220706132729-d86698d07c53 h1:liFd7OL799HvMNYG5xozhUoWDj944y+zXPDOhu4PyaM=
-google.golang.org/genproto v0.0.0-20220706132729-d86698d07c53/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
+google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f h1:P8EiVSxZwC6xH2niv2N66aqwMtYFg+D54gbjpcqKJtM=
+google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE=
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/AnalyzeWorkloadMove/main.go b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/AnalyzeWorkloadMove/main.go
new file mode 100644
index 0000000..ae9dc09
--- /dev/null
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/AnalyzeWorkloadMove/main.go
@@ -0,0 +1,48 @@
+// Copyright 2022 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Code generated by cloud.google.com/go/internal/gapicgen/gensnippets. DO NOT EDIT.
+
+// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync]
+
+package main
+
+import (
+ "context"
+
+ assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
+ assuredworkloadspb "google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1"
+)
+
+func main() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.AnalyzeWorkloadMoveRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#AnalyzeWorkloadMoveRequest.
+ }
+ resp, err := c.AnalyzeWorkloadMove(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync]
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/GetOperation/main.go b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/GetOperation/main.go
new file mode 100644
index 0000000..c2ba6cb
--- /dev/null
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/GetOperation/main.go
@@ -0,0 +1,48 @@
+// Copyright 2022 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Code generated by cloud.google.com/go/internal/gapicgen/gensnippets. DO NOT EDIT.
+
+// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_GetOperation_sync]
+
+package main
+
+import (
+ "context"
+
+ assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
+ longrunningpb "google.golang.org/genproto/googleapis/longrunning"
+)
+
+func main() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &longrunningpb.GetOperationRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/longrunning#GetOperationRequest.
+ }
+ resp, err := c.GetOperation(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_GetOperation_sync]
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/ListOperations/main.go b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/ListOperations/main.go
new file mode 100644
index 0000000..86ee121
--- /dev/null
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/ListOperations/main.go
@@ -0,0 +1,55 @@
+// Copyright 2022 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Code generated by cloud.google.com/go/internal/gapicgen/gensnippets. DO NOT EDIT.
+
+// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_ListOperations_sync]
+
+package main
+
+import (
+ "context"
+
+ assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
+ "google.golang.org/api/iterator"
+ longrunningpb "google.golang.org/genproto/googleapis/longrunning"
+)
+
+func main() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &longrunningpb.ListOperationsRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/longrunning#ListOperationsRequest.
+ }
+ it := c.ListOperations(ctx, req)
+ for {
+ resp, err := it.Next()
+ if err == iterator.Done {
+ break
+ }
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+ }
+}
+
+// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_ListOperations_sync]
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedResources/main.go b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedResources/main.go
new file mode 100644
index 0000000..a687293
--- /dev/null
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedResources/main.go
@@ -0,0 +1,48 @@
+// Copyright 2022 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Code generated by cloud.google.com/go/internal/gapicgen/gensnippets. DO NOT EDIT.
+
+// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_sync]
+
+package main
+
+import (
+ "context"
+
+ assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
+ assuredworkloadspb "google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1"
+)
+
+func main() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.RestrictAllowedResourcesRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#RestrictAllowedResourcesRequest.
+ }
+ resp, err := c.RestrictAllowedResources(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_sync]
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedServices/main.go b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedServices/main.go
new file mode 100644
index 0000000..5b65b93
--- /dev/null
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/Client/RestrictAllowedServices/main.go
@@ -0,0 +1,48 @@
+// Copyright 2022 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Code generated by cloud.google.com/go/internal/gapicgen/gensnippets. DO NOT EDIT.
+
+// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_sync]
+
+package main
+
+import (
+ "context"
+
+ assuredworkloads "cloud.google.com/go/assuredworkloads/apiv1beta1"
+ assuredworkloadspb "google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1"
+)
+
+func main() {
+ ctx := context.Background()
+ c, err := assuredworkloads.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &assuredworkloadspb.RestrictAllowedServicesRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/assuredworkloads/v1beta1#RestrictAllowedServicesRequest.
+ }
+ resp, err := c.RestrictAllowedServices(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
+// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_sync]
diff --git a/internal/generated/snippets/assuredworkloads/apiv1beta1/snippet_metadata.google.cloud.assuredworkloads.v1beta1.json b/internal/generated/snippets/assuredworkloads/apiv1beta1/snippet_metadata.google.cloud.assuredworkloads.v1beta1.json
index e48c171..2041d2d 100644
--- a/internal/generated/snippets/assuredworkloads/apiv1beta1/snippet_metadata.google.cloud.assuredworkloads.v1beta1.json
+++ b/internal/generated/snippets/assuredworkloads/apiv1beta1/snippet_metadata.google.cloud.assuredworkloads.v1beta1.json
@@ -12,6 +12,52 @@
},
"snippets": [
{
+ "regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync",
+ "title": "assuredworkloads AnalyzeWorkloadMove Sample",
+ "description": "AnalyzeWorkloadMove analyze if the source Assured Workloads can be moved to the target Assured\nWorkload",
+ "file": "Client/AnalyzeWorkloadMove/main.go",
+ "language": "GO",
+ "clientMethod": {
+ "shortName": "AnalyzeWorkloadMove",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client.AnalyzeWorkloadMove",
+ "parameters": [
+ {
+ "type": "context.Context",
+ "name": "ctx"
+ },
+ {
+ "type": "assuredworkloadspb.AnalyzeWorkloadMoveRequest",
+ "name": "req"
+ },
+ {
+ "type": "...gax.CallOption",
+ "name": "opts"
+ }
+ ],
+ "resultType": "assuredworkloadspb.AnalyzeWorkloadMoveResponse",
+ "client": {
+ "shortName": "Client",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client"
+ },
+ "method": {
+ "shortName": "AnalyzeWorkloadMove",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService.AnalyzeWorkloadMove",
+ "service": {
+ "shortName": "AssuredWorkloadsService",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService"
+ }
+ }
+ },
+ "origin": "API_DEFINITION",
+ "segments": [
+ {
+ "start": 18,
+ "end": 47,
+ "type": "FULL"
+ }
+ ]
+ },
+ {
"regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_CreateWorkload_sync",
"title": "assuredworkloads CreateWorkload Sample",
"description": "CreateWorkload creates Assured Workload.",
@@ -60,7 +106,7 @@
{
"regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_DeleteWorkload_sync",
"title": "assuredworkloads DeleteWorkload Sample",
- "description": "DeleteWorkload deletes the workload. Make sure that workload’s direct children are already\nin a deleted state, otherwise the request will fail with a\nFAILED_PRECONDITION error.",
+ "description": "DeleteWorkload deletes the workload. Make sure that workload’s direct children are already\nin a deleted state, otherwise the request will fail with a\nFAILED_PRECONDITION error.\nIn addition to assuredworkloads.workload.delete permission, the user should\nalso have orgpolicy.policy.set permission on the deleted folder to remove\nAssured Workloads OrgPolicies.",
"file": "Client/DeleteWorkload/main.go",
"language": "GO",
"clientMethod": {
@@ -103,6 +149,52 @@
]
},
{
+ "regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_GetOperation_sync",
+ "title": "assuredworkloads GetOperation Sample",
+ "description": "GetOperation is a utility method from google.longrunning.Operations.",
+ "file": "Client/GetOperation/main.go",
+ "language": "GO",
+ "clientMethod": {
+ "shortName": "GetOperation",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client.GetOperation",
+ "parameters": [
+ {
+ "type": "context.Context",
+ "name": "ctx"
+ },
+ {
+ "type": "longrunningpb.GetOperationRequest",
+ "name": "req"
+ },
+ {
+ "type": "...gax.CallOption",
+ "name": "opts"
+ }
+ ],
+ "resultType": "longrunningpb.Operation",
+ "client": {
+ "shortName": "Client",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client"
+ },
+ "method": {
+ "shortName": "GetOperation",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService.GetOperation",
+ "service": {
+ "shortName": "AssuredWorkloadsService",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService"
+ }
+ }
+ },
+ "origin": "API_DEFINITION",
+ "segments": [
+ {
+ "start": 18,
+ "end": 47,
+ "type": "FULL"
+ }
+ ]
+ },
+ {
"regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_GetWorkload_sync",
"title": "assuredworkloads GetWorkload Sample",
"description": "GetWorkload gets Assured Workload associated with a CRM Node",
@@ -149,6 +241,52 @@
]
},
{
+ "regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_ListOperations_sync",
+ "title": "assuredworkloads ListOperations Sample",
+ "description": "ListOperations is a utility method from google.longrunning.Operations.",
+ "file": "Client/ListOperations/main.go",
+ "language": "GO",
+ "clientMethod": {
+ "shortName": "ListOperations",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client.ListOperations",
+ "parameters": [
+ {
+ "type": "context.Context",
+ "name": "ctx"
+ },
+ {
+ "type": "longrunningpb.ListOperationsRequest",
+ "name": "req"
+ },
+ {
+ "type": "...gax.CallOption",
+ "name": "opts"
+ }
+ ],
+ "resultType": "OperationIterator",
+ "client": {
+ "shortName": "Client",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client"
+ },
+ "method": {
+ "shortName": "ListOperations",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService.ListOperations",
+ "service": {
+ "shortName": "AssuredWorkloadsService",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService"
+ }
+ }
+ },
+ "origin": "API_DEFINITION",
+ "segments": [
+ {
+ "start": 18,
+ "end": 54,
+ "type": "FULL"
+ }
+ ]
+ },
+ {
"regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_ListWorkloads_sync",
"title": "assuredworkloads ListWorkloads Sample",
"description": "ListWorkloads lists Assured Workloads under a CRM Node.",
@@ -195,6 +333,98 @@
]
},
{
+ "regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_sync",
+ "title": "assuredworkloads RestrictAllowedResources Sample",
+ "description": "RestrictAllowedResources restrict the list of resources allowed in the Workload environment.\nThe current list of allowed products can be found at\nhttps: //cloud.google.com/assured-workloads/docs/supported-products (at https: //cloud.google.com/assured-workloads/docs/supported-products)\nIn addition to assuredworkloads.workload.update permission, the user should\nalso have orgpolicy.policy.set permission on the folder resource\nto use this functionality.",
+ "file": "Client/RestrictAllowedResources/main.go",
+ "language": "GO",
+ "clientMethod": {
+ "shortName": "RestrictAllowedResources",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client.RestrictAllowedResources",
+ "parameters": [
+ {
+ "type": "context.Context",
+ "name": "ctx"
+ },
+ {
+ "type": "assuredworkloadspb.RestrictAllowedResourcesRequest",
+ "name": "req"
+ },
+ {
+ "type": "...gax.CallOption",
+ "name": "opts"
+ }
+ ],
+ "resultType": "assuredworkloadspb.RestrictAllowedResourcesResponse",
+ "client": {
+ "shortName": "Client",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client"
+ },
+ "method": {
+ "shortName": "RestrictAllowedResources",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService.RestrictAllowedResources",
+ "service": {
+ "shortName": "AssuredWorkloadsService",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService"
+ }
+ }
+ },
+ "origin": "API_DEFINITION",
+ "segments": [
+ {
+ "start": 18,
+ "end": 47,
+ "type": "FULL"
+ }
+ ]
+ },
+ {
+ "regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_sync",
+ "title": "assuredworkloads RestrictAllowedServices Sample",
+ "description": "RestrictAllowedServices restrict the list of services allowed in the Workload environment.\nThe current list of allowed services can be found at\nhttps: //cloud.google.com/assured-workloads/docs/supported-products (at https: //cloud.google.com/assured-workloads/docs/supported-products)\nIn addition to assuredworkloads.workload.update permission, the user should\nalso have orgpolicy.policy.set permission on the folder resource\nto use this functionality.",
+ "file": "Client/RestrictAllowedServices/main.go",
+ "language": "GO",
+ "clientMethod": {
+ "shortName": "RestrictAllowedServices",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client.RestrictAllowedServices",
+ "parameters": [
+ {
+ "type": "context.Context",
+ "name": "ctx"
+ },
+ {
+ "type": "assuredworkloadspb.RestrictAllowedServicesRequest",
+ "name": "req"
+ },
+ {
+ "type": "...gax.CallOption",
+ "name": "opts"
+ }
+ ],
+ "resultType": "assuredworkloadspb.RestrictAllowedServicesResponse",
+ "client": {
+ "shortName": "Client",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.Client"
+ },
+ "method": {
+ "shortName": "RestrictAllowedServices",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService.RestrictAllowedServices",
+ "service": {
+ "shortName": "AssuredWorkloadsService",
+ "fullName": "google.cloud.assuredworkloads.v1beta1.AssuredWorkloadsService"
+ }
+ }
+ },
+ "origin": "API_DEFINITION",
+ "segments": [
+ {
+ "start": 18,
+ "end": 47,
+ "type": "FULL"
+ }
+ ]
+ },
+ {
"regionTag": "assuredworkloads_v1beta1_generated_AssuredWorkloadsService_UpdateWorkload_sync",
"title": "assuredworkloads UpdateWorkload Sample",
"description": "UpdateWorkload updates an existing workload.\nCurrently allows updating of workload display_name and labels.\nFor force updates don’t set etag field in the Workload.\nOnly one update operation per workload can be in progress.",
diff --git a/internal/generated/snippets/bigquery/connection/apiv1/snippet_metadata.google.cloud.bigquery.connection.v1.json b/internal/generated/snippets/bigquery/connection/apiv1/snippet_metadata.google.cloud.bigquery.connection.v1.json
index 23f85b0..1ad9a5f 100644
--- a/internal/generated/snippets/bigquery/connection/apiv1/snippet_metadata.google.cloud.bigquery.connection.v1.json
+++ b/internal/generated/snippets/bigquery/connection/apiv1/snippet_metadata.google.cloud.bigquery.connection.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/connection/apiv1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/connection/apiv1beta1/snippet_metadata.google.cloud.bigquery.connection.v1beta1.json b/internal/generated/snippets/bigquery/connection/apiv1beta1/snippet_metadata.google.cloud.bigquery.connection.v1beta1.json
index 11c57f6..04b3a41 100644
--- a/internal/generated/snippets/bigquery/connection/apiv1beta1/snippet_metadata.google.cloud.bigquery.connection.v1beta1.json
+++ b/internal/generated/snippets/bigquery/connection/apiv1beta1/snippet_metadata.google.cloud.bigquery.connection.v1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/connection/apiv1beta1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/dataexchange/apiv1beta1/snippet_metadata.google.cloud.bigquery.dataexchange.v1beta1.json b/internal/generated/snippets/bigquery/dataexchange/apiv1beta1/snippet_metadata.google.cloud.bigquery.dataexchange.v1beta1.json
index bf351d7..745e964 100644
--- a/internal/generated/snippets/bigquery/dataexchange/apiv1beta1/snippet_metadata.google.cloud.bigquery.dataexchange.v1beta1.json
+++ b/internal/generated/snippets/bigquery/dataexchange/apiv1beta1/snippet_metadata.google.cloud.bigquery.dataexchange.v1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/dataexchange/apiv1beta1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/datatransfer/apiv1/snippet_metadata.google.cloud.bigquery.datatransfer.v1.json b/internal/generated/snippets/bigquery/datatransfer/apiv1/snippet_metadata.google.cloud.bigquery.datatransfer.v1.json
index 1df325d..b9955f8 100644
--- a/internal/generated/snippets/bigquery/datatransfer/apiv1/snippet_metadata.google.cloud.bigquery.datatransfer.v1.json
+++ b/internal/generated/snippets/bigquery/datatransfer/apiv1/snippet_metadata.google.cloud.bigquery.datatransfer.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/datatransfer/apiv1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/migration/apiv2/snippet_metadata.google.cloud.bigquery.migration.v2.json b/internal/generated/snippets/bigquery/migration/apiv2/snippet_metadata.google.cloud.bigquery.migration.v2.json
index 0cb6ceb..f57cfb0 100644
--- a/internal/generated/snippets/bigquery/migration/apiv2/snippet_metadata.google.cloud.bigquery.migration.v2.json
+++ b/internal/generated/snippets/bigquery/migration/apiv2/snippet_metadata.google.cloud.bigquery.migration.v2.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/migration/apiv2",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/migration/apiv2alpha/snippet_metadata.google.cloud.bigquery.migration.v2alpha.json b/internal/generated/snippets/bigquery/migration/apiv2alpha/snippet_metadata.google.cloud.bigquery.migration.v2alpha.json
index b51ac8d..b281cfd 100644
--- a/internal/generated/snippets/bigquery/migration/apiv2alpha/snippet_metadata.google.cloud.bigquery.migration.v2alpha.json
+++ b/internal/generated/snippets/bigquery/migration/apiv2alpha/snippet_metadata.google.cloud.bigquery.migration.v2alpha.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/migration/apiv2alpha",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/reservation/apiv1/snippet_metadata.google.cloud.bigquery.reservation.v1.json b/internal/generated/snippets/bigquery/reservation/apiv1/snippet_metadata.google.cloud.bigquery.reservation.v1.json
index 18aa3e7..40ceddd 100644
--- a/internal/generated/snippets/bigquery/reservation/apiv1/snippet_metadata.google.cloud.bigquery.reservation.v1.json
+++ b/internal/generated/snippets/bigquery/reservation/apiv1/snippet_metadata.google.cloud.bigquery.reservation.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/reservation/apiv1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/reservation/apiv1beta1/snippet_metadata.google.cloud.bigquery.reservation.v1beta1.json b/internal/generated/snippets/bigquery/reservation/apiv1beta1/snippet_metadata.google.cloud.bigquery.reservation.v1beta1.json
index 77b459a..bb83233 100644
--- a/internal/generated/snippets/bigquery/reservation/apiv1beta1/snippet_metadata.google.cloud.bigquery.reservation.v1beta1.json
+++ b/internal/generated/snippets/bigquery/reservation/apiv1beta1/snippet_metadata.google.cloud.bigquery.reservation.v1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/reservation/apiv1beta1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/storage/apiv1/snippet_metadata.google.cloud.bigquery.storage.v1.json b/internal/generated/snippets/bigquery/storage/apiv1/snippet_metadata.google.cloud.bigquery.storage.v1.json
index 96cd1cb..6638ef0 100644
--- a/internal/generated/snippets/bigquery/storage/apiv1/snippet_metadata.google.cloud.bigquery.storage.v1.json
+++ b/internal/generated/snippets/bigquery/storage/apiv1/snippet_metadata.google.cloud.bigquery.storage.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/storage/apiv1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/storage/apiv1beta1/snippet_metadata.google.cloud.bigquery.storage.v1beta1.json b/internal/generated/snippets/bigquery/storage/apiv1beta1/snippet_metadata.google.cloud.bigquery.storage.v1beta1.json
index 944b76d..dc0f6bf 100644
--- a/internal/generated/snippets/bigquery/storage/apiv1beta1/snippet_metadata.google.cloud.bigquery.storage.v1beta1.json
+++ b/internal/generated/snippets/bigquery/storage/apiv1beta1/snippet_metadata.google.cloud.bigquery.storage.v1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/storage/apiv1beta1",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/internal/generated/snippets/bigquery/storage/apiv1beta2/snippet_metadata.google.cloud.bigquery.storage.v1beta2.json b/internal/generated/snippets/bigquery/storage/apiv1beta2/snippet_metadata.google.cloud.bigquery.storage.v1beta2.json
index 0a2a896..e5c42e7 100644
--- a/internal/generated/snippets/bigquery/storage/apiv1beta2/snippet_metadata.google.cloud.bigquery.storage.v1beta2.json
+++ b/internal/generated/snippets/bigquery/storage/apiv1beta2/snippet_metadata.google.cloud.bigquery.storage.v1beta2.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "cloud.google.com/go/bigquery/storage/apiv1beta2",
- "version": "1.35.0",
+ "version": "1.36.0",
"language": "GO",
"apis": [
{
diff --git a/vmmigration/apiv1/doc.go b/vmmigration/apiv1/doc.go
index fa2da4b..f71c321 100644
--- a/vmmigration/apiv1/doc.go
+++ b/vmmigration/apiv1/doc.go
@@ -17,7 +17,7 @@
// Package vmmigration is an auto-generated package for the
// VM Migration API.
//
-// Use the Migrate for Compute Engine API to programmatically migrate
+// Use the Migrate to Virtual Machines API to programmatically migrate
// workloads.
//
// Example usage
diff --git a/vmmigration/apiv1/gapic_metadata.json b/vmmigration/apiv1/gapic_metadata.json
index 5e30985..071a141 100644
--- a/vmmigration/apiv1/gapic_metadata.json
+++ b/vmmigration/apiv1/gapic_metadata.json
@@ -224,6 +224,11 @@
"methods": [
"UpdateTargetProject"
]
+ },
+ "UpgradeAppliance": {
+ "methods": [
+ "UpgradeAppliance"
+ ]
}
}
}
diff --git a/vmmigration/apiv1/vm_migration_client.go b/vmmigration/apiv1/vm_migration_client.go
index 4f957bd..056fdba 100644
--- a/vmmigration/apiv1/vm_migration_client.go
+++ b/vmmigration/apiv1/vm_migration_client.go
@@ -55,6 +55,7 @@
GetDatacenterConnector []gax.CallOption
CreateDatacenterConnector []gax.CallOption
DeleteDatacenterConnector []gax.CallOption
+ UpgradeAppliance []gax.CallOption
CreateMigratingVm []gax.CallOption
ListMigratingVms []gax.CallOption
GetMigratingVm []gax.CallOption
@@ -114,6 +115,7 @@
GetDatacenterConnector: []gax.CallOption{},
CreateDatacenterConnector: []gax.CallOption{},
DeleteDatacenterConnector: []gax.CallOption{},
+ UpgradeAppliance: []gax.CallOption{},
CreateMigratingVm: []gax.CallOption{},
ListMigratingVms: []gax.CallOption{},
GetMigratingVm: []gax.CallOption{},
@@ -172,6 +174,8 @@
CreateDatacenterConnectorOperation(name string) *CreateDatacenterConnectorOperation
DeleteDatacenterConnector(context.Context, *vmmigrationpb.DeleteDatacenterConnectorRequest, ...gax.CallOption) (*DeleteDatacenterConnectorOperation, error)
DeleteDatacenterConnectorOperation(name string) *DeleteDatacenterConnectorOperation
+ UpgradeAppliance(context.Context, *vmmigrationpb.UpgradeApplianceRequest, ...gax.CallOption) (*UpgradeApplianceOperation, error)
+ UpgradeApplianceOperation(name string) *UpgradeApplianceOperation
CreateMigratingVm(context.Context, *vmmigrationpb.CreateMigratingVmRequest, ...gax.CallOption) (*CreateMigratingVmOperation, error)
CreateMigratingVmOperation(name string) *CreateMigratingVmOperation
ListMigratingVms(context.Context, *vmmigrationpb.ListMigratingVmsRequest, ...gax.CallOption) *MigratingVmIterator
@@ -377,6 +381,18 @@
return c.internalClient.DeleteDatacenterConnectorOperation(name)
}
+// UpgradeAppliance upgrades the appliance relate to this DatacenterConnector to the in-place
+// updateable version.
+func (c *Client) UpgradeAppliance(ctx context.Context, req *vmmigrationpb.UpgradeApplianceRequest, opts ...gax.CallOption) (*UpgradeApplianceOperation, error) {
+ return c.internalClient.UpgradeAppliance(ctx, req, opts...)
+}
+
+// UpgradeApplianceOperation returns a new UpgradeApplianceOperation from a given name.
+// The name must be that of a previously created UpgradeApplianceOperation, possibly from a different process.
+func (c *Client) UpgradeApplianceOperation(name string) *UpgradeApplianceOperation {
+ return c.internalClient.UpgradeApplianceOperation(name)
+}
+
// CreateMigratingVm creates a new MigratingVm in a given Source.
func (c *Client) CreateMigratingVm(ctx context.Context, req *vmmigrationpb.CreateMigratingVmRequest, opts ...gax.CallOption) (*CreateMigratingVmOperation, error) {
return c.internalClient.CreateMigratingVm(ctx, req, opts...)
@@ -1147,6 +1163,30 @@
}, nil
}
+func (c *gRPCClient) UpgradeAppliance(ctx context.Context, req *vmmigrationpb.UpgradeApplianceRequest, opts ...gax.CallOption) (*UpgradeApplianceOperation, error) {
+ if _, ok := ctx.Deadline(); !ok && !c.disableDeadlines {
+ cctx, cancel := context.WithTimeout(ctx, 60000*time.Millisecond)
+ defer cancel()
+ ctx = cctx
+ }
+ md := metadata.Pairs("x-goog-request-params", fmt.Sprintf("%s=%v", "datacenter_connector", url.QueryEscape(req.GetDatacenterConnector())))
+
+ ctx = insertMetadata(ctx, c.xGoogMetadata, md)
+ opts = append((*c.CallOptions).UpgradeAppliance[0:len((*c.CallOptions).UpgradeAppliance):len((*c.CallOptions).UpgradeAppliance)], opts...)
+ var resp *longrunningpb.Operation
+ err := gax.Invoke(ctx, func(ctx context.Context, settings gax.CallSettings) error {
+ var err error
+ resp, err = c.client.UpgradeAppliance(ctx, req, settings.GRPC...)
+ return err
+ }, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return &UpgradeApplianceOperation{
+ lro: longrunning.InternalNewOperation(*c.LROClient, resp),
+ }, nil
+}
+
func (c *gRPCClient) CreateMigratingVm(ctx context.Context, req *vmmigrationpb.CreateMigratingVmRequest, opts ...gax.CallOption) (*CreateMigratingVmOperation, error) {
if _, ok := ctx.Deadline(); !ok && !c.disableDeadlines {
cctx, cancel := context.WithTimeout(ctx, 60000*time.Millisecond)
@@ -3666,6 +3706,75 @@
return op.lro.Name()
}
+// UpgradeApplianceOperation manages a long-running operation from UpgradeAppliance.
+type UpgradeApplianceOperation struct {
+ lro *longrunning.Operation
+}
+
+// UpgradeApplianceOperation returns a new UpgradeApplianceOperation from a given name.
+// The name must be that of a previously created UpgradeApplianceOperation, possibly from a different process.
+func (c *gRPCClient) UpgradeApplianceOperation(name string) *UpgradeApplianceOperation {
+ return &UpgradeApplianceOperation{
+ lro: longrunning.InternalNewOperation(*c.LROClient, &longrunningpb.Operation{Name: name}),
+ }
+}
+
+// Wait blocks until the long-running operation is completed, returning the response and any errors encountered.
+//
+// See documentation of Poll for error-handling information.
+func (op *UpgradeApplianceOperation) Wait(ctx context.Context, opts ...gax.CallOption) (*vmmigrationpb.UpgradeApplianceResponse, error) {
+ var resp vmmigrationpb.UpgradeApplianceResponse
+ if err := op.lro.WaitWithInterval(ctx, &resp, time.Minute, opts...); err != nil {
+ return nil, err
+ }
+ return &resp, nil
+}
+
+// Poll fetches the latest state of the long-running operation.
+//
+// Poll also fetches the latest metadata, which can be retrieved by Metadata.
+//
+// If Poll fails, the error is returned and op is unmodified. If Poll succeeds and
+// the operation has completed with failure, the error is returned and op.Done will return true.
+// If Poll succeeds and the operation has completed successfully,
+// op.Done will return true, and the response of the operation is returned.
+// If Poll succeeds and the operation has not completed, the returned response and error are both nil.
+func (op *UpgradeApplianceOperation) Poll(ctx context.Context, opts ...gax.CallOption) (*vmmigrationpb.UpgradeApplianceResponse, error) {
+ var resp vmmigrationpb.UpgradeApplianceResponse
+ if err := op.lro.Poll(ctx, &resp, opts...); err != nil {
+ return nil, err
+ }
+ if !op.Done() {
+ return nil, nil
+ }
+ return &resp, nil
+}
+
+// Metadata returns metadata associated with the long-running operation.
+// Metadata itself does not contact the server, but Poll does.
+// To get the latest metadata, call this method after a successful call to Poll.
+// If the metadata is not available, the returned metadata and error are both nil.
+func (op *UpgradeApplianceOperation) Metadata() (*vmmigrationpb.OperationMetadata, error) {
+ var meta vmmigrationpb.OperationMetadata
+ if err := op.lro.Metadata(&meta); err == longrunning.ErrNoMetadata {
+ return nil, nil
+ } else if err != nil {
+ return nil, err
+ }
+ return &meta, nil
+}
+
+// Done reports whether the long-running operation has completed.
+func (op *UpgradeApplianceOperation) Done() bool {
+ return op.lro.Done()
+}
+
+// Name returns the name of the long-running operation.
+// The name is assigned by the server and is unique within the service from which the operation is created.
+func (op *UpgradeApplianceOperation) Name() string {
+ return op.lro.Name()
+}
+
// CloneJobIterator manages a stream of *vmmigrationpb.CloneJob.
type CloneJobIterator struct {
items []*vmmigrationpb.CloneJob
diff --git a/vmmigration/apiv1/vm_migration_client_example_test.go b/vmmigration/apiv1/vm_migration_client_example_test.go
index b095c09..177b942 100644
--- a/vmmigration/apiv1/vm_migration_client_example_test.go
+++ b/vmmigration/apiv1/vm_migration_client_example_test.go
@@ -363,6 +363,31 @@
}
}
+func ExampleClient_UpgradeAppliance() {
+ ctx := context.Background()
+ c, err := vmmigration.NewClient(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ defer c.Close()
+
+ req := &vmmigrationpb.UpgradeApplianceRequest{
+ // TODO: Fill request struct fields.
+ // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/vmmigration/v1#UpgradeApplianceRequest.
+ }
+ op, err := c.UpgradeAppliance(ctx, req)
+ if err != nil {
+ // TODO: Handle error.
+ }
+
+ resp, err := op.Wait(ctx)
+ if err != nil {
+ // TODO: Handle error.
+ }
+ // TODO: Use resp.
+ _ = resp
+}
+
func ExampleClient_CreateMigratingVm() {
ctx := context.Background()
c, err := vmmigration.NewClient(ctx)
diff --git a/vmmigration/go.mod b/vmmigration/go.mod
index 9aead68..0abc973 100644
--- a/vmmigration/go.mod
+++ b/vmmigration/go.mod
@@ -5,8 +5,8 @@
require (
cloud.google.com/go v0.102.1
github.com/googleapis/gax-go/v2 v2.4.0
- google.golang.org/api v0.85.0
- google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad
+ google.golang.org/api v0.87.0
+ google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f
google.golang.org/grpc v1.47.0
google.golang.org/protobuf v1.28.0
)
@@ -18,9 +18,9 @@
github.com/google/go-cmp v0.5.8 // indirect
github.com/googleapis/enterprise-certificate-proxy v0.1.0 // indirect
go.opencensus.io v0.23.0 // indirect
- golang.org/x/net v0.0.0-20220617184016-355a448f1bc9 // indirect
- golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb // indirect
- golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c // indirect
+ golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e // indirect
+ golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2 // indirect
+ golang.org/x/sys v0.0.0-20220624220833-87e55d714810 // indirect
golang.org/x/text v0.3.7 // indirect
google.golang.org/appengine v1.6.7 // indirect
)
diff --git a/vmmigration/go.sum b/vmmigration/go.sum
index f00d995..df87a96 100644
--- a/vmmigration/go.sum
+++ b/vmmigration/go.sum
@@ -162,6 +162,7 @@
github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8=
github.com/googleapis/enterprise-certificate-proxy v0.1.0 h1:zO8WHNx/MYiAKJ3d5spxZXZE6KHmIQGQcAzwUzV7qQw=
github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8=
@@ -290,8 +291,8 @@
golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
-golang.org/x/net v0.0.0-20220617184016-355a448f1bc9 h1:Yqz/iviulwKwAREEeUd3nbBFn0XuyJqkoft2IlrvOhc=
-golang.org/x/net v0.0.0-20220617184016-355a448f1bc9/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
+golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e h1:TsQ7F31D3bUCLeqPT0u+yjp1guoArKaNKmCr22PYgTQ=
+golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
@@ -311,8 +312,9 @@
golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
-golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb h1:8tDJ3aechhddbdPAxpycgXHJRMLpk/Ab+aa4OgdN5/g=
golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE=
+golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2 h1:+jnHzr9VPj32ykQVai5DNahi9+NSp7yYuCsl5eAQtL0=
+golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE=
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
@@ -383,8 +385,8 @@
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220610221304-9f5ed59c137d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c h1:aFV+BgZ4svzjfabn8ERpuB4JI4N6/rdy1iusx77G3oU=
-golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20220624220833-87e55d714810 h1:rHZQSjJdAI4Xf5Qzeh2bBc5YJIkPFVM6oDtMFYmgws0=
+golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
@@ -497,8 +499,8 @@
google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw=
google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg=
google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o=
-google.golang.org/api v0.85.0 h1:8rJoHuRxx+vCmZtAO/3k1dRLvYNVyTJtZ5oaFZvhgvc=
-google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g=
+google.golang.org/api v0.87.0 h1:pUQVF/F+X7Tl1lo4LJoJf5BOpjtmINU80p9XpYTU2p4=
+google.golang.org/api v0.87.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -585,8 +587,10 @@
google.golang.org/genproto v0.0.0-20220523171625-347a074981d8/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4=
google.golang.org/genproto v0.0.0-20220608133413-ed9918b62aac/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
-google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad h1:kqrS+lhvaMHCxul6sKQvKJ8nAAhlVItmZV822hYFH/U=
google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
+google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA=
+google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f h1:P8EiVSxZwC6xH2niv2N66aqwMtYFg+D54gbjpcqKJtM=
+google.golang.org/genproto v0.0.0-20220719170305-83ca9fad585f/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE=
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=