Skip to content

Commit

Permalink
Automated DCL import.
Browse files Browse the repository at this point in the history
  - 9f0883d Automatic import from cloud_mmv2_dcl_20220502_1531_RC00 by DCL Team <[email protected]>

GitOrigin-RevId: 9f0883d
  • Loading branch information
DCL Team authored and copybara-github committed May 2, 2022
1 parent a010ffc commit 1f322e1
Show file tree
Hide file tree
Showing 18 changed files with 30 additions and 54 deletions.
1 change: 1 addition & 0 deletions services/google/clouddeploy/alpha/delivery_pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `DeliveryPipeline`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -154,11 +154,6 @@ func newUpdateDeliveryPipelineUpdateDeliveryPipelineRequest(ctx context.Context,
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/deliveryPipelines/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1257,7 +1252,7 @@ func diffDeliveryPipeline(c *Client, desired, actual *DeliveryPipeline, opts ...
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateDeliveryPipelineUpdateDeliveryPipelineOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
1 change: 1 addition & 0 deletions services/google/clouddeploy/alpha/target.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `Target`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down
6 changes: 3 additions & 3 deletions services/google/clouddeploy/alpha/target_alpha_yaml_embed.go

Large diffs are not rendered by default.

7 changes: 1 addition & 6 deletions services/google/clouddeploy/alpha/target_internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,6 @@ func newUpdateTargetUpdateTargetRequest(ctx context.Context, f *Target, c *Clien
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/targets/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1089,7 +1084,7 @@ func diffTarget(c *Client, desired, actual *Target, opts ...dcl.ApplyOption) ([]
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateTargetUpdateTargetOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
1 change: 1 addition & 0 deletions services/google/clouddeploy/beta/delivery_pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `DeliveryPipeline`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -154,11 +154,6 @@ func newUpdateDeliveryPipelineUpdateDeliveryPipelineRequest(ctx context.Context,
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/deliveryPipelines/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1257,7 +1252,7 @@ func diffDeliveryPipeline(c *Client, desired, actual *DeliveryPipeline, opts ...
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateDeliveryPipelineUpdateDeliveryPipelineOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
1 change: 1 addition & 0 deletions services/google/clouddeploy/beta/target.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `Target`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down
6 changes: 3 additions & 3 deletions services/google/clouddeploy/beta/target_beta_yaml_embed.go

Large diffs are not rendered by default.

7 changes: 1 addition & 6 deletions services/google/clouddeploy/beta/target_internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,6 @@ func newUpdateTargetUpdateTargetRequest(ctx context.Context, f *Target, c *Clien
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/targets/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1089,7 +1084,7 @@ func diffTarget(c *Client, desired, actual *Target, opts ...dcl.ApplyOption) ([]
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateTargetUpdateTargetOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
1 change: 1 addition & 0 deletions services/google/clouddeploy/delivery_pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `DeliveryPipeline`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down
7 changes: 1 addition & 6 deletions services/google/clouddeploy/delivery_pipeline_internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,11 +154,6 @@ func newUpdateDeliveryPipelineUpdateDeliveryPipelineRequest(ctx context.Context,
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/deliveryPipelines/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1257,7 +1252,7 @@ func diffDeliveryPipeline(c *Client, desired, actual *DeliveryPipeline, opts ...
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateDeliveryPipelineUpdateDeliveryPipelineOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
6 changes: 3 additions & 3 deletions services/google/clouddeploy/delivery_pipeline_yaml_embed.go

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions services/google/clouddeploy/target.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ components:
type: string
x-dcl-go-name: Name
description: Name of the `Target`. Format is [a-z][a-z0-9\-]{0,62}.
x-kubernetes-immutable: true
project:
type: string
x-dcl-go-name: Project
Expand Down
7 changes: 1 addition & 6 deletions services/google/clouddeploy/target_internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,6 @@ func newUpdateTargetUpdateTargetRequest(ctx context.Context, f *Target, c *Clien
res := f
_ = res

if v, err := dcl.DeriveField("projects/%s/locations/%s/targets/%s", f.Name, dcl.SelfLinkToName(f.Project), dcl.SelfLinkToName(f.Location), dcl.SelfLinkToName(f.Name)); err != nil {
return nil, fmt.Errorf("error expanding Name into name: %w", err)
} else if !dcl.IsEmptyValueIndirect(v) {
req["name"] = v
}
if v := f.Description; !dcl.IsEmptyValueIndirect(v) {
req["description"] = v
}
Expand Down Expand Up @@ -1089,7 +1084,7 @@ func diffTarget(c *Client, desired, actual *Target, opts ...dcl.ApplyOption) ([]
var fn dcl.FieldName
var newDiffs []*dcl.FieldDiff
// New style diffs.
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.TriggersOperation("updateTargetUpdateTargetOperation")}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if ds, err := dcl.Diff(desired.Name, actual.Name, dcl.Info{OperationSelector: dcl.RequiresRecreate()}, fn.AddNest("Name")); len(ds) != 0 || err != nil {
if err != nil {
return nil, err
}
Expand Down
6 changes: 3 additions & 3 deletions services/google/clouddeploy/target_yaml_embed.go

Large diffs are not rendered by default.

0 comments on commit 1f322e1

Please sign in to comment.