assuredworkloads

package
v1.84.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2026 License: Apache-2.0 Imports: 14 Imported by: 7

Documentation

Overview

Copyright 2026 Google LLC. All Rights Reserved.

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. Package assuredworkloads contains support code for the assuredworkload service.

Copyright 2026 Google LLC. All Rights Reserved.

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. Package assuredworkloads defines operations in the declarative SDK.

Copyright 2026 Google LLC. All Rights Reserved.

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.

Copyright 2026 Google LLC. All Rights Reserved.

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.

Copyright 2026 Google LLC. All Rights Reserved.

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.

Copyright 2026 Google LLC. All Rights Reserved.

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.

Index

Constants

View Source
const WorkloadMaxPage = -1

Variables

View Source
var YAML_workload []byte

Functions

func DCLWorkloadSchema added in v1.10.3

func DCLWorkloadSchema() *dcl.Schema

Types

type Client

type Client struct {
	Config *dcl.Config
}

The Client is the base struct of all operations. This will receive the Get, Delete, List, and Apply operations on all resources.

func NewClient

func NewClient(c *dcl.Config) *Client

NewClient creates a client that retries all operations a few times each.

func (*Client) ApplyWorkload

func (c *Client) ApplyWorkload(ctx context.Context, rawDesired *Workload, opts ...dcl.ApplyOption) (*Workload, error)

func (*Client) DeleteAllWorkload

func (c *Client) DeleteAllWorkload(ctx context.Context, organization, location string, filter func(*Workload) bool) error

DeleteAllWorkload deletes all resources that the filter functions returns true on.

func (*Client) DeleteWorkload

func (c *Client) DeleteWorkload(ctx context.Context, r *Workload) error

func (*Client) GetWorkload

func (c *Client) GetWorkload(ctx context.Context, r *Workload) (*Workload, error)

func (*Client) ListWorkload

func (c *Client) ListWorkload(ctx context.Context, organization, location string) (*WorkloadList, error)

func (*Client) ListWorkloadWithMaxResults

func (c *Client) ListWorkloadWithMaxResults(ctx context.Context, organization, location string, pageSize int32) (*WorkloadList, error)

type Workload

type Workload struct {
	Name                           *string                          `json:"name"`
	DisplayName                    *string                          `json:"displayName"`
	Resources                      []WorkloadResources              `json:"resources"`
	ComplianceRegime               *WorkloadComplianceRegimeEnum    `json:"complianceRegime"`
	CreateTime                     *string                          `json:"createTime"`
	BillingAccount                 *string                          `json:"billingAccount"`
	PartnerServicesBillingAccount  *string                          `json:"partnerServicesBillingAccount"`
	Labels                         map[string]string                `json:"labels"`
	ProvisionedResourcesParent     *string                          `json:"provisionedResourcesParent"`
	KmsSettings                    *WorkloadKmsSettings             `json:"kmsSettings"`
	ResourceSettings               []WorkloadResourceSettings       `json:"resourceSettings"`
	KajEnrollmentState             *WorkloadKajEnrollmentStateEnum  `json:"kajEnrollmentState"`
	EnableSovereignControls        *bool                            `json:"enableSovereignControls"`
	SaaEnrollmentResponse          *WorkloadSaaEnrollmentResponse   `json:"saaEnrollmentResponse"`
	ComplianceStatus               *WorkloadComplianceStatus        `json:"complianceStatus"`
	CompliantButDisallowedServices []string                         `json:"compliantButDisallowedServices"`
	Partner                        *WorkloadPartnerEnum             `json:"partner"`
	PartnerPermissions             *WorkloadPartnerPermissions      `json:"partnerPermissions"`
	WorkloadOptions                *WorkloadWorkloadOptions         `json:"workloadOptions"`
	EkmProvisioningResponse        *WorkloadEkmProvisioningResponse `json:"ekmProvisioningResponse"`
	ViolationNotificationsEnabled  *bool                            `json:"violationNotificationsEnabled"`
	Organization                   *string                          `json:"organization"`
	Location                       *string                          `json:"location"`
}

func (*Workload) Describe

func (r *Workload) Describe() dcl.ServiceTypeVersion

Describe returns a simple description of this resource to ensure that automated tools can identify it.

func (*Workload) ID

func (r *Workload) ID() (string, error)

func (*Workload) String

func (r *Workload) String() string

type WorkloadComplianceRegimeEnum

type WorkloadComplianceRegimeEnum string

The enum WorkloadComplianceRegimeEnum.

func WorkloadComplianceRegimeEnumRef

func WorkloadComplianceRegimeEnumRef(s string) *WorkloadComplianceRegimeEnum

WorkloadComplianceRegimeEnumRef returns a *WorkloadComplianceRegimeEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadComplianceRegimeEnum) Validate

func (v WorkloadComplianceRegimeEnum) Validate() error

type WorkloadComplianceStatus added in v1.55.0

type WorkloadComplianceStatus struct {
	ActiveViolationCount       []int64 `json:"activeViolationCount"`
	AcknowledgedViolationCount []int64 `json:"acknowledgedViolationCount"`
	// contains filtered or unexported fields
}
var EmptyWorkloadComplianceStatus *WorkloadComplianceStatus = &WorkloadComplianceStatus{empty: true}

This object is used to assert a desired state where this WorkloadComplianceStatus is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadComplianceStatus) Empty added in v1.55.0

func (r *WorkloadComplianceStatus) Empty() bool

func (*WorkloadComplianceStatus) HashCode added in v1.55.0

func (r *WorkloadComplianceStatus) HashCode() string

func (*WorkloadComplianceStatus) String added in v1.55.0

func (r *WorkloadComplianceStatus) String() string

func (*WorkloadComplianceStatus) UnmarshalJSON added in v1.55.0

func (r *WorkloadComplianceStatus) UnmarshalJSON(data []byte) error

type WorkloadEkmProvisioningResponse added in v1.55.0

type WorkloadEkmProvisioningResponse struct {
	EkmProvisioningState        *WorkloadEkmProvisioningResponseEkmProvisioningStateEnum        `json:"ekmProvisioningState"`
	EkmProvisioningErrorDomain  *WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum  `json:"ekmProvisioningErrorDomain"`
	EkmProvisioningErrorMapping *WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum `json:"ekmProvisioningErrorMapping"`
	// contains filtered or unexported fields
}
var EmptyWorkloadEkmProvisioningResponse *WorkloadEkmProvisioningResponse = &WorkloadEkmProvisioningResponse{empty: true}

This object is used to assert a desired state where this WorkloadEkmProvisioningResponse is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadEkmProvisioningResponse) Empty added in v1.55.0

func (*WorkloadEkmProvisioningResponse) HashCode added in v1.55.0

func (*WorkloadEkmProvisioningResponse) String added in v1.55.0

func (*WorkloadEkmProvisioningResponse) UnmarshalJSON added in v1.55.0

func (r *WorkloadEkmProvisioningResponse) UnmarshalJSON(data []byte) error

type WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum added in v1.55.0

type WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum string

The enum WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum.

func WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnumRef added in v1.55.0

func WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnumRef(s string) *WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum

WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnumRef returns a *WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadEkmProvisioningResponseEkmProvisioningErrorDomainEnum) Validate added in v1.55.0

type WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum added in v1.55.0

type WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum string

The enum WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum.

func WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnumRef added in v1.55.0

func WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnumRef(s string) *WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum

WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnumRef returns a *WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadEkmProvisioningResponseEkmProvisioningErrorMappingEnum) Validate added in v1.55.0

type WorkloadEkmProvisioningResponseEkmProvisioningStateEnum added in v1.55.0

type WorkloadEkmProvisioningResponseEkmProvisioningStateEnum string

The enum WorkloadEkmProvisioningResponseEkmProvisioningStateEnum.

func WorkloadEkmProvisioningResponseEkmProvisioningStateEnumRef added in v1.55.0

func WorkloadEkmProvisioningResponseEkmProvisioningStateEnumRef(s string) *WorkloadEkmProvisioningResponseEkmProvisioningStateEnum

WorkloadEkmProvisioningResponseEkmProvisioningStateEnumRef returns a *WorkloadEkmProvisioningResponseEkmProvisioningStateEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadEkmProvisioningResponseEkmProvisioningStateEnum) Validate added in v1.55.0

type WorkloadKajEnrollmentStateEnum added in v1.55.0

type WorkloadKajEnrollmentStateEnum string

The enum WorkloadKajEnrollmentStateEnum.

func WorkloadKajEnrollmentStateEnumRef added in v1.55.0

func WorkloadKajEnrollmentStateEnumRef(s string) *WorkloadKajEnrollmentStateEnum

WorkloadKajEnrollmentStateEnumRef returns a *WorkloadKajEnrollmentStateEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadKajEnrollmentStateEnum) Validate added in v1.55.0

type WorkloadKmsSettings

type WorkloadKmsSettings struct {
	NextRotationTime *string `json:"nextRotationTime"`
	RotationPeriod   *string `json:"rotationPeriod"`
	// contains filtered or unexported fields
}
var EmptyWorkloadKmsSettings *WorkloadKmsSettings = &WorkloadKmsSettings{empty: true}

This object is used to assert a desired state where this WorkloadKmsSettings is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadKmsSettings) Empty

func (r *WorkloadKmsSettings) Empty() bool

func (*WorkloadKmsSettings) HashCode

func (r *WorkloadKmsSettings) HashCode() string

func (*WorkloadKmsSettings) String

func (r *WorkloadKmsSettings) String() string

func (*WorkloadKmsSettings) UnmarshalJSON

func (r *WorkloadKmsSettings) UnmarshalJSON(data []byte) error

type WorkloadList

type WorkloadList struct {
	Items []*Workload
	// contains filtered or unexported fields
}

func (*WorkloadList) HasNext

func (l *WorkloadList) HasNext() bool

func (*WorkloadList) Next

func (l *WorkloadList) Next(ctx context.Context, c *Client) error

type WorkloadPartnerEnum added in v1.55.0

type WorkloadPartnerEnum string

The enum WorkloadPartnerEnum.

func WorkloadPartnerEnumRef added in v1.55.0

func WorkloadPartnerEnumRef(s string) *WorkloadPartnerEnum

WorkloadPartnerEnumRef returns a *WorkloadPartnerEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadPartnerEnum) Validate added in v1.55.0

func (v WorkloadPartnerEnum) Validate() error

type WorkloadPartnerPermissions added in v1.55.0

type WorkloadPartnerPermissions struct {
	DataLogsViewer             *bool `json:"dataLogsViewer"`
	ServiceAccessApprover      *bool `json:"serviceAccessApprover"`
	AssuredWorkloadsMonitoring *bool `json:"assuredWorkloadsMonitoring"`
	// contains filtered or unexported fields
}
var EmptyWorkloadPartnerPermissions *WorkloadPartnerPermissions = &WorkloadPartnerPermissions{empty: true}

This object is used to assert a desired state where this WorkloadPartnerPermissions is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadPartnerPermissions) Empty added in v1.55.0

func (r *WorkloadPartnerPermissions) Empty() bool

func (*WorkloadPartnerPermissions) HashCode added in v1.55.0

func (r *WorkloadPartnerPermissions) HashCode() string

func (*WorkloadPartnerPermissions) String added in v1.55.0

func (r *WorkloadPartnerPermissions) String() string

func (*WorkloadPartnerPermissions) UnmarshalJSON added in v1.55.0

func (r *WorkloadPartnerPermissions) UnmarshalJSON(data []byte) error

type WorkloadResourceSettings

type WorkloadResourceSettings struct {
	ResourceId   *string                                   `json:"resourceId"`
	ResourceType *WorkloadResourceSettingsResourceTypeEnum `json:"resourceType"`
	DisplayName  *string                                   `json:"displayName"`
	// contains filtered or unexported fields
}
var EmptyWorkloadResourceSettings *WorkloadResourceSettings = &WorkloadResourceSettings{empty: true}

This object is used to assert a desired state where this WorkloadResourceSettings is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadResourceSettings) Empty

func (r *WorkloadResourceSettings) Empty() bool

func (*WorkloadResourceSettings) HashCode

func (r *WorkloadResourceSettings) HashCode() string

func (*WorkloadResourceSettings) String

func (r *WorkloadResourceSettings) String() string

func (*WorkloadResourceSettings) UnmarshalJSON

func (r *WorkloadResourceSettings) UnmarshalJSON(data []byte) error

type WorkloadResourceSettingsResourceTypeEnum

type WorkloadResourceSettingsResourceTypeEnum string

The enum WorkloadResourceSettingsResourceTypeEnum.

func WorkloadResourceSettingsResourceTypeEnumRef

func WorkloadResourceSettingsResourceTypeEnumRef(s string) *WorkloadResourceSettingsResourceTypeEnum

WorkloadResourceSettingsResourceTypeEnumRef returns a *WorkloadResourceSettingsResourceTypeEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadResourceSettingsResourceTypeEnum) Validate

type WorkloadResources

type WorkloadResources struct {
	ResourceId   *int64                             `json:"resourceId"`
	ResourceType *WorkloadResourcesResourceTypeEnum `json:"resourceType"`
	// contains filtered or unexported fields
}
var EmptyWorkloadResources *WorkloadResources = &WorkloadResources{empty: true}

This object is used to assert a desired state where this WorkloadResources is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadResources) Empty

func (r *WorkloadResources) Empty() bool

func (*WorkloadResources) HashCode

func (r *WorkloadResources) HashCode() string

func (*WorkloadResources) String

func (r *WorkloadResources) String() string

func (*WorkloadResources) UnmarshalJSON

func (r *WorkloadResources) UnmarshalJSON(data []byte) error

type WorkloadResourcesResourceTypeEnum

type WorkloadResourcesResourceTypeEnum string

The enum WorkloadResourcesResourceTypeEnum.

func WorkloadResourcesResourceTypeEnumRef

func WorkloadResourcesResourceTypeEnumRef(s string) *WorkloadResourcesResourceTypeEnum

WorkloadResourcesResourceTypeEnumRef returns a *WorkloadResourcesResourceTypeEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadResourcesResourceTypeEnum) Validate

type WorkloadSaaEnrollmentResponse added in v1.55.0

type WorkloadSaaEnrollmentResponse struct {
	SetupErrors []WorkloadSaaEnrollmentResponseSetupErrorsEnum `json:"setupErrors"`
	SetupStatus *WorkloadSaaEnrollmentResponseSetupStatusEnum  `json:"setupStatus"`
	// contains filtered or unexported fields
}
var EmptyWorkloadSaaEnrollmentResponse *WorkloadSaaEnrollmentResponse = &WorkloadSaaEnrollmentResponse{empty: true}

This object is used to assert a desired state where this WorkloadSaaEnrollmentResponse is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadSaaEnrollmentResponse) Empty added in v1.55.0

func (*WorkloadSaaEnrollmentResponse) HashCode added in v1.55.0

func (r *WorkloadSaaEnrollmentResponse) HashCode() string

func (*WorkloadSaaEnrollmentResponse) String added in v1.55.0

func (*WorkloadSaaEnrollmentResponse) UnmarshalJSON added in v1.55.0

func (r *WorkloadSaaEnrollmentResponse) UnmarshalJSON(data []byte) error

type WorkloadSaaEnrollmentResponseSetupErrorsEnum added in v1.55.0

type WorkloadSaaEnrollmentResponseSetupErrorsEnum string

The enum WorkloadSaaEnrollmentResponseSetupErrorsEnum.

func WorkloadSaaEnrollmentResponseSetupErrorsEnumRef added in v1.55.0

func WorkloadSaaEnrollmentResponseSetupErrorsEnumRef(s string) *WorkloadSaaEnrollmentResponseSetupErrorsEnum

WorkloadSaaEnrollmentResponseSetupErrorsEnumRef returns a *WorkloadSaaEnrollmentResponseSetupErrorsEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadSaaEnrollmentResponseSetupErrorsEnum) Validate added in v1.55.0

type WorkloadSaaEnrollmentResponseSetupStatusEnum added in v1.55.0

type WorkloadSaaEnrollmentResponseSetupStatusEnum string

The enum WorkloadSaaEnrollmentResponseSetupStatusEnum.

func WorkloadSaaEnrollmentResponseSetupStatusEnumRef added in v1.55.0

func WorkloadSaaEnrollmentResponseSetupStatusEnumRef(s string) *WorkloadSaaEnrollmentResponseSetupStatusEnum

WorkloadSaaEnrollmentResponseSetupStatusEnumRef returns a *WorkloadSaaEnrollmentResponseSetupStatusEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadSaaEnrollmentResponseSetupStatusEnum) Validate added in v1.55.0

type WorkloadWorkloadOptions added in v1.75.0

type WorkloadWorkloadOptions struct {
	KajEnrollmentType *WorkloadWorkloadOptionsKajEnrollmentTypeEnum `json:"kajEnrollmentType"`
	// contains filtered or unexported fields
}
var EmptyWorkloadWorkloadOptions *WorkloadWorkloadOptions = &WorkloadWorkloadOptions{empty: true}

This object is used to assert a desired state where this WorkloadWorkloadOptions is empty. Go lacks global const objects, but this object should be treated as one. Modifying this object will have undesirable results.

func (*WorkloadWorkloadOptions) Empty added in v1.75.0

func (r *WorkloadWorkloadOptions) Empty() bool

func (*WorkloadWorkloadOptions) HashCode added in v1.75.0

func (r *WorkloadWorkloadOptions) HashCode() string

func (*WorkloadWorkloadOptions) String added in v1.75.0

func (r *WorkloadWorkloadOptions) String() string

func (*WorkloadWorkloadOptions) UnmarshalJSON added in v1.75.0

func (r *WorkloadWorkloadOptions) UnmarshalJSON(data []byte) error

type WorkloadWorkloadOptionsKajEnrollmentTypeEnum added in v1.75.0

type WorkloadWorkloadOptionsKajEnrollmentTypeEnum string

The enum WorkloadWorkloadOptionsKajEnrollmentTypeEnum.

func WorkloadWorkloadOptionsKajEnrollmentTypeEnumRef added in v1.75.0

func WorkloadWorkloadOptionsKajEnrollmentTypeEnumRef(s string) *WorkloadWorkloadOptionsKajEnrollmentTypeEnum

WorkloadWorkloadOptionsKajEnrollmentTypeEnumRef returns a *WorkloadWorkloadOptionsKajEnrollmentTypeEnum with the value of string s If the empty string is provided, nil is returned.

func (WorkloadWorkloadOptionsKajEnrollmentTypeEnum) Validate added in v1.75.0

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL