From 1d12f2695148a57a0b370308067e6973f7fe07fb Mon Sep 17 00:00:00 2001 From: OCI DEX Release Bot Automation Date: Tue, 15 Oct 2024 16:44:42 +0000 Subject: [PATCH] Releasing version 65.76.0 --- CHANGELOG.md | 12 ++ common/version.go | 4 +- containerengine/cluster.go | 44 ++-- containerengine/cluster_create_options.go | 4 + containerengine/open_id_connect_discovery.go | 41 ++++ ..._id_connect_token_authentication_config.go | 77 +++++++ .../update_cluster_options_details.go | 4 + core/block_volume_replica.go | 5 + core/block_volume_replica_details.go | 6 + core/block_volume_replica_info.go | 5 + core/boot_volume_replica.go | 5 + core/boot_volume_replica_details.go | 6 + core/boot_volume_replica_info.go | 5 + core/boot_volume_source_details.go | 4 + ...e_from_boot_volume_backup_delta_details.go | 66 ++++++ core/create_boot_volume_details.go | 9 + ...volume_backup_policy_assignment_details.go | 6 + core/create_volume_details.go | 9 + core/create_volume_group_details.go | 9 + ...nce_configuration_create_volume_details.go | 9 + core/volume_backup_policy_assignment.go | 6 + core/volume_group_replica_details.go | 6 + core/volume_group_replica_info.go | 5 + core/volume_source_details.go | 4 + ...source_from_volume_backup_delta_details.go | 66 ++++++ ...ing_policy_compartment_request_response.go | 4 + ...ring_policy_attachment_request_response.go | 4 + ...create_steering_policy_request_response.go | 4 + dns/create_zone_details.go | 24 +++ ...ring_policy_attachment_request_response.go | 4 + ...delete_steering_policy_request_response.go | 4 + dns/dns_client.go | 135 ++++++++++++ dns/dnssec_config.go | 44 ++++ dns/dnssec_digest_type.go | 53 +++++ dns/dnssec_key_version_ds_data.go | 47 ++++ dns/dnssec_signing_algorithm.go | 53 +++++ dns/ksk_dnssec_key_version.go | 105 +++++++++ dns/list_zones_request_response.go | 48 +++++ ...promote_zone_dnssec_key_version_details.go | 40 ++++ ...one_dnssec_key_version_request_response.go | 166 ++++++++++++++ dns/stage_zone_dnssec_key_version_details.go | 40 ++++ ...one_dnssec_key_version_request_response.go | 166 ++++++++++++++ ...ring_policy_attachment_request_response.go | 4 + ...update_steering_policy_request_response.go | 4 + dns/update_zone_details.go | 24 +++ dns/zone.go | 26 +++ dns/zone_dnssec_state.go | 57 +++++ dns/zone_summary.go | 26 +++ dns/zsk_dnssec_key_version.go | 101 +++++++++ ...copy_deployment_backup_request_response.go | 6 + .../create_database_registration_details.go | 4 +- ...eate_deployment_backup_request_response.go | 6 + goldengate/create_deployment_details.go | 6 + goldengate/create_ogg_deployment_details.go | 2 + .../create_oracle_connection_details.go | 4 +- goldengate/deployment.go | 14 ++ goldengate/deployment_category.go | 60 ++++++ .../deployment_environment_collection.go | 39 ++++ goldengate/deployment_environment_summary.go | 73 +++++++ goldengate/deployment_summary.go | 28 ++- goldengate/deployment_type_summary.go | 54 +---- goldengate/environment_type.go | 56 +++++ goldengate/goldengate_client.go | 58 +++++ goldengate/group_to_roles_mapping_details.go | 57 +++++ ...eployment_environments_request_response.go | 202 ++++++++++++++++++ goldengate/ogg_deployment.go | 2 + .../test_connection_assignment_result.go | 4 + .../update_database_registration_details.go | 4 +- goldengate/update_deployment_details.go | 6 + .../update_group_to_roles_mapping_details.go | 57 +++++ goldengate/update_ogg_deployment_details.go | 2 + .../update_oracle_connection_details.go | 4 +- securityattribute/securityattribute_client.go | 36 ++-- zpr/zpr_client.go | 30 +-- 74 files changed, 2296 insertions(+), 118 deletions(-) create mode 100644 containerengine/open_id_connect_discovery.go create mode 100644 containerengine/open_id_connect_token_authentication_config.go create mode 100644 core/boot_volume_source_from_boot_volume_backup_delta_details.go create mode 100644 core/volume_source_from_volume_backup_delta_details.go create mode 100644 dns/dnssec_config.go create mode 100644 dns/dnssec_digest_type.go create mode 100644 dns/dnssec_key_version_ds_data.go create mode 100644 dns/dnssec_signing_algorithm.go create mode 100644 dns/ksk_dnssec_key_version.go create mode 100644 dns/promote_zone_dnssec_key_version_details.go create mode 100644 dns/promote_zone_dnssec_key_version_request_response.go create mode 100644 dns/stage_zone_dnssec_key_version_details.go create mode 100644 dns/stage_zone_dnssec_key_version_request_response.go create mode 100644 dns/zone_dnssec_state.go create mode 100644 dns/zsk_dnssec_key_version.go create mode 100644 goldengate/deployment_category.go create mode 100644 goldengate/deployment_environment_collection.go create mode 100644 goldengate/deployment_environment_summary.go create mode 100644 goldengate/environment_type.go create mode 100644 goldengate/group_to_roles_mapping_details.go create mode 100644 goldengate/list_deployment_environments_request_response.go create mode 100644 goldengate/update_group_to_roles_mapping_details.go diff --git a/CHANGELOG.md b/CHANGELOG.md index f7a8104965..833915e455 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,18 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) +## 65.76.0 - 2024-10-15 +### Added +- Support for open id connect discovery in the Oracle Kubernetes Engine service +- Support for DNS security extensions (DNSSEC) in the DNS service +- Support for restoring delta between backups to a new volume in the Block Volume service +- Support for cross region backup copy and replication for volumes encrypted with customer keys in the Block Volume service +- Support for list operation on deployment environments in the GoldenGate service +- Support for defining environment types for deployments in the GoldenGate service + +### Breaking Changes +- The type of property `Category` was changed from `DeploymentTypeSummaryCategoryEnum` to `DeploymentCategoryEnum` in the model `DeploymentTypeSummary` in the GoldenGate service + ## 65.75.2 - 2024-10-08 ### Added - Support for OCI Secure Desktops service diff --git a/common/version.go b/common/version.go index 7e36c4cd32..a49bbfdf19 100644 --- a/common/version.go +++ b/common/version.go @@ -12,8 +12,8 @@ import ( const ( major = "65" - minor = "75" - patch = "2" + minor = "76" + patch = "0" tag = "" ) diff --git a/containerengine/cluster.go b/containerengine/cluster.go index da6f644fca..65f3d4dd43 100644 --- a/containerengine/cluster.go +++ b/containerengine/cluster.go @@ -82,6 +82,9 @@ type Cluster struct { // Type of cluster Type ClusterTypeEnum `mandatory:"false" json:"type,omitempty"` + + // The cluster-specific OpenID Connect Discovery endpoint + OpenIdConnectDiscoveryEndpoint *string `mandatory:"false" json:"openIdConnectDiscoveryEndpoint"` } func (m Cluster) String() string { @@ -109,25 +112,26 @@ func (m Cluster) ValidateEnumValue() (bool, error) { // UnmarshalJSON unmarshals from json func (m *Cluster) UnmarshalJSON(data []byte) (e error) { model := struct { - Id *string `json:"id"` - Name *string `json:"name"` - CompartmentId *string `json:"compartmentId"` - EndpointConfig *ClusterEndpointConfig `json:"endpointConfig"` - VcnId *string `json:"vcnId"` - KubernetesVersion *string `json:"kubernetesVersion"` - KmsKeyId *string `json:"kmsKeyId"` - FreeformTags map[string]string `json:"freeformTags"` - DefinedTags map[string]map[string]interface{} `json:"definedTags"` - SystemTags map[string]map[string]interface{} `json:"systemTags"` - Options *ClusterCreateOptions `json:"options"` - Metadata *ClusterMetadata `json:"metadata"` - LifecycleState ClusterLifecycleStateEnum `json:"lifecycleState"` - LifecycleDetails *string `json:"lifecycleDetails"` - Endpoints *ClusterEndpoints `json:"endpoints"` - AvailableKubernetesUpgrades []string `json:"availableKubernetesUpgrades"` - ImagePolicyConfig *ImagePolicyConfig `json:"imagePolicyConfig"` - ClusterPodNetworkOptions []clusterpodnetworkoptiondetails `json:"clusterPodNetworkOptions"` - Type ClusterTypeEnum `json:"type"` + Id *string `json:"id"` + Name *string `json:"name"` + CompartmentId *string `json:"compartmentId"` + EndpointConfig *ClusterEndpointConfig `json:"endpointConfig"` + VcnId *string `json:"vcnId"` + KubernetesVersion *string `json:"kubernetesVersion"` + KmsKeyId *string `json:"kmsKeyId"` + FreeformTags map[string]string `json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + SystemTags map[string]map[string]interface{} `json:"systemTags"` + Options *ClusterCreateOptions `json:"options"` + Metadata *ClusterMetadata `json:"metadata"` + LifecycleState ClusterLifecycleStateEnum `json:"lifecycleState"` + LifecycleDetails *string `json:"lifecycleDetails"` + Endpoints *ClusterEndpoints `json:"endpoints"` + AvailableKubernetesUpgrades []string `json:"availableKubernetesUpgrades"` + ImagePolicyConfig *ImagePolicyConfig `json:"imagePolicyConfig"` + ClusterPodNetworkOptions []clusterpodnetworkoptiondetails `json:"clusterPodNetworkOptions"` + Type ClusterTypeEnum `json:"type"` + OpenIdConnectDiscoveryEndpoint *string `json:"openIdConnectDiscoveryEndpoint"` }{} e = json.Unmarshal(data, &model) @@ -183,5 +187,7 @@ func (m *Cluster) UnmarshalJSON(data []byte) (e error) { } m.Type = model.Type + m.OpenIdConnectDiscoveryEndpoint = model.OpenIdConnectDiscoveryEndpoint + return } diff --git a/containerengine/cluster_create_options.go b/containerengine/cluster_create_options.go index eafbcf7c20..e9c0a3dac1 100644 --- a/containerengine/cluster_create_options.go +++ b/containerengine/cluster_create_options.go @@ -35,6 +35,10 @@ type ClusterCreateOptions struct { PersistentVolumeConfig *PersistentVolumeConfigDetails `mandatory:"false" json:"persistentVolumeConfig"` ServiceLbConfig *ServiceLbConfigDetails `mandatory:"false" json:"serviceLbConfig"` + + OpenIdConnectTokenAuthenticationConfig *OpenIdConnectTokenAuthenticationConfig `mandatory:"false" json:"openIdConnectTokenAuthenticationConfig"` + + OpenIdConnectDiscovery *OpenIdConnectDiscovery `mandatory:"false" json:"openIdConnectDiscovery"` } func (m ClusterCreateOptions) String() string { diff --git a/containerengine/open_id_connect_discovery.go b/containerengine/open_id_connect_discovery.go new file mode 100644 index 0000000000..b4a842ea0e --- /dev/null +++ b/containerengine/open_id_connect_discovery.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Kubernetes Engine API +// +// API for the Kubernetes Engine service (also known as the Container Engine for Kubernetes service). Use this API to build, deploy, +// and manage cloud-native applications. For more information, see +// Overview of Kubernetes Engine (https://docs.cloud.oracle.com/iaas/Content/ContEng/Concepts/contengoverview.htm). +// + +package containerengine + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// OpenIdConnectDiscovery The property that define the status of the OIDC Discovery feature for a cluster. +type OpenIdConnectDiscovery struct { + + // Whether the cluster has OIDC Discovery enabled. Defaults to false. If set to true, the cluster will be assigned a public OIDC Discovery endpoint. + IsOpenIdConnectDiscoveryEnabled *bool `mandatory:"false" json:"isOpenIdConnectDiscoveryEnabled"` +} + +func (m OpenIdConnectDiscovery) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m OpenIdConnectDiscovery) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/containerengine/open_id_connect_token_authentication_config.go b/containerengine/open_id_connect_token_authentication_config.go new file mode 100644 index 0000000000..f8b2c9157b --- /dev/null +++ b/containerengine/open_id_connect_token_authentication_config.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Kubernetes Engine API +// +// API for the Kubernetes Engine service (also known as the Container Engine for Kubernetes service). Use this API to build, deploy, +// and manage cloud-native applications. For more information, see +// Overview of Kubernetes Engine (https://docs.cloud.oracle.com/iaas/Content/ContEng/Concepts/contengoverview.htm). +// + +package containerengine + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// OpenIdConnectTokenAuthenticationConfig The properties that configure OIDC token authentication in kube-apiserver. +// For more information, see Configuring the API Server (https://kubernetes.io/docs/reference/access-authn-authz/authentication/#using-flags). +type OpenIdConnectTokenAuthenticationConfig struct { + + // Whether the cluster has OIDC Auth Config enabled. Defaults to false. + IsOpenIdConnectAuthEnabled *bool `mandatory:"true" json:"isOpenIdConnectAuthEnabled"` + + // URL of the provider that allows the API server to discover public signing keys. + // Only URLs that use the https:// scheme are accepted. This is typically the provider's discovery URL, + // changed to have an empty path. + IssuerUrl *string `mandatory:"false" json:"issuerUrl"` + + // A client id that all tokens must be issued for. + ClientId *string `mandatory:"false" json:"clientId"` + + // JWT claim to use as the user name. By default sub, which is expected to be a unique identifier of the end + // user. Admins can choose other claims, such as email or name, depending on their provider. However, claims + // other than email will be prefixed with the issuer URL to prevent naming clashes with other plugins. + UsernameClaim *string `mandatory:"false" json:"usernameClaim"` + + // Prefix prepended to username claims to prevent clashes with existing names (such as system:users). + // For example, the value oidc: will create usernames like oidc:jane.doe. If this flag isn't provided and + // --oidc-username-claim is a value other than email the prefix defaults to ( Issuer URL )# where + // ( Issuer URL ) is the value of --oidc-issuer-url. The value - can be used to disable all prefixing. + UsernamePrefix *string `mandatory:"false" json:"usernamePrefix"` + + // JWT claim to use as the user's group. If the claim is present it must be an array of strings. + GroupsClaim *string `mandatory:"false" json:"groupsClaim"` + + // Prefix prepended to group claims to prevent clashes with existing names (such as system:groups). + GroupsPrefix *string `mandatory:"false" json:"groupsPrefix"` + + // A key=value pair that describes a required claim in the ID Token. If set, the claim is verified to be present + // in the ID Token with a matching value. Repeat this flag to specify multiple claims. + RequiredClaims []KeyValue `mandatory:"false" json:"requiredClaims"` + + // A Base64 encoded public RSA or ECDSA certificates used to signed your identity provider's web certificate. + CaCertificate *string `mandatory:"false" json:"caCertificate"` + + // The signing algorithms accepted. Default is ["RS256"]. + SigningAlgorithms []string `mandatory:"false" json:"signingAlgorithms"` +} + +func (m OpenIdConnectTokenAuthenticationConfig) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m OpenIdConnectTokenAuthenticationConfig) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/containerengine/update_cluster_options_details.go b/containerengine/update_cluster_options_details.go index 8351a2c734..ec8d7ae17f 100644 --- a/containerengine/update_cluster_options_details.go +++ b/containerengine/update_cluster_options_details.go @@ -26,6 +26,10 @@ type UpdateClusterOptionsDetails struct { PersistentVolumeConfig *PersistentVolumeConfigDetails `mandatory:"false" json:"persistentVolumeConfig"` ServiceLbConfig *ServiceLbConfigDetails `mandatory:"false" json:"serviceLbConfig"` + + OpenIdConnectTokenAuthenticationConfig *OpenIdConnectTokenAuthenticationConfig `mandatory:"false" json:"openIdConnectTokenAuthenticationConfig"` + + OpenIdConnectDiscovery *OpenIdConnectDiscovery `mandatory:"false" json:"openIdConnectDiscovery"` } func (m UpdateClusterOptionsDetails) String() string { diff --git a/core/block_volume_replica.go b/core/block_volume_replica.go index 045fa2636f..9f1c4932ff 100644 --- a/core/block_volume_replica.go +++ b/core/block_volume_replica.go @@ -78,6 +78,11 @@ type BlockVolumeReplica struct { // The OCID of the volume group replica. VolumeGroupReplicaId *string `mandatory:"false" json:"volumeGroupReplicaId"` + + // The OCID of the Vault service key to assign as the master encryption key for the block volume replica, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` } func (m BlockVolumeReplica) String() string { diff --git a/core/block_volume_replica_details.go b/core/block_volume_replica_details.go index 8d1879205a..331dd5c8c2 100644 --- a/core/block_volume_replica_details.go +++ b/core/block_volume_replica_details.go @@ -31,6 +31,12 @@ type BlockVolumeReplicaDetails struct { // A user-friendly name. Does not have to be unique, and it's changeable. // Avoid entering confidential information. DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Vault service key which is the master encryption key for the cross region block volume replicas, which will be used in the destination region to encrypt the block volume replica's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrrKmsKeyId *string `mandatory:"false" json:"xrrKmsKeyId"` } func (m BlockVolumeReplicaDetails) String() string { diff --git a/core/block_volume_replica_info.go b/core/block_volume_replica_info.go index d915126c87..7741877e1d 100644 --- a/core/block_volume_replica_info.go +++ b/core/block_volume_replica_info.go @@ -34,6 +34,11 @@ type BlockVolumeReplicaInfo struct { // The availability domain of the block volume replica. // Example: `Uocm:PHX-AD-1` AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the Vault service key to assign as the master encryption key for the block volume replica, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` } func (m BlockVolumeReplicaInfo) String() string { diff --git a/core/boot_volume_replica.go b/core/boot_volume_replica.go index a18af18692..d8ab97e17f 100644 --- a/core/boot_volume_replica.go +++ b/core/boot_volume_replica.go @@ -81,6 +81,11 @@ type BootVolumeReplica struct { // The OCID of the volume group replica. VolumeGroupReplicaId *string `mandatory:"false" json:"volumeGroupReplicaId"` + + // The OCID of the Vault service key to assign as the master encryption key for the boot volume replica, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` } func (m BootVolumeReplica) String() string { diff --git a/core/boot_volume_replica_details.go b/core/boot_volume_replica_details.go index 566c56d208..ab139d2d48 100644 --- a/core/boot_volume_replica_details.go +++ b/core/boot_volume_replica_details.go @@ -31,6 +31,12 @@ type BootVolumeReplicaDetails struct { // A user-friendly name. Does not have to be unique, and it's changeable. // Avoid entering confidential information. DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Vault service key which is the master encryption key for the cross region boot volume replicas, which will be used in the destination region to encrypt the boot volume replica's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrrKmsKeyId *string `mandatory:"false" json:"xrrKmsKeyId"` } func (m BootVolumeReplicaDetails) String() string { diff --git a/core/boot_volume_replica_info.go b/core/boot_volume_replica_info.go index 9aa46150f3..62874afc2e 100644 --- a/core/boot_volume_replica_info.go +++ b/core/boot_volume_replica_info.go @@ -34,6 +34,11 @@ type BootVolumeReplicaInfo struct { // The availability domain of the boot volume replica. // Example: `Uocm:PHX-AD-1` AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the Vault service key to assign as the master encryption key for the block volume replica, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` } func (m BootVolumeReplicaInfo) String() string { diff --git a/core/boot_volume_source_details.go b/core/boot_volume_source_details.go index ecaaf1e246..d4ac8635e9 100644 --- a/core/boot_volume_source_details.go +++ b/core/boot_volume_source_details.go @@ -68,6 +68,10 @@ func (m *bootvolumesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interfa mm := BootVolumeSourceFromBootVolumeReplicaDetails{} err = json.Unmarshal(data, &mm) return mm, err + case "bootVolumeBackupDelta": + mm := BootVolumeSourceFromBootVolumeBackupDeltaDetails{} + err = json.Unmarshal(data, &mm) + return mm, err default: common.Logf("Recieved unsupported enum value for BootVolumeSourceDetails: %s.", m.Type) return *m, nil diff --git a/core/boot_volume_source_from_boot_volume_backup_delta_details.go b/core/boot_volume_source_from_boot_volume_backup_delta_details.go new file mode 100644 index 0000000000..a8b9fc2b1a --- /dev/null +++ b/core/boot_volume_source_from_boot_volume_backup_delta_details.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// The required permissions are documented in the +// Details for the Core Services (https://docs.cloud.oracle.com/iaas/Content/Identity/Reference/corepolicyreference.htm) article. +// + +package core + +import ( + "encoding/json" + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// BootVolumeSourceFromBootVolumeBackupDeltaDetails Specifies the boot volume backups (first & second) and block size in bytes. +type BootVolumeSourceFromBootVolumeBackupDeltaDetails struct { + + // The OCID of the first boot volume backup. + FirstBackupId *string `mandatory:"true" json:"firstBackupId"` + + // The OCID of the second boot volume backup. + SecondBackupId *string `mandatory:"true" json:"secondBackupId"` + + // Block size in bytes to be considered while performing volume restore. The value must be a power of 2; ranging from 4KB (4096 bytes) to 1MB (1048576 bytes). If omitted, defaults to 4,096 bytes (4 KiB). + ChangeBlockSizeInBytes *int64 `mandatory:"false" json:"changeBlockSizeInBytes"` +} + +func (m BootVolumeSourceFromBootVolumeBackupDeltaDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m BootVolumeSourceFromBootVolumeBackupDeltaDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} + +// MarshalJSON marshals to json representation +func (m BootVolumeSourceFromBootVolumeBackupDeltaDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeBootVolumeSourceFromBootVolumeBackupDeltaDetails BootVolumeSourceFromBootVolumeBackupDeltaDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeBootVolumeSourceFromBootVolumeBackupDeltaDetails + }{ + "bootVolumeBackupDelta", + (MarshalTypeBootVolumeSourceFromBootVolumeBackupDeltaDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/core/create_boot_volume_details.go b/core/create_boot_volume_details.go index 2cabb02aa0..e29f505e14 100644 --- a/core/create_boot_volume_details.go +++ b/core/create_boot_volume_details.go @@ -82,6 +82,12 @@ type CreateBootVolumeDetails struct { // The list of autotune policies to be enabled for this volume. AutotunePolicies []AutotunePolicy `mandatory:"false" json:"autotunePolicies"` + + // The OCID of the Vault service key which is the master encryption key for the boot volume cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m CreateBootVolumeDetails) String() string { @@ -115,6 +121,7 @@ func (m *CreateBootVolumeDetails) UnmarshalJSON(data []byte) (e error) { IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` BootVolumeReplicas []BootVolumeReplicaDetails `json:"bootVolumeReplicas"` AutotunePolicies []autotunepolicy `json:"autotunePolicies"` + XrcKmsKeyId *string `json:"xrcKmsKeyId"` CompartmentId *string `json:"compartmentId"` SourceDetails bootvolumesourcedetails `json:"sourceDetails"` }{} @@ -158,6 +165,8 @@ func (m *CreateBootVolumeDetails) UnmarshalJSON(data []byte) (e error) { m.AutotunePolicies[i] = nil } } + m.XrcKmsKeyId = model.XrcKmsKeyId + m.CompartmentId = model.CompartmentId nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) diff --git a/core/create_volume_backup_policy_assignment_details.go b/core/create_volume_backup_policy_assignment_details.go index fb2fa2471c..c3fc3f6950 100644 --- a/core/create_volume_backup_policy_assignment_details.go +++ b/core/create_volume_backup_policy_assignment_details.go @@ -29,6 +29,12 @@ type CreateVolumeBackupPolicyAssignmentDetails struct { // The OCID of the volume backup policy to assign to the volume. PolicyId *string `mandatory:"true" json:"policyId"` + + // The OCID of the Vault service key which is the master encryption key for the block / boot volume cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m CreateVolumeBackupPolicyAssignmentDetails) String() string { diff --git a/core/create_volume_details.go b/core/create_volume_details.go index bbf187fe64..977ac058d2 100644 --- a/core/create_volume_details.go +++ b/core/create_volume_details.go @@ -93,6 +93,12 @@ type CreateVolumeDetails struct { // The list of autotune policies to be enabled for this volume. AutotunePolicies []AutotunePolicy `mandatory:"false" json:"autotunePolicies"` + + // The OCID of the Vault service key which is the master encryption key for the block volume cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m CreateVolumeDetails) String() string { @@ -129,6 +135,7 @@ func (m *CreateVolumeDetails) UnmarshalJSON(data []byte) (e error) { IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` BlockVolumeReplicas []BlockVolumeReplicaDetails `json:"blockVolumeReplicas"` AutotunePolicies []autotunepolicy `json:"autotunePolicies"` + XrcKmsKeyId *string `json:"xrcKmsKeyId"` CompartmentId *string `json:"compartmentId"` }{} @@ -185,6 +192,8 @@ func (m *CreateVolumeDetails) UnmarshalJSON(data []byte) (e error) { m.AutotunePolicies[i] = nil } } + m.XrcKmsKeyId = model.XrcKmsKeyId + m.CompartmentId = model.CompartmentId return diff --git a/core/create_volume_group_details.go b/core/create_volume_group_details.go index 1a2437e9d7..9f2af6b3ce 100644 --- a/core/create_volume_group_details.go +++ b/core/create_volume_group_details.go @@ -57,6 +57,12 @@ type CreateVolumeGroupDetails struct { // The clusterPlacementGroup Id of the volume group for volume group placement. ClusterPlacementGroupId *string `mandatory:"false" json:"clusterPlacementGroupId"` + + // The OCID of the Vault service key which is the master encryption key for the volume's cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m CreateVolumeGroupDetails) String() string { @@ -84,6 +90,7 @@ func (m *CreateVolumeGroupDetails) UnmarshalJSON(data []byte) (e error) { FreeformTags map[string]string `json:"freeformTags"` VolumeGroupReplicas []VolumeGroupReplicaDetails `json:"volumeGroupReplicas"` ClusterPlacementGroupId *string `json:"clusterPlacementGroupId"` + XrcKmsKeyId *string `json:"xrcKmsKeyId"` AvailabilityDomain *string `json:"availabilityDomain"` CompartmentId *string `json:"compartmentId"` SourceDetails volumegroupsourcedetails `json:"sourceDetails"` @@ -106,6 +113,8 @@ func (m *CreateVolumeGroupDetails) UnmarshalJSON(data []byte) (e error) { copy(m.VolumeGroupReplicas, model.VolumeGroupReplicas) m.ClusterPlacementGroupId = model.ClusterPlacementGroupId + m.XrcKmsKeyId = model.XrcKmsKeyId + m.AvailabilityDomain = model.AvailabilityDomain m.CompartmentId = model.CompartmentId diff --git a/core/instance_configuration_create_volume_details.go b/core/instance_configuration_create_volume_details.go index 8d794531fc..d14942c873 100644 --- a/core/instance_configuration_create_volume_details.go +++ b/core/instance_configuration_create_volume_details.go @@ -83,6 +83,12 @@ type InstanceConfigurationCreateVolumeDetails struct { // The list of autotune policies enabled for this volume. AutotunePolicies []InstanceConfigurationAutotunePolicy `mandatory:"false" json:"autotunePolicies"` + + // The OCID of the Vault service key which is the master encryption key for the block volume cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m InstanceConfigurationCreateVolumeDetails) String() string { @@ -118,6 +124,7 @@ func (m *InstanceConfigurationCreateVolumeDetails) UnmarshalJSON(data []byte) (e SizeInGBs *int64 `json:"sizeInGBs"` SourceDetails instanceconfigurationvolumesourcedetails `json:"sourceDetails"` AutotunePolicies []instanceconfigurationautotunepolicy `json:"autotunePolicies"` + XrcKmsKeyId *string `json:"xrcKmsKeyId"` }{} e = json.Unmarshal(data, &model) @@ -171,5 +178,7 @@ func (m *InstanceConfigurationCreateVolumeDetails) UnmarshalJSON(data []byte) (e m.AutotunePolicies[i] = nil } } + m.XrcKmsKeyId = model.XrcKmsKeyId + return } diff --git a/core/volume_backup_policy_assignment.go b/core/volume_backup_policy_assignment.go index 7322b96f8c..871de28e4f 100644 --- a/core/volume_backup_policy_assignment.go +++ b/core/volume_backup_policy_assignment.go @@ -38,6 +38,12 @@ type VolumeBackupPolicyAssignment struct { // The date and time the volume backup policy was assigned to the volume. The format is // defined by RFC3339 (https://tools.ietf.org/html/rfc3339). TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the Vault service key which is the master encryption key for the block / boot volume cross region backups, which will be used in the destination region to encrypt the backup's encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrcKmsKeyId *string `mandatory:"false" json:"xrcKmsKeyId"` } func (m VolumeBackupPolicyAssignment) String() string { diff --git a/core/volume_group_replica_details.go b/core/volume_group_replica_details.go index 7a98f3ae58..7dfae065a9 100644 --- a/core/volume_group_replica_details.go +++ b/core/volume_group_replica_details.go @@ -31,6 +31,12 @@ type VolumeGroupReplicaDetails struct { // A user-friendly name. Does not have to be unique, and it's changeable. // Avoid entering confidential information. DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Vault service key which is the master encryption key for the cross region volume group's replicas, which will be used in the destination region to encrypt the volume group's replicas encryption keys. + // For more information about the Vault service and encryption keys, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + XrrKmsKeyId *string `mandatory:"false" json:"xrrKmsKeyId"` } func (m VolumeGroupReplicaDetails) String() string { diff --git a/core/volume_group_replica_info.go b/core/volume_group_replica_info.go index f730deec9a..2d5a8cdae2 100644 --- a/core/volume_group_replica_info.go +++ b/core/volume_group_replica_info.go @@ -34,6 +34,11 @@ type VolumeGroupReplicaInfo struct { // The availability domain of the boot volume replica replica. // Example: `Uocm:PHX-AD-1` AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the Vault service key to assign as the master encryption key for the block volume replica, see + // Overview of Vault service (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` } func (m VolumeGroupReplicaInfo) String() string { diff --git a/core/volume_source_details.go b/core/volume_source_details.go index bcea6aaf3d..8d8538519a 100644 --- a/core/volume_source_details.go +++ b/core/volume_source_details.go @@ -70,6 +70,10 @@ func (m *volumesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{} mm := VolumeSourceFromVolumeBackupDetails{} err = json.Unmarshal(data, &mm) return mm, err + case "volumeBackupDelta": + mm := VolumeSourceFromVolumeBackupDeltaDetails{} + err = json.Unmarshal(data, &mm) + return mm, err default: common.Logf("Recieved unsupported enum value for VolumeSourceDetails: %s.", m.Type) return *m, nil diff --git a/core/volume_source_from_volume_backup_delta_details.go b/core/volume_source_from_volume_backup_delta_details.go new file mode 100644 index 0000000000..b3223d6369 --- /dev/null +++ b/core/volume_source_from_volume_backup_delta_details.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// The required permissions are documented in the +// Details for the Core Services (https://docs.cloud.oracle.com/iaas/Content/Identity/Reference/corepolicyreference.htm) article. +// + +package core + +import ( + "encoding/json" + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// VolumeSourceFromVolumeBackupDeltaDetails Specifies the volume backups (first & second) and block size in bytes. +type VolumeSourceFromVolumeBackupDeltaDetails struct { + + // The OCID of the first volume backup. + FirstBackupId *string `mandatory:"true" json:"firstBackupId"` + + // The OCID of the second volume backup. + SecondBackupId *string `mandatory:"true" json:"secondBackupId"` + + // Block size in bytes to be considered while performing volume restore. The value must be a power of 2; ranging from 4KB (4096 bytes) to 1MB (1048576 bytes). If omitted, defaults to 4,096 bytes (4 KiB). + ChangeBlockSizeInBytes *int64 `mandatory:"false" json:"changeBlockSizeInBytes"` +} + +func (m VolumeSourceFromVolumeBackupDeltaDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m VolumeSourceFromVolumeBackupDeltaDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} + +// MarshalJSON marshals to json representation +func (m VolumeSourceFromVolumeBackupDeltaDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeSourceFromVolumeBackupDeltaDetails VolumeSourceFromVolumeBackupDeltaDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeSourceFromVolumeBackupDeltaDetails + }{ + "volumeBackupDelta", + (MarshalTypeVolumeSourceFromVolumeBackupDeltaDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/dns/change_steering_policy_compartment_request_response.go b/dns/change_steering_policy_compartment_request_response.go index e26a364663..8980eecce4 100644 --- a/dns/change_steering_policy_compartment_request_response.go +++ b/dns/change_steering_policy_compartment_request_response.go @@ -101,6 +101,10 @@ type ChangeSteeringPolicyCompartmentResponse struct { // Unique Oracle-assigned identifier for the request. If you need to // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` } func (response ChangeSteeringPolicyCompartmentResponse) String() string { diff --git a/dns/create_steering_policy_attachment_request_response.go b/dns/create_steering_policy_attachment_request_response.go index b17c64ccf0..0b6ad30f19 100644 --- a/dns/create_steering_policy_attachment_request_response.go +++ b/dns/create_steering_policy_attachment_request_response.go @@ -102,6 +102,10 @@ type CreateSteeringPolicyAttachmentResponse struct { // Unique Oracle-assigned identifier for the request. If you need to // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` } func (response CreateSteeringPolicyAttachmentResponse) String() string { diff --git a/dns/create_steering_policy_request_response.go b/dns/create_steering_policy_request_response.go index 8404a04fd3..2ae884166c 100644 --- a/dns/create_steering_policy_request_response.go +++ b/dns/create_steering_policy_request_response.go @@ -102,6 +102,10 @@ type CreateSteeringPolicyResponse struct { // Unique Oracle-assigned identifier for the request. If you need to // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` } func (response CreateSteeringPolicyResponse) String() string { diff --git a/dns/create_zone_details.go b/dns/create_zone_details.go index 113ffe8cab..c21faa1501 100644 --- a/dns/create_zone_details.go +++ b/dns/create_zone_details.go @@ -59,6 +59,27 @@ type CreateZoneDetails struct { // The scope of the zone. Scope ScopeEnum `mandatory:"false" json:"scope,omitempty"` + + // The state of DNSSEC on the zone. + // For DNSSEC to function, every parent zone in the DNS tree up to the top-level domain (or an independent + // trust anchor) must also have DNSSEC correctly set up. + // After enabling DNSSEC, you must add a DS record to the zone's parent zone containing the + // `KskDnssecKeyVersion` data. You can find the DS data in the `dsData` attribute of the `KskDnssecKeyVersion`. + // Then, use the `PromoteZoneDnssecKeyVersion` operation to promote the `KskDnssecKeyVersion`. + // New `KskDnssecKeyVersion`s are generated annually, a week before the existing `KskDnssecKeyVersion`'s expiration. + // To rollover a `KskDnssecKeyVersion`, you must replace the parent zone's DS record containing the old + // `KskDnssecKeyVersion` data with the data from the new `KskDnssecKeyVersion`. + // To remove the old DS record without causing service disruption, wait until the old DS record's TTL has + // expired, and the new DS record has propagated. After the DS replacement has been completed, then the + // `PromoteZoneDnssecKeyVersion` operation must be called. + // Metrics are emitted in the `oci_dns` namespace daily for each `KskDnssecKeyVersion` indicating how many + // days are left until expiration. + // We recommend that you set up alarms and notifications for KskDnssecKeyVersion expiration so that the + // necessary parent zone updates can be made and the `PromoteZoneDnssecKeyVersion` operation can be called. + // Enabling DNSSEC results in additional records in DNS responses which increases their size and can + // cause higher response latency. + // For more information, see DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm). + DnssecState ZoneDnssecStateEnum `mandatory:"false" json:"dnssecState,omitempty"` } // GetName returns Name @@ -97,6 +118,9 @@ func (m CreateZoneDetails) ValidateEnumValue() (bool, error) { if _, ok := GetMappingScopeEnum(string(m.Scope)); !ok && m.Scope != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", m.Scope, strings.Join(GetScopeEnumStringValues(), ","))) } + if _, ok := GetMappingZoneDnssecStateEnum(string(m.DnssecState)); !ok && m.DnssecState != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DnssecState: %s. Supported values are: %s.", m.DnssecState, strings.Join(GetZoneDnssecStateEnumStringValues(), ","))) + } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) } diff --git a/dns/delete_steering_policy_attachment_request_response.go b/dns/delete_steering_policy_attachment_request_response.go index d64baaaec0..6550d9c392 100644 --- a/dns/delete_steering_policy_attachment_request_response.go +++ b/dns/delete_steering_policy_attachment_request_response.go @@ -97,6 +97,10 @@ type DeleteSteeringPolicyAttachmentResponse struct { // Unique Oracle-assigned identifier for the request. If you need to // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` } func (response DeleteSteeringPolicyAttachmentResponse) String() string { diff --git a/dns/delete_steering_policy_request_response.go b/dns/delete_steering_policy_request_response.go index 27e93e4ca1..285ede2ce1 100644 --- a/dns/delete_steering_policy_request_response.go +++ b/dns/delete_steering_policy_request_response.go @@ -97,6 +97,10 @@ type DeleteSteeringPolicyResponse struct { // Unique Oracle-assigned identifier for the request. If you need to // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` } func (response DeleteSteeringPolicyResponse) String() string { diff --git a/dns/dns_client.go b/dns/dns_client.go index 3621b124eb..0095d89891 100644 --- a/dns/dns_client.go +++ b/dns/dns_client.go @@ -2657,6 +2657,141 @@ func (client DnsClient) patchZoneRecords(ctx context.Context, request common.OCI return response, err } +// PromoteZoneDnssecKeyVersion Promotes a specified `DnssecKeyVersion` on the zone. +// If the `DnssecKeyVersion` identified in the request body is a key signing key (KSK) that is replacing +// another `DnssecKeyVersion`, then the old `DnssecKeyVersion` is scheduled for removal from the zone. +// For key signing keys (KSKs), you must create the DS record with the new key information **before** promoting +// the new key to establish a chain of trust. To avoid a service disruption, remove the old DS record as soon +// as its TTL (time to live) expires. +// For more information, see DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm). +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/dns/PromoteZoneDnssecKeyVersion.go.html to see an example of how to use PromoteZoneDnssecKeyVersion API. +// A default retry strategy applies to this operation PromoteZoneDnssecKeyVersion() +func (client DnsClient) PromoteZoneDnssecKeyVersion(ctx context.Context, request PromoteZoneDnssecKeyVersionRequest) (response PromoteZoneDnssecKeyVersionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.DefaultRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.promoteZoneDnssecKeyVersion, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = PromoteZoneDnssecKeyVersionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = PromoteZoneDnssecKeyVersionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(PromoteZoneDnssecKeyVersionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into PromoteZoneDnssecKeyVersionResponse") + } + return +} + +// promoteZoneDnssecKeyVersion implements the OCIOperation interface (enables retrying operations) +func (client DnsClient) promoteZoneDnssecKeyVersion(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/zones/{zoneId}/actions/promoteDnssecKeyVersion", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response PromoteZoneDnssecKeyVersionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/dns/20180115/Zone/PromoteZoneDnssecKeyVersion" + err = common.PostProcessServiceError(err, "Dns", "PromoteZoneDnssecKeyVersion", apiReferenceLink) + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// StageZoneDnssecKeyVersion Stages a new `DnssecKeyVersion` on the zone. Staging is a process that generates a new "successor" key version +// that replaces an existing "predecessor" key version. +// **Note:** A new key-signing key (KSK) version is inert until you update the parent zone DS records. +// For more information, see the DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm) documentation. +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/dns/StageZoneDnssecKeyVersion.go.html to see an example of how to use StageZoneDnssecKeyVersion API. +// A default retry strategy applies to this operation StageZoneDnssecKeyVersion() +func (client DnsClient) StageZoneDnssecKeyVersion(ctx context.Context, request StageZoneDnssecKeyVersionRequest) (response StageZoneDnssecKeyVersionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.DefaultRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.stageZoneDnssecKeyVersion, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = StageZoneDnssecKeyVersionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = StageZoneDnssecKeyVersionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(StageZoneDnssecKeyVersionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into StageZoneDnssecKeyVersionResponse") + } + return +} + +// stageZoneDnssecKeyVersion implements the OCIOperation interface (enables retrying operations) +func (client DnsClient) stageZoneDnssecKeyVersion(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/zones/{zoneId}/actions/stageDnssecKeyVersion", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response StageZoneDnssecKeyVersionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/dns/20180115/Zone/StageZoneDnssecKeyVersion" + err = common.PostProcessServiceError(err, "Dns", "StageZoneDnssecKeyVersion", apiReferenceLink) + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + // UpdateDomainRecords Replaces records in the specified zone at a domain with the records specified in the request body. // If a specified record does not exist, it will be created. If the record exists, then it will be updated to // represent the record in the body of the request. If a record in the zone does not exist in the request body, diff --git a/dns/dnssec_config.go b/dns/dnssec_config.go new file mode 100644 index 0000000000..01b1d53501 --- /dev/null +++ b/dns/dnssec_config.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// DnssecConfig DNSSEC configuration data. +// A zone may have a maximum of 10 `DnssecKeyVersions`, regardless of signing key type. +type DnssecConfig struct { + + // A read-only array of key signing key (KSK) versions. + KskDnssecKeyVersions []KskDnssecKeyVersion `mandatory:"false" json:"kskDnssecKeyVersions"` + + // A read-only array of zone signing key (ZSK) versions. + ZskDnssecKeyVersions []ZskDnssecKeyVersion `mandatory:"false" json:"zskDnssecKeyVersions"` +} + +func (m DnssecConfig) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m DnssecConfig) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/dns/dnssec_digest_type.go b/dns/dnssec_digest_type.go new file mode 100644 index 0000000000..2eef9f3a27 --- /dev/null +++ b/dns/dnssec_digest_type.go @@ -0,0 +1,53 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "strings" +) + +// DnssecDigestTypeEnum Enum with underlying type: string +type DnssecDigestTypeEnum string + +// Set of constants representing the allowable values for DnssecDigestTypeEnum +const ( + DnssecDigestTypeSha256 DnssecDigestTypeEnum = "SHA_256" +) + +var mappingDnssecDigestTypeEnum = map[string]DnssecDigestTypeEnum{ + "SHA_256": DnssecDigestTypeSha256, +} + +var mappingDnssecDigestTypeEnumLowerCase = map[string]DnssecDigestTypeEnum{ + "sha_256": DnssecDigestTypeSha256, +} + +// GetDnssecDigestTypeEnumValues Enumerates the set of values for DnssecDigestTypeEnum +func GetDnssecDigestTypeEnumValues() []DnssecDigestTypeEnum { + values := make([]DnssecDigestTypeEnum, 0) + for _, v := range mappingDnssecDigestTypeEnum { + values = append(values, v) + } + return values +} + +// GetDnssecDigestTypeEnumStringValues Enumerates the set of values in String for DnssecDigestTypeEnum +func GetDnssecDigestTypeEnumStringValues() []string { + return []string{ + "SHA_256", + } +} + +// GetMappingDnssecDigestTypeEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingDnssecDigestTypeEnum(val string) (DnssecDigestTypeEnum, bool) { + enum, ok := mappingDnssecDigestTypeEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/dnssec_key_version_ds_data.go b/dns/dnssec_key_version_ds_data.go new file mode 100644 index 0000000000..b523b75bc5 --- /dev/null +++ b/dns/dnssec_key_version_ds_data.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// DnssecKeyVersionDsData Data for a parent zone DS record corresponding to this key-signing key (KSK). +type DnssecKeyVersionDsData struct { + + // Presentation-format DS record data that must be added to the parent zone. For more information about RDATA, + // see Supported DNS Resource Record Types (https://docs.cloud.oracle.com/iaas/Content/DNS/Reference/supporteddnsresource.htm) + Rdata *string `mandatory:"false" json:"rdata"` + + // The type of the digest associated with the rdata. + DigestType DnssecDigestTypeEnum `mandatory:"false" json:"digestType,omitempty"` +} + +func (m DnssecKeyVersionDsData) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m DnssecKeyVersionDsData) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if _, ok := GetMappingDnssecDigestTypeEnum(string(m.DigestType)); !ok && m.DigestType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DigestType: %s. Supported values are: %s.", m.DigestType, strings.Join(GetDnssecDigestTypeEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/dns/dnssec_signing_algorithm.go b/dns/dnssec_signing_algorithm.go new file mode 100644 index 0000000000..b75a41181e --- /dev/null +++ b/dns/dnssec_signing_algorithm.go @@ -0,0 +1,53 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "strings" +) + +// DnssecSigningAlgorithmEnum Enum with underlying type: string +type DnssecSigningAlgorithmEnum string + +// Set of constants representing the allowable values for DnssecSigningAlgorithmEnum +const ( + DnssecSigningAlgorithmRsasha256 DnssecSigningAlgorithmEnum = "RSASHA256" +) + +var mappingDnssecSigningAlgorithmEnum = map[string]DnssecSigningAlgorithmEnum{ + "RSASHA256": DnssecSigningAlgorithmRsasha256, +} + +var mappingDnssecSigningAlgorithmEnumLowerCase = map[string]DnssecSigningAlgorithmEnum{ + "rsasha256": DnssecSigningAlgorithmRsasha256, +} + +// GetDnssecSigningAlgorithmEnumValues Enumerates the set of values for DnssecSigningAlgorithmEnum +func GetDnssecSigningAlgorithmEnumValues() []DnssecSigningAlgorithmEnum { + values := make([]DnssecSigningAlgorithmEnum, 0) + for _, v := range mappingDnssecSigningAlgorithmEnum { + values = append(values, v) + } + return values +} + +// GetDnssecSigningAlgorithmEnumStringValues Enumerates the set of values in String for DnssecSigningAlgorithmEnum +func GetDnssecSigningAlgorithmEnumStringValues() []string { + return []string{ + "RSASHA256", + } +} + +// GetMappingDnssecSigningAlgorithmEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingDnssecSigningAlgorithmEnum(val string) (DnssecSigningAlgorithmEnum, bool) { + enum, ok := mappingDnssecSigningAlgorithmEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/ksk_dnssec_key_version.go b/dns/ksk_dnssec_key_version.go new file mode 100644 index 0000000000..bb550f9786 --- /dev/null +++ b/dns/ksk_dnssec_key_version.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// KskDnssecKeyVersion A key signing key (KSK) version. The version information contains timing and configuration data corresponding to the KSK that is used to +// apply DNSSEC on the zone. +type KskDnssecKeyVersion struct { + + // The UUID of the `DnssecKeyVersion`. + Uuid *string `mandatory:"false" json:"uuid"` + + // The signing algorithm used for the key. + Algorithm DnssecSigningAlgorithmEnum `mandatory:"false" json:"algorithm,omitempty"` + + // The length of the corresponding private key in bytes, expressed as an integer. + LengthInBytes *int `mandatory:"false" json:"lengthInBytes"` + + // The date and time the key version was created, expressed in RFC 3339 timestamp format. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The date and time the key version was, or will be, published, expressed in RFC 3339 timestamp format. This is + // when the zone contents will include a DNSKEY record corresponding to the key material. + // **Example:** `2016-07-22T17:23:59:00Z` + TimePublished *common.SDKTime `mandatory:"false" json:"timePublished"` + + // The date and time the key version went, or will go, active, expressed in RFC 3339 timestamp format. This is + // when the key material will be used to generate RRSIGs. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeActivated *common.SDKTime `mandatory:"false" json:"timeActivated"` + + // The date and time the key version went, or will go, inactive, expressed in RFC 3339 timestamp format. This + // is when the key material will no longer be used to generate RRSIGs. For a key signing key (KSK) `DnssecKeyVersion`, this is + // populated after `PromoteZoneDnssecKeyVersion` has been called on its successor `DnssecKeyVersion`. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeInactivated *common.SDKTime `mandatory:"false" json:"timeInactivated"` + + // The date and time the key version was, or will be, unpublished, expressed in RFC 3339 timestamp format. This + // is when the corresponding DNSKEY will be removed from zone contents. For a key signing key (KSK) `DnssecKeyVersion`, this is + // populated after `PromoteZoneDnssecKeyVersion` has been called on its successor `DnssecKeyVersion`. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeUnpublished *common.SDKTime `mandatory:"false" json:"timeUnpublished"` + + // The date and time at which the recommended key version publication/activation lifetime ends, expressed in RFC + // 3339 timestamp format. This is when the corresponding DNSKEY should no longer exist in zone contents and no + // longer be used to generate RRSIGs. For a key sigining key (KSK), if `PromoteZoneDnssecKeyVersion` has not been called on this + // `DnssecKeyVersion`'s successor then it will remain active for arbitrarily long past its recommended lifetime. + // This prevents service disruption at the potential increased risk of key compromise. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeExpired *common.SDKTime `mandatory:"false" json:"timeExpired"` + + // The date and time the key version was promoted expressed in RFC 3339 timestamp format. + // **Example:** `2016-07-22T17:23:59:00Z` + TimePromoted *common.SDKTime `mandatory:"false" json:"timePromoted"` + + // When populated, this is the UUID of the `DnssecKeyVersion` that this `DnssecKeyVersion` will replace or has + // replaced. + PredecessorDnssecKeyVersionUuid *string `mandatory:"false" json:"predecessorDnssecKeyVersionUuid"` + + // When populated, this is the UUID of the `DnssecKeyVersion` that will replace, or has replaced, this + // `DnssecKeyVersion`. + SuccessorDnssecKeyVersionUuid *string `mandatory:"false" json:"successorDnssecKeyVersionUuid"` + + // The key tag associated with the `DnssecKeyVersion`. This key tag will be present in the RRSIG and DS records + // associated with the key material for this `DnssecKeyVersion`. For more information about key tags, see + // RFC 4034 (https://tools.ietf.org/html/rfc4034). + KeyTag *int `mandatory:"false" json:"keyTag"` + + // An array of data for DS records corresponding with this key version. An entry will exist for each + // supported DS digest algorithm. + DsData []DnssecKeyVersionDsData `mandatory:"false" json:"dsData"` +} + +func (m KskDnssecKeyVersion) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m KskDnssecKeyVersion) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if _, ok := GetMappingDnssecSigningAlgorithmEnum(string(m.Algorithm)); !ok && m.Algorithm != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Algorithm: %s. Supported values are: %s.", m.Algorithm, strings.Join(GetDnssecSigningAlgorithmEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/dns/list_zones_request_response.go b/dns/list_zones_request_response.go index b56b3380a6..bfd691a8e0 100644 --- a/dns/list_zones_request_response.go +++ b/dns/list_zones_request_response.go @@ -70,6 +70,9 @@ type ListZonesRequest struct { // Search for zones that are associated with a TSIG key. TsigKeyId *string `mandatory:"false" contributesTo:"query" name:"tsigKeyId"` + // Search for zones that have the given `DnssecState`. + DnssecState ListZonesDnssecStateEnum `mandatory:"false" contributesTo:"query" name:"dnssecState" omitEmpty:"true"` + // Metadata about the request. This information will not be transmitted to the service, but // represents information that the SDK will consume to drive retry behavior. RequestMetadata common.RequestMetadata @@ -121,6 +124,9 @@ func (request ListZonesRequest) ValidateEnumValue() (bool, error) { if _, ok := GetMappingListZonesScopeEnum(string(request.Scope)); !ok && request.Scope != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", request.Scope, strings.Join(GetListZonesScopeEnumStringValues(), ","))) } + if _, ok := GetMappingListZonesDnssecStateEnum(string(request.DnssecState)); !ok && request.DnssecState != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DnssecState: %s. Supported values are: %s.", request.DnssecState, strings.Join(GetListZonesDnssecStateEnumStringValues(), ","))) + } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) } @@ -387,3 +393,45 @@ func GetMappingListZonesScopeEnum(val string) (ListZonesScopeEnum, bool) { enum, ok := mappingListZonesScopeEnumLowerCase[strings.ToLower(val)] return enum, ok } + +// ListZonesDnssecStateEnum Enum with underlying type: string +type ListZonesDnssecStateEnum string + +// Set of constants representing the allowable values for ListZonesDnssecStateEnum +const ( + ListZonesDnssecStateEnabled ListZonesDnssecStateEnum = "ENABLED" + ListZonesDnssecStateDisabled ListZonesDnssecStateEnum = "DISABLED" +) + +var mappingListZonesDnssecStateEnum = map[string]ListZonesDnssecStateEnum{ + "ENABLED": ListZonesDnssecStateEnabled, + "DISABLED": ListZonesDnssecStateDisabled, +} + +var mappingListZonesDnssecStateEnumLowerCase = map[string]ListZonesDnssecStateEnum{ + "enabled": ListZonesDnssecStateEnabled, + "disabled": ListZonesDnssecStateDisabled, +} + +// GetListZonesDnssecStateEnumValues Enumerates the set of values for ListZonesDnssecStateEnum +func GetListZonesDnssecStateEnumValues() []ListZonesDnssecStateEnum { + values := make([]ListZonesDnssecStateEnum, 0) + for _, v := range mappingListZonesDnssecStateEnum { + values = append(values, v) + } + return values +} + +// GetListZonesDnssecStateEnumStringValues Enumerates the set of values in String for ListZonesDnssecStateEnum +func GetListZonesDnssecStateEnumStringValues() []string { + return []string{ + "ENABLED", + "DISABLED", + } +} + +// GetMappingListZonesDnssecStateEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingListZonesDnssecStateEnum(val string) (ListZonesDnssecStateEnum, bool) { + enum, ok := mappingListZonesDnssecStateEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/promote_zone_dnssec_key_version_details.go b/dns/promote_zone_dnssec_key_version_details.go new file mode 100644 index 0000000000..d982639b30 --- /dev/null +++ b/dns/promote_zone_dnssec_key_version_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// PromoteZoneDnssecKeyVersionDetails Details for promoting a `DnssecKeyVersion` on a zone. +type PromoteZoneDnssecKeyVersionDetails struct { + + // The UUID of the `DnssecKeyVersion` that is being promoted. + DnssecKeyVersionUuid *string `mandatory:"true" json:"dnssecKeyVersionUuid"` +} + +func (m PromoteZoneDnssecKeyVersionDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m PromoteZoneDnssecKeyVersionDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/dns/promote_zone_dnssec_key_version_request_response.go b/dns/promote_zone_dnssec_key_version_request_response.go new file mode 100644 index 0000000000..7f3054c3c1 --- /dev/null +++ b/dns/promote_zone_dnssec_key_version_request_response.go @@ -0,0 +1,166 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "net/http" + "strings" +) + +// PromoteZoneDnssecKeyVersionRequest wrapper for the PromoteZoneDnssecKeyVersion operation +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/dns/PromoteZoneDnssecKeyVersion.go.html to see an example of how to use PromoteZoneDnssecKeyVersionRequest. +type PromoteZoneDnssecKeyVersionRequest struct { + + // The OCID of the target zone. + ZoneId *string `mandatory:"true" contributesTo:"path" name:"zoneId"` + + // Details for promoting a `DnssecKeyVersion`. + PromoteZoneDnssecKeyVersionDetails `contributesTo:"body"` + + // The `If-Match` header field makes the request method conditional on the + // existence of at least one current representation of the target resource, + // when the field-value is `*`, or having a current representation of the + // target resource that has an entity-tag matching a member of the list of + // entity-tags provided in the field-value. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"If-Match"` + + // The `If-Unmodified-Since` header field makes the request method + // conditional on the selected representation's last modification date being + // earlier than or equal to the date provided in the field-value. This + // field accomplishes the same purpose as If-Match for cases where the user + // agent does not have an entity-tag for the representation. + IfUnmodifiedSince *string `mandatory:"false" contributesTo:"header" name:"If-Unmodified-Since"` + + // A token that uniquely identifies a request so it can be retried in case + // of a timeout or server error without risk of executing that same action + // again. Retry tokens expire after 24 hours, but can be invalidated before + // then due to conflicting operations (for example, if a resource has been + // deleted and purged from the system, then a retry of the original creation + // request may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. If you need + // to contact Oracle about a particular request, please provide + // the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Specifies to operate only on resources that have a matching DNS scope. + Scope PromoteZoneDnssecKeyVersionScopeEnum `mandatory:"false" contributesTo:"query" name:"scope" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request PromoteZoneDnssecKeyVersionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request PromoteZoneDnssecKeyVersionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + _, err := request.ValidateEnumValue() + if err != nil { + return http.Request{}, err + } + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request PromoteZoneDnssecKeyVersionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request PromoteZoneDnssecKeyVersionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (request PromoteZoneDnssecKeyVersionRequest) ValidateEnumValue() (bool, error) { + errMessage := []string{} + if _, ok := GetMappingPromoteZoneDnssecKeyVersionScopeEnum(string(request.Scope)); !ok && request.Scope != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", request.Scope, strings.Join(GetPromoteZoneDnssecKeyVersionScopeEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} + +// PromoteZoneDnssecKeyVersionResponse wrapper for the PromoteZoneDnssecKeyVersion operation +type PromoteZoneDnssecKeyVersionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to + // contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response PromoteZoneDnssecKeyVersionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response PromoteZoneDnssecKeyVersionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// PromoteZoneDnssecKeyVersionScopeEnum Enum with underlying type: string +type PromoteZoneDnssecKeyVersionScopeEnum string + +// Set of constants representing the allowable values for PromoteZoneDnssecKeyVersionScopeEnum +const ( + PromoteZoneDnssecKeyVersionScopeGlobal PromoteZoneDnssecKeyVersionScopeEnum = "GLOBAL" + PromoteZoneDnssecKeyVersionScopePrivate PromoteZoneDnssecKeyVersionScopeEnum = "PRIVATE" +) + +var mappingPromoteZoneDnssecKeyVersionScopeEnum = map[string]PromoteZoneDnssecKeyVersionScopeEnum{ + "GLOBAL": PromoteZoneDnssecKeyVersionScopeGlobal, + "PRIVATE": PromoteZoneDnssecKeyVersionScopePrivate, +} + +var mappingPromoteZoneDnssecKeyVersionScopeEnumLowerCase = map[string]PromoteZoneDnssecKeyVersionScopeEnum{ + "global": PromoteZoneDnssecKeyVersionScopeGlobal, + "private": PromoteZoneDnssecKeyVersionScopePrivate, +} + +// GetPromoteZoneDnssecKeyVersionScopeEnumValues Enumerates the set of values for PromoteZoneDnssecKeyVersionScopeEnum +func GetPromoteZoneDnssecKeyVersionScopeEnumValues() []PromoteZoneDnssecKeyVersionScopeEnum { + values := make([]PromoteZoneDnssecKeyVersionScopeEnum, 0) + for _, v := range mappingPromoteZoneDnssecKeyVersionScopeEnum { + values = append(values, v) + } + return values +} + +// GetPromoteZoneDnssecKeyVersionScopeEnumStringValues Enumerates the set of values in String for PromoteZoneDnssecKeyVersionScopeEnum +func GetPromoteZoneDnssecKeyVersionScopeEnumStringValues() []string { + return []string{ + "GLOBAL", + "PRIVATE", + } +} + +// GetMappingPromoteZoneDnssecKeyVersionScopeEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingPromoteZoneDnssecKeyVersionScopeEnum(val string) (PromoteZoneDnssecKeyVersionScopeEnum, bool) { + enum, ok := mappingPromoteZoneDnssecKeyVersionScopeEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/stage_zone_dnssec_key_version_details.go b/dns/stage_zone_dnssec_key_version_details.go new file mode 100644 index 0000000000..62a7ee22d0 --- /dev/null +++ b/dns/stage_zone_dnssec_key_version_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// StageZoneDnssecKeyVersionDetails Details for staging a `DnssecKeyVersion` on a zone. +type StageZoneDnssecKeyVersionDetails struct { + + // The UUID of the `DnssecKeyVersion` for which a new successor should be generated. + PredecessorDnssecKeyVersionUuid *string `mandatory:"true" json:"predecessorDnssecKeyVersionUuid"` +} + +func (m StageZoneDnssecKeyVersionDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m StageZoneDnssecKeyVersionDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/dns/stage_zone_dnssec_key_version_request_response.go b/dns/stage_zone_dnssec_key_version_request_response.go new file mode 100644 index 0000000000..872a5b7e8a --- /dev/null +++ b/dns/stage_zone_dnssec_key_version_request_response.go @@ -0,0 +1,166 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "net/http" + "strings" +) + +// StageZoneDnssecKeyVersionRequest wrapper for the StageZoneDnssecKeyVersion operation +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/dns/StageZoneDnssecKeyVersion.go.html to see an example of how to use StageZoneDnssecKeyVersionRequest. +type StageZoneDnssecKeyVersionRequest struct { + + // The OCID of the target zone. + ZoneId *string `mandatory:"true" contributesTo:"path" name:"zoneId"` + + // Details for staging a DnssecKeyVersion. + StageZoneDnssecKeyVersionDetails `contributesTo:"body"` + + // The `If-Match` header field makes the request method conditional on the + // existence of at least one current representation of the target resource, + // when the field-value is `*`, or having a current representation of the + // target resource that has an entity-tag matching a member of the list of + // entity-tags provided in the field-value. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"If-Match"` + + // The `If-Unmodified-Since` header field makes the request method + // conditional on the selected representation's last modification date being + // earlier than or equal to the date provided in the field-value. This + // field accomplishes the same purpose as If-Match for cases where the user + // agent does not have an entity-tag for the representation. + IfUnmodifiedSince *string `mandatory:"false" contributesTo:"header" name:"If-Unmodified-Since"` + + // A token that uniquely identifies a request so it can be retried in case + // of a timeout or server error without risk of executing that same action + // again. Retry tokens expire after 24 hours, but can be invalidated before + // then due to conflicting operations (for example, if a resource has been + // deleted and purged from the system, then a retry of the original creation + // request may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. If you need + // to contact Oracle about a particular request, please provide + // the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Specifies to operate only on resources that have a matching DNS scope. + Scope StageZoneDnssecKeyVersionScopeEnum `mandatory:"false" contributesTo:"query" name:"scope" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request StageZoneDnssecKeyVersionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request StageZoneDnssecKeyVersionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + _, err := request.ValidateEnumValue() + if err != nil { + return http.Request{}, err + } + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request StageZoneDnssecKeyVersionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request StageZoneDnssecKeyVersionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (request StageZoneDnssecKeyVersionRequest) ValidateEnumValue() (bool, error) { + errMessage := []string{} + if _, ok := GetMappingStageZoneDnssecKeyVersionScopeEnum(string(request.Scope)); !ok && request.Scope != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", request.Scope, strings.Join(GetStageZoneDnssecKeyVersionScopeEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} + +// StageZoneDnssecKeyVersionResponse wrapper for the StageZoneDnssecKeyVersion operation +type StageZoneDnssecKeyVersionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to + // contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response StageZoneDnssecKeyVersionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response StageZoneDnssecKeyVersionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// StageZoneDnssecKeyVersionScopeEnum Enum with underlying type: string +type StageZoneDnssecKeyVersionScopeEnum string + +// Set of constants representing the allowable values for StageZoneDnssecKeyVersionScopeEnum +const ( + StageZoneDnssecKeyVersionScopeGlobal StageZoneDnssecKeyVersionScopeEnum = "GLOBAL" + StageZoneDnssecKeyVersionScopePrivate StageZoneDnssecKeyVersionScopeEnum = "PRIVATE" +) + +var mappingStageZoneDnssecKeyVersionScopeEnum = map[string]StageZoneDnssecKeyVersionScopeEnum{ + "GLOBAL": StageZoneDnssecKeyVersionScopeGlobal, + "PRIVATE": StageZoneDnssecKeyVersionScopePrivate, +} + +var mappingStageZoneDnssecKeyVersionScopeEnumLowerCase = map[string]StageZoneDnssecKeyVersionScopeEnum{ + "global": StageZoneDnssecKeyVersionScopeGlobal, + "private": StageZoneDnssecKeyVersionScopePrivate, +} + +// GetStageZoneDnssecKeyVersionScopeEnumValues Enumerates the set of values for StageZoneDnssecKeyVersionScopeEnum +func GetStageZoneDnssecKeyVersionScopeEnumValues() []StageZoneDnssecKeyVersionScopeEnum { + values := make([]StageZoneDnssecKeyVersionScopeEnum, 0) + for _, v := range mappingStageZoneDnssecKeyVersionScopeEnum { + values = append(values, v) + } + return values +} + +// GetStageZoneDnssecKeyVersionScopeEnumStringValues Enumerates the set of values in String for StageZoneDnssecKeyVersionScopeEnum +func GetStageZoneDnssecKeyVersionScopeEnumStringValues() []string { + return []string{ + "GLOBAL", + "PRIVATE", + } +} + +// GetMappingStageZoneDnssecKeyVersionScopeEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingStageZoneDnssecKeyVersionScopeEnum(val string) (StageZoneDnssecKeyVersionScopeEnum, bool) { + enum, ok := mappingStageZoneDnssecKeyVersionScopeEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/update_steering_policy_attachment_request_response.go b/dns/update_steering_policy_attachment_request_response.go index 382f5a3e54..9d1d3f6043 100644 --- a/dns/update_steering_policy_attachment_request_response.go +++ b/dns/update_steering_policy_attachment_request_response.go @@ -104,6 +104,10 @@ type UpdateSteeringPolicyAttachmentResponse struct { // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + // The current version of the resource, ending with a // representation-specific suffix. This value may be used in If-Match // and If-None-Match headers for later requests of the same resource. diff --git a/dns/update_steering_policy_request_response.go b/dns/update_steering_policy_request_response.go index 4455ca4a2c..59f4deb260 100644 --- a/dns/update_steering_policy_request_response.go +++ b/dns/update_steering_policy_request_response.go @@ -104,6 +104,10 @@ type UpdateSteeringPolicyResponse struct { // contact Oracle about a particular request, please provide the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + // Unique Oracle-assigned identifier for the asynchronous request. + // You can use this to query status of the asynchronous operation. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + // The current version of the resource, ending with a // representation-specific suffix. This value may be used in If-Match // and If-None-Match headers for later requests of the same resource. diff --git a/dns/update_zone_details.go b/dns/update_zone_details.go index 4b35f00282..8e4551312d 100644 --- a/dns/update_zone_details.go +++ b/dns/update_zone_details.go @@ -32,6 +32,27 @@ type UpdateZoneDetails struct { // **Example:** `{"Operations": {"CostCenter": "42"}}` DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + // The state of DNSSEC on the zone. + // For DNSSEC to function, every parent zone in the DNS tree up to the top-level domain (or an independent + // trust anchor) must also have DNSSEC correctly set up. + // After enabling DNSSEC, you must add a DS record to the zone's parent zone containing the + // `KskDnssecKeyVersion` data. You can find the DS data in the `dsData` attribute of the `KskDnssecKeyVersion`. + // Then, use the `PromoteZoneDnssecKeyVersion` operation to promote the `KskDnssecKeyVersion`. + // New `KskDnssecKeyVersion`s are generated annually, a week before the existing `KskDnssecKeyVersion`'s expiration. + // To rollover a `KskDnssecKeyVersion`, you must replace the parent zone's DS record containing the old + // `KskDnssecKeyVersion` data with the data from the new `KskDnssecKeyVersion`. + // To remove the old DS record without causing service disruption, wait until the old DS record's TTL has + // expired, and the new DS record has propagated. After the DS replacement has been completed, then the + // `PromoteZoneDnssecKeyVersion` operation must be called. + // Metrics are emitted in the `oci_dns` namespace daily for each `KskDnssecKeyVersion` indicating how many + // days are left until expiration. + // We recommend that you set up alarms and notifications for KskDnssecKeyVersion expiration so that the + // necessary parent zone updates can be made and the `PromoteZoneDnssecKeyVersion` operation can be called. + // Enabling DNSSEC results in additional records in DNS responses which increases their size and can + // cause higher response latency. + // For more information, see DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm). + DnssecState ZoneDnssecStateEnum `mandatory:"false" json:"dnssecState,omitempty"` + // External master servers for the zone. `externalMasters` becomes a // required parameter when the `zoneType` value is `SECONDARY`. ExternalMasters []ExternalMaster `mandatory:"false" json:"externalMasters"` @@ -51,6 +72,9 @@ func (m UpdateZoneDetails) String() string { func (m UpdateZoneDetails) ValidateEnumValue() (bool, error) { errMessage := []string{} + if _, ok := GetMappingZoneDnssecStateEnum(string(m.DnssecState)); !ok && m.DnssecState != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DnssecState: %s. Supported values are: %s.", m.DnssecState, strings.Join(GetZoneDnssecStateEnumStringValues(), ","))) + } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) } diff --git a/dns/zone.go b/dns/zone.go index 579b49eaec..3484744980 100644 --- a/dns/zone.go +++ b/dns/zone.go @@ -44,6 +44,27 @@ type Zone struct { // **Example:** `{"Operations": {"CostCenter": "42"}}` DefinedTags map[string]map[string]interface{} `mandatory:"true" json:"definedTags"` + // The state of DNSSEC on the zone. + // For DNSSEC to function, every parent zone in the DNS tree up to the top-level domain (or an independent + // trust anchor) must also have DNSSEC correctly set up. + // After enabling DNSSEC, you must add a DS record to the zone's parent zone containing the + // `KskDnssecKeyVersion` data. You can find the DS data in the `dsData` attribute of the `KskDnssecKeyVersion`. + // Then, use the `PromoteZoneDnssecKeyVersion` operation to promote the `KskDnssecKeyVersion`. + // New `KskDnssecKeyVersion`s are generated annually, a week before the existing `KskDnssecKeyVersion`'s expiration. + // To rollover a `KskDnssecKeyVersion`, you must replace the parent zone's DS record containing the old + // `KskDnssecKeyVersion` data with the data from the new `KskDnssecKeyVersion`. + // To remove the old DS record without causing service disruption, wait until the old DS record's TTL has + // expired, and the new DS record has propagated. After the DS replacement has been completed, then the + // `PromoteZoneDnssecKeyVersion` operation must be called. + // Metrics are emitted in the `oci_dns` namespace daily for each `KskDnssecKeyVersion` indicating how many + // days are left until expiration. + // We recommend that you set up alarms and notifications for KskDnssecKeyVersion expiration so that the + // necessary parent zone updates can be made and the `PromoteZoneDnssecKeyVersion` operation can be called. + // Enabling DNSSEC results in additional records in DNS responses which increases their size and can + // cause higher response latency. + // For more information, see DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm). + DnssecState ZoneDnssecStateEnum `mandatory:"true" json:"dnssecState"` + // External master servers for the zone. `externalMasters` becomes a // required parameter when the `zoneType` value is `SECONDARY`. ExternalMasters []ExternalMaster `mandatory:"true" json:"externalMasters"` @@ -85,6 +106,8 @@ type Zone struct { // not part of a private view. ViewId *string `mandatory:"false" json:"viewId"` + DnssecConfig *DnssecConfig `mandatory:"false" json:"dnssecConfig"` + // The OCI nameservers that transfer the zone data with external nameservers. ZoneTransferServers []ZoneTransferServer `mandatory:"false" json:"zoneTransferServers"` } @@ -104,6 +127,9 @@ func (m Zone) ValidateEnumValue() (bool, error) { if _, ok := GetMappingScopeEnum(string(m.Scope)); !ok && m.Scope != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", m.Scope, strings.Join(GetScopeEnumStringValues(), ","))) } + if _, ok := GetMappingZoneDnssecStateEnum(string(m.DnssecState)); !ok && m.DnssecState != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DnssecState: %s. Supported values are: %s.", m.DnssecState, strings.Join(GetZoneDnssecStateEnumStringValues(), ","))) + } if _, ok := GetMappingZoneLifecycleStateEnum(string(m.LifecycleState)); !ok && m.LifecycleState != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LifecycleState: %s. Supported values are: %s.", m.LifecycleState, strings.Join(GetZoneLifecycleStateEnumStringValues(), ","))) } diff --git a/dns/zone_dnssec_state.go b/dns/zone_dnssec_state.go new file mode 100644 index 0000000000..6901274761 --- /dev/null +++ b/dns/zone_dnssec_state.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "strings" +) + +// ZoneDnssecStateEnum Enum with underlying type: string +type ZoneDnssecStateEnum string + +// Set of constants representing the allowable values for ZoneDnssecStateEnum +const ( + ZoneDnssecStateEnabled ZoneDnssecStateEnum = "ENABLED" + ZoneDnssecStateDisabled ZoneDnssecStateEnum = "DISABLED" +) + +var mappingZoneDnssecStateEnum = map[string]ZoneDnssecStateEnum{ + "ENABLED": ZoneDnssecStateEnabled, + "DISABLED": ZoneDnssecStateDisabled, +} + +var mappingZoneDnssecStateEnumLowerCase = map[string]ZoneDnssecStateEnum{ + "enabled": ZoneDnssecStateEnabled, + "disabled": ZoneDnssecStateDisabled, +} + +// GetZoneDnssecStateEnumValues Enumerates the set of values for ZoneDnssecStateEnum +func GetZoneDnssecStateEnumValues() []ZoneDnssecStateEnum { + values := make([]ZoneDnssecStateEnum, 0) + for _, v := range mappingZoneDnssecStateEnum { + values = append(values, v) + } + return values +} + +// GetZoneDnssecStateEnumStringValues Enumerates the set of values in String for ZoneDnssecStateEnum +func GetZoneDnssecStateEnumStringValues() []string { + return []string{ + "ENABLED", + "DISABLED", + } +} + +// GetMappingZoneDnssecStateEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingZoneDnssecStateEnum(val string) (ZoneDnssecStateEnum, bool) { + enum, ok := mappingZoneDnssecStateEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/dns/zone_summary.go b/dns/zone_summary.go index f0e1d0be93..d6aae7821b 100644 --- a/dns/zone_summary.go +++ b/dns/zone_summary.go @@ -44,6 +44,27 @@ type ZoneSummary struct { // **Example:** `{"Operations": {"CostCenter": "42"}}` DefinedTags map[string]map[string]interface{} `mandatory:"true" json:"definedTags"` + // The state of DNSSEC on the zone. + // For DNSSEC to function, every parent zone in the DNS tree up to the top-level domain (or an independent + // trust anchor) must also have DNSSEC correctly set up. + // After enabling DNSSEC, you must add a DS record to the zone's parent zone containing the + // `KskDnssecKeyVersion` data. You can find the DS data in the `dsData` attribute of the `KskDnssecKeyVersion`. + // Then, use the `PromoteZoneDnssecKeyVersion` operation to promote the `KskDnssecKeyVersion`. + // New `KskDnssecKeyVersion`s are generated annually, a week before the existing `KskDnssecKeyVersion`'s expiration. + // To rollover a `KskDnssecKeyVersion`, you must replace the parent zone's DS record containing the old + // `KskDnssecKeyVersion` data with the data from the new `KskDnssecKeyVersion`. + // To remove the old DS record without causing service disruption, wait until the old DS record's TTL has + // expired, and the new DS record has propagated. After the DS replacement has been completed, then the + // `PromoteZoneDnssecKeyVersion` operation must be called. + // Metrics are emitted in the `oci_dns` namespace daily for each `KskDnssecKeyVersion` indicating how many + // days are left until expiration. + // We recommend that you set up alarms and notifications for KskDnssecKeyVersion expiration so that the + // necessary parent zone updates can be made and the `PromoteZoneDnssecKeyVersion` operation can be called. + // Enabling DNSSEC results in additional records in DNS responses which increases their size and can + // cause higher response latency. + // For more information, see DNSSEC (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnssec.htm). + DnssecState ZoneDnssecStateEnum `mandatory:"true" json:"dnssecState"` + // The canonical absolute URL of the resource. Self *string `mandatory:"true" json:"self"` @@ -73,6 +94,8 @@ type ZoneSummary struct { // be null for zones in the global DNS, which are publicly resolvable and // not part of a private view. ViewId *string `mandatory:"false" json:"viewId"` + + DnssecConfig *DnssecConfig `mandatory:"false" json:"dnssecConfig"` } func (m ZoneSummary) String() string { @@ -90,6 +113,9 @@ func (m ZoneSummary) ValidateEnumValue() (bool, error) { if _, ok := GetMappingScopeEnum(string(m.Scope)); !ok && m.Scope != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Scope: %s. Supported values are: %s.", m.Scope, strings.Join(GetScopeEnumStringValues(), ","))) } + if _, ok := GetMappingZoneDnssecStateEnum(string(m.DnssecState)); !ok && m.DnssecState != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DnssecState: %s. Supported values are: %s.", m.DnssecState, strings.Join(GetZoneDnssecStateEnumStringValues(), ","))) + } if _, ok := GetMappingZoneSummaryLifecycleStateEnum(string(m.LifecycleState)); !ok && m.LifecycleState != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LifecycleState: %s. Supported values are: %s.", m.LifecycleState, strings.Join(GetZoneSummaryLifecycleStateEnumStringValues(), ","))) } diff --git a/dns/zsk_dnssec_key_version.go b/dns/zsk_dnssec_key_version.go new file mode 100644 index 0000000000..2e6b70ae8d --- /dev/null +++ b/dns/zsk_dnssec_key_version.go @@ -0,0 +1,101 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// DNS API +// +// API for the DNS service. Use this API to manage DNS zones, records, and other DNS resources. +// For more information, see Overview of the DNS Service (https://docs.cloud.oracle.com/iaas/Content/DNS/Concepts/dnszonemanagement.htm). +// + +package dns + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// ZskDnssecKeyVersion A zone signing key (ZSK) version. The version information contains timing and configuration data for the ZSK that is used to +// apply DNSSEC on the zone. +type ZskDnssecKeyVersion struct { + + // The UUID of the `DnssecKeyVersion`. + Uuid *string `mandatory:"false" json:"uuid"` + + // The signing algorithm used for the key. + Algorithm DnssecSigningAlgorithmEnum `mandatory:"false" json:"algorithm,omitempty"` + + // The length of the corresponding private key in bytes, expressed as an integer. + LengthInBytes *int `mandatory:"false" json:"lengthInBytes"` + + // The date and time the key version was created, expressed in RFC 3339 timestamp format. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The date and time the key version was, or will be, published, expressed in RFC 3339 timestamp format. This is + // when the zone contents will include a DNSKEY record corresponding to the key material. + // **Example:** `2016-07-22T17:23:59:00Z` + TimePublished *common.SDKTime `mandatory:"false" json:"timePublished"` + + // The date and time the key version went, or will go, active, expressed in RFC 3339 timestamp format. This is + // when the key material will be used to generate RRSIGs. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeActivated *common.SDKTime `mandatory:"false" json:"timeActivated"` + + // The date and time the key version went, or will go, inactive, expressed in RFC 3339 timestamp format. This + // is when the key material will no longer be used to generate RRSIGs. For a key signing key (KSK) `DnssecKeyVersion`, this is + // populated after `PromoteZoneDnssecKeyVersion` has been called on its successor `DnssecKeyVersion`. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeInactivated *common.SDKTime `mandatory:"false" json:"timeInactivated"` + + // The date and time the key version was, or will be, unpublished, expressed in RFC 3339 timestamp format. This + // is when the corresponding DNSKEY will be removed from zone contents. For a key signing key (KSK) `DnssecKeyVersion`, this is + // populated after `PromoteZoneDnssecKeyVersion` has been called on its successor `DnssecKeyVersion`. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeUnpublished *common.SDKTime `mandatory:"false" json:"timeUnpublished"` + + // The date and time at which the recommended key version publication/activation lifetime ends, expressed in RFC + // 3339 timestamp format. This is when the corresponding DNSKEY should no longer exist in zone contents and no + // longer be used to generate RRSIGs. For a key sigining key (KSK), if `PromoteZoneDnssecKeyVersion` has not been called on this + // `DnssecKeyVersion`'s successor then it will remain active for arbitrarily long past its recommended lifetime. + // This prevents service disruption at the potential increased risk of key compromise. + // **Example:** `2016-07-22T17:23:59:00Z` + TimeExpired *common.SDKTime `mandatory:"false" json:"timeExpired"` + + // The date and time the key version was promoted expressed in RFC 3339 timestamp format. + // **Example:** `2016-07-22T17:23:59:00Z` + TimePromoted *common.SDKTime `mandatory:"false" json:"timePromoted"` + + // When populated, this is the UUID of the `DnssecKeyVersion` that this `DnssecKeyVersion` will replace or has + // replaced. + PredecessorDnssecKeyVersionUuid *string `mandatory:"false" json:"predecessorDnssecKeyVersionUuid"` + + // When populated, this is the UUID of the `DnssecKeyVersion` that will replace, or has replaced, this + // `DnssecKeyVersion`. + SuccessorDnssecKeyVersionUuid *string `mandatory:"false" json:"successorDnssecKeyVersionUuid"` + + // The key tag associated with the `DnssecKeyVersion`. This key tag will be present in the RRSIG and DS records + // associated with the key material for this `DnssecKeyVersion`. For more information about key tags, see + // RFC 4034 (https://tools.ietf.org/html/rfc4034). + KeyTag *int `mandatory:"false" json:"keyTag"` +} + +func (m ZskDnssecKeyVersion) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m ZskDnssecKeyVersion) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if _, ok := GetMappingDnssecSigningAlgorithmEnum(string(m.Algorithm)); !ok && m.Algorithm != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Algorithm: %s. Supported values are: %s.", m.Algorithm, strings.Join(GetDnssecSigningAlgorithmEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/goldengate/copy_deployment_backup_request_response.go b/goldengate/copy_deployment_backup_request_response.go index 18dae51e79..72df5e67e0 100644 --- a/goldengate/copy_deployment_backup_request_response.go +++ b/goldengate/copy_deployment_backup_request_response.go @@ -87,6 +87,9 @@ type CopyDeploymentBackupResponse struct { // The underlying http response RawResponse *http.Response + // The DeploymentBackup instance + DeploymentBackup `presentIn:"body"` + // A unique Oracle-assigned identifier for an asynchronous request. You can use this to query // status of the asynchronous operation. OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` @@ -94,6 +97,9 @@ type CopyDeploymentBackupResponse struct { // A unique Oracle-assigned identifier for the request. If you need to contact Oracle about a // particular request, please include the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` } func (response CopyDeploymentBackupResponse) String() string { diff --git a/goldengate/create_database_registration_details.go b/goldengate/create_database_registration_details.go index e1ea7cb45c..683e5182eb 100644 --- a/goldengate/create_database_registration_details.go +++ b/goldengate/create_database_registration_details.go @@ -70,8 +70,8 @@ type CreateDatabaseRegistrationDetails struct { // to the database node to connect to. By default the mode would be DIRECT. SessionMode CreateDatabaseRegistrationDetailsSessionModeEnum `mandatory:"false" json:"sessionMode,omitempty"` - // The wallet contents Oracle GoldenGate uses to make connections to a database. This - // attribute is expected to be base64 encoded. + // The wallet contents Oracle GoldenGate uses to make connections to a database. + // This attribute is expected to be base64 encoded. Wallet *string `mandatory:"false" json:"wallet"` // Refers to the customer's vault OCID. diff --git a/goldengate/create_deployment_backup_request_response.go b/goldengate/create_deployment_backup_request_response.go index f321196f83..588a81d64b 100644 --- a/goldengate/create_deployment_backup_request_response.go +++ b/goldengate/create_deployment_backup_request_response.go @@ -78,6 +78,9 @@ type CreateDeploymentBackupResponse struct { // The underlying http response RawResponse *http.Response + // The DeploymentBackup instance + DeploymentBackup `presentIn:"body"` + // A unique Oracle-assigned identifier for an asynchronous request. You can use this to query // status of the asynchronous operation. OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` @@ -85,6 +88,9 @@ type CreateDeploymentBackupResponse struct { // A unique Oracle-assigned identifier for the request. If you need to contact Oracle about a // particular request, please include the request ID. OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` } func (response CreateDeploymentBackupResponse) String() string { diff --git a/goldengate/create_deployment_details.go b/goldengate/create_deployment_details.go index a6219e6739..2fcbd42027 100644 --- a/goldengate/create_deployment_details.go +++ b/goldengate/create_deployment_details.go @@ -43,6 +43,9 @@ type CreateDeploymentDetails struct { // Its use is discouraged in favor of 'DATABASE_ORACLE'. DeploymentType DeploymentTypeEnum `mandatory:"true" json:"deploymentType"` + // Specifies whether the deployment is used in a production or development/testing environment. + EnvironmentType EnvironmentTypeEnum `mandatory:"false" json:"environmentType,omitempty"` + // Metadata about this specific object. Description *string `mandatory:"false" json:"description"` @@ -98,6 +101,9 @@ func (m CreateDeploymentDetails) ValidateEnumValue() (bool, error) { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DeploymentType: %s. Supported values are: %s.", m.DeploymentType, strings.Join(GetDeploymentTypeEnumStringValues(), ","))) } + if _, ok := GetMappingEnvironmentTypeEnum(string(m.EnvironmentType)); !ok && m.EnvironmentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for EnvironmentType: %s. Supported values are: %s.", m.EnvironmentType, strings.Join(GetEnvironmentTypeEnumStringValues(), ","))) + } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) } diff --git a/goldengate/create_ogg_deployment_details.go b/goldengate/create_ogg_deployment_details.go index 2308cf1bde..f081d5daba 100644 --- a/goldengate/create_ogg_deployment_details.go +++ b/goldengate/create_ogg_deployment_details.go @@ -48,6 +48,8 @@ type CreateOggDeploymentDetails struct { // Version of OGG OggVersion *string `mandatory:"false" json:"oggVersion"` + + GroupToRolesMapping *GroupToRolesMappingDetails `mandatory:"false" json:"groupToRolesMapping"` } func (m CreateOggDeploymentDetails) String() string { diff --git a/goldengate/create_oracle_connection_details.go b/goldengate/create_oracle_connection_details.go index ed22c18f9e..4a5fcdb778 100644 --- a/goldengate/create_oracle_connection_details.go +++ b/goldengate/create_oracle_connection_details.go @@ -67,8 +67,8 @@ type CreateOracleConnectionDetails struct { // Connect descriptor or Easy Connect Naming method used to connect to a database. ConnectionString *string `mandatory:"false" json:"connectionString"` - // The wallet contents Oracle GoldenGate uses to make connections to a database. This - // attribute is expected to be base64 encoded. + // The wallet contents Oracle GoldenGate uses to make connections to a database. + // This attribute is expected to be base64 encoded. Wallet *string `mandatory:"false" json:"wallet"` // Deprecated: this field will be removed in future versions. Either specify the private IP in the connectionString or host diff --git a/goldengate/deployment.go b/goldengate/deployment.go index 0cb139c314..45d0e76b46 100644 --- a/goldengate/deployment.go +++ b/goldengate/deployment.go @@ -32,6 +32,10 @@ type Deployment struct { // The Oracle license model that applies to a Deployment. LicenseModel LicenseModelEnum `mandatory:"true" json:"licenseModel"` + // The deployment category defines the broad separation of the deployment type into three categories. + // Currently the separation is 'DATA_REPLICATION', 'STREAM_ANALYTICS' and 'DATA_TRANSFORMS'. + Category DeploymentCategoryEnum `mandatory:"true" json:"category"` + // The Minimum number of OCPUs to be made available for this Deployment. CpuCoreCount *int `mandatory:"true" json:"cpuCoreCount"` @@ -97,6 +101,9 @@ type Deployment struct { // A three-label Fully Qualified Domain Name (FQDN) for a resource. Fqdn *string `mandatory:"false" json:"fqdn"` + // Specifies whether the deployment is used in a production or development/testing environment. + EnvironmentType EnvironmentTypeEnum `mandatory:"false" json:"environmentType,omitempty"` + // An array of Network Security Group OCIDs used to define network access for either Deployments or Connections. NsgIds []string `mandatory:"false" json:"nsgIds"` @@ -134,6 +141,7 @@ type Deployment struct { // The amount of storage being utilized (in bytes) StorageUtilizationInBytes *int64 `mandatory:"false" json:"storageUtilizationInBytes"` + // Deprecated: This field is not updated and will be removed in future versions. If storage utilization exceeds the limit, the respective warning message will appear in deployment messages, which can be accessed through /messages?deploymentId=. // Indicator will be true if the amount of storage being utilized exceeds the allowable storage utilization limit. Exceeding the limit may be an indication of a misconfiguration of the deployment's GoldenGate service. IsStorageUtilizationLimitExceeded *bool `mandatory:"false" json:"isStorageUtilizationLimitExceeded"` @@ -176,6 +184,9 @@ func (m Deployment) ValidateEnumValue() (bool, error) { if _, ok := GetMappingLicenseModelEnum(string(m.LicenseModel)); !ok && m.LicenseModel != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LicenseModel: %s. Supported values are: %s.", m.LicenseModel, strings.Join(GetLicenseModelEnumStringValues(), ","))) } + if _, ok := GetMappingDeploymentCategoryEnum(string(m.Category)); !ok && m.Category != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Category: %s. Supported values are: %s.", m.Category, strings.Join(GetDeploymentCategoryEnumStringValues(), ","))) + } if _, ok := GetMappingDeploymentTypeEnum(string(m.DeploymentType)); !ok && m.DeploymentType != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DeploymentType: %s. Supported values are: %s.", m.DeploymentType, strings.Join(GetDeploymentTypeEnumStringValues(), ","))) } @@ -186,6 +197,9 @@ func (m Deployment) ValidateEnumValue() (bool, error) { if _, ok := GetMappingLifecycleSubStateEnum(string(m.LifecycleSubState)); !ok && m.LifecycleSubState != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LifecycleSubState: %s. Supported values are: %s.", m.LifecycleSubState, strings.Join(GetLifecycleSubStateEnumStringValues(), ","))) } + if _, ok := GetMappingEnvironmentTypeEnum(string(m.EnvironmentType)); !ok && m.EnvironmentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for EnvironmentType: %s. Supported values are: %s.", m.EnvironmentType, strings.Join(GetEnvironmentTypeEnumStringValues(), ","))) + } if _, ok := GetMappingMaintenanceActionTypeEnum(string(m.NextMaintenanceActionType)); !ok && m.NextMaintenanceActionType != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for NextMaintenanceActionType: %s. Supported values are: %s.", m.NextMaintenanceActionType, strings.Join(GetMaintenanceActionTypeEnumStringValues(), ","))) } diff --git a/goldengate/deployment_category.go b/goldengate/deployment_category.go new file mode 100644 index 0000000000..93d5208ce2 --- /dev/null +++ b/goldengate/deployment_category.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "strings" +) + +// DeploymentCategoryEnum Enum with underlying type: string +type DeploymentCategoryEnum string + +// Set of constants representing the allowable values for DeploymentCategoryEnum +const ( + DeploymentCategoryDataReplication DeploymentCategoryEnum = "DATA_REPLICATION" + DeploymentCategoryStreamAnalytics DeploymentCategoryEnum = "STREAM_ANALYTICS" + DeploymentCategoryDataTransforms DeploymentCategoryEnum = "DATA_TRANSFORMS" +) + +var mappingDeploymentCategoryEnum = map[string]DeploymentCategoryEnum{ + "DATA_REPLICATION": DeploymentCategoryDataReplication, + "STREAM_ANALYTICS": DeploymentCategoryStreamAnalytics, + "DATA_TRANSFORMS": DeploymentCategoryDataTransforms, +} + +var mappingDeploymentCategoryEnumLowerCase = map[string]DeploymentCategoryEnum{ + "data_replication": DeploymentCategoryDataReplication, + "stream_analytics": DeploymentCategoryStreamAnalytics, + "data_transforms": DeploymentCategoryDataTransforms, +} + +// GetDeploymentCategoryEnumValues Enumerates the set of values for DeploymentCategoryEnum +func GetDeploymentCategoryEnumValues() []DeploymentCategoryEnum { + values := make([]DeploymentCategoryEnum, 0) + for _, v := range mappingDeploymentCategoryEnum { + values = append(values, v) + } + return values +} + +// GetDeploymentCategoryEnumStringValues Enumerates the set of values in String for DeploymentCategoryEnum +func GetDeploymentCategoryEnumStringValues() []string { + return []string{ + "DATA_REPLICATION", + "STREAM_ANALYTICS", + "DATA_TRANSFORMS", + } +} + +// GetMappingDeploymentCategoryEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingDeploymentCategoryEnum(val string) (DeploymentCategoryEnum, bool) { + enum, ok := mappingDeploymentCategoryEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/goldengate/deployment_environment_collection.go b/goldengate/deployment_environment_collection.go new file mode 100644 index 0000000000..2a22270d74 --- /dev/null +++ b/goldengate/deployment_environment_collection.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// DeploymentEnvironmentCollection The list of DeploymentEnvironmentDescriptor objects. +type DeploymentEnvironmentCollection struct { + + // Array of DeploymentEnvironmentSummary objects. + Items []DeploymentEnvironmentSummary `mandatory:"true" json:"items"` +} + +func (m DeploymentEnvironmentCollection) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m DeploymentEnvironmentCollection) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/goldengate/deployment_environment_summary.go b/goldengate/deployment_environment_summary.go new file mode 100644 index 0000000000..5ec0184ec0 --- /dev/null +++ b/goldengate/deployment_environment_summary.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// DeploymentEnvironmentSummary The metadata specific to a production or development/testing environment. +type DeploymentEnvironmentSummary struct { + + // Specifies whether the deployment is used in a production or development/testing environment. + EnvironmentType EnvironmentTypeEnum `mandatory:"true" json:"environmentType"` + + // The deployment category defines the broad separation of the deployment type into three categories. + // Currently the separation is 'DATA_REPLICATION', 'STREAM_ANALYTICS' and 'DATA_TRANSFORMS'. + Category DeploymentCategoryEnum `mandatory:"true" json:"category"` + + // The minimum CPU core count. + MinCpuCoreCount *int `mandatory:"true" json:"minCpuCoreCount"` + + // The default CPU core count. + DefaultCpuCoreCount *int `mandatory:"true" json:"defaultCpuCoreCount"` + + // The maximum CPU core count. + MaxCpuCoreCount *int `mandatory:"true" json:"maxCpuCoreCount"` + + // Specifies whether the "Auto scaling" option should be enabled by default or not. + IsAutoScalingEnabledByDefault *bool `mandatory:"true" json:"isAutoScalingEnabledByDefault"` + + // The multiplier value between CPU core count and network bandwidth. + NetworkBandwidthPerOcpuInGbps *int `mandatory:"true" json:"networkBandwidthPerOcpuInGbps"` + + // The multiplier value between CPU core count and memory size. + MemoryPerOcpuInGBs *int `mandatory:"true" json:"memoryPerOcpuInGBs"` + + // The multiplier value between CPU core count and storage usage limit size. + StorageUsageLimitPerOcpuInGBs *int `mandatory:"true" json:"storageUsageLimitPerOcpuInGBs"` + + // An object's Display Name. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m DeploymentEnvironmentSummary) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m DeploymentEnvironmentSummary) ValidateEnumValue() (bool, error) { + errMessage := []string{} + if _, ok := GetMappingEnvironmentTypeEnum(string(m.EnvironmentType)); !ok && m.EnvironmentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for EnvironmentType: %s. Supported values are: %s.", m.EnvironmentType, strings.Join(GetEnvironmentTypeEnumStringValues(), ","))) + } + if _, ok := GetMappingDeploymentCategoryEnum(string(m.Category)); !ok && m.Category != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Category: %s. Supported values are: %s.", m.Category, strings.Join(GetDeploymentCategoryEnumStringValues(), ","))) + } + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/goldengate/deployment_summary.go b/goldengate/deployment_summary.go index 7eb46ad58b..9eab0b9840 100644 --- a/goldengate/deployment_summary.go +++ b/goldengate/deployment_summary.go @@ -32,6 +32,15 @@ type DeploymentSummary struct { // The Oracle license model that applies to a Deployment. LicenseModel LicenseModelEnum `mandatory:"true" json:"licenseModel"` + // The deployment category defines the broad separation of the deployment type into three categories. + // Currently the separation is 'DATA_REPLICATION', 'STREAM_ANALYTICS' and 'DATA_TRANSFORMS'. + Category DeploymentCategoryEnum `mandatory:"true" json:"category"` + + // The type of deployment, which can be any one of the Allowed values. + // NOTE: Use of the value 'OGG' is maintained for backward compatibility purposes. + // Its use is discouraged in favor of 'DATABASE_ORACLE'. + DeploymentType DeploymentTypeEnum `mandatory:"true" json:"deploymentType"` + // An object's Display Name. DisplayName *string `mandatory:"false" json:"displayName"` @@ -74,6 +83,9 @@ type DeploymentSummary struct { // The loadbalancer of the public deployment created in the customer subnet. LoadBalancerId *string `mandatory:"false" json:"loadBalancerId"` + // Specifies whether the deployment is used in a production or development/testing environment. + EnvironmentType EnvironmentTypeEnum `mandatory:"false" json:"environmentType,omitempty"` + // A three-label Fully Qualified Domain Name (FQDN) for a resource. Fqdn *string `mandatory:"false" json:"fqdn"` @@ -114,14 +126,10 @@ type DeploymentSummary struct { // RFC3339 (https://tools.ietf.org/html/rfc3339), such as `2016-08-25T21:10:29.600Z`. TimeUpgradeRequired *common.SDKTime `mandatory:"false" json:"timeUpgradeRequired"` - // The type of deployment, which can be any one of the Allowed values. - // NOTE: Use of the value 'OGG' is maintained for backward compatibility purposes. - // Its use is discouraged in favor of 'DATABASE_ORACLE'. - DeploymentType DeploymentTypeEnum `mandatory:"false" json:"deploymentType,omitempty"` - // The amount of storage being utilized (in bytes) StorageUtilizationInBytes *int64 `mandatory:"false" json:"storageUtilizationInBytes"` + // Deprecated: This field is not updated and will be removed in future versions. If storage utilization exceeds the limit, the respective warning message will appear in deployment messages, which can be accessed through /messages?deploymentId=. // Indicator will be true if the amount of storage being utilized exceeds the allowable storage utilization limit. Exceeding the limit may be an indication of a misconfiguration of the deployment's GoldenGate service. IsStorageUtilizationLimitExceeded *bool `mandatory:"false" json:"isStorageUtilizationLimitExceeded"` @@ -141,6 +149,12 @@ func (m DeploymentSummary) ValidateEnumValue() (bool, error) { if _, ok := GetMappingLicenseModelEnum(string(m.LicenseModel)); !ok && m.LicenseModel != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LicenseModel: %s. Supported values are: %s.", m.LicenseModel, strings.Join(GetLicenseModelEnumStringValues(), ","))) } + if _, ok := GetMappingDeploymentCategoryEnum(string(m.Category)); !ok && m.Category != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Category: %s. Supported values are: %s.", m.Category, strings.Join(GetDeploymentCategoryEnumStringValues(), ","))) + } + if _, ok := GetMappingDeploymentTypeEnum(string(m.DeploymentType)); !ok && m.DeploymentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DeploymentType: %s. Supported values are: %s.", m.DeploymentType, strings.Join(GetDeploymentTypeEnumStringValues(), ","))) + } if _, ok := GetMappingLifecycleStateEnum(string(m.LifecycleState)); !ok && m.LifecycleState != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LifecycleState: %s. Supported values are: %s.", m.LifecycleState, strings.Join(GetLifecycleStateEnumStringValues(), ","))) @@ -148,8 +162,8 @@ func (m DeploymentSummary) ValidateEnumValue() (bool, error) { if _, ok := GetMappingLifecycleSubStateEnum(string(m.LifecycleSubState)); !ok && m.LifecycleSubState != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LifecycleSubState: %s. Supported values are: %s.", m.LifecycleSubState, strings.Join(GetLifecycleSubStateEnumStringValues(), ","))) } - if _, ok := GetMappingDeploymentTypeEnum(string(m.DeploymentType)); !ok && m.DeploymentType != "" { - errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DeploymentType: %s. Supported values are: %s.", m.DeploymentType, strings.Join(GetDeploymentTypeEnumStringValues(), ","))) + if _, ok := GetMappingEnvironmentTypeEnum(string(m.EnvironmentType)); !ok && m.EnvironmentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for EnvironmentType: %s. Supported values are: %s.", m.EnvironmentType, strings.Join(GetEnvironmentTypeEnumStringValues(), ","))) } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) diff --git a/goldengate/deployment_type_summary.go b/goldengate/deployment_type_summary.go index 24914b0e4e..421719346f 100644 --- a/goldengate/deployment_type_summary.go +++ b/goldengate/deployment_type_summary.go @@ -16,11 +16,13 @@ import ( ) // DeploymentTypeSummary The meta-data specific on particular deployment type represented by deploymentType field. +// Deprecated properties: `sourceTechnologies` and `targetTechnologies` are not populated. They will be removed after September 15 2025. +// The list of supported source and target technologies can be accessed using the url provided in `supportedTechnologiesUrl` property. type DeploymentTypeSummary struct { // The deployment category defines the broad separation of the deployment type into three categories. // Currently the separation is 'DATA_REPLICATION', 'STREAM_ANALYTICS' and 'DATA_TRANSFORMS'. - Category DeploymentTypeSummaryCategoryEnum `mandatory:"true" json:"category"` + Category DeploymentCategoryEnum `mandatory:"true" json:"category"` // An object's Display Name. DisplayName *string `mandatory:"true" json:"displayName"` @@ -62,8 +64,8 @@ func (m DeploymentTypeSummary) String() string { // Not recommended for calling this function directly func (m DeploymentTypeSummary) ValidateEnumValue() (bool, error) { errMessage := []string{} - if _, ok := GetMappingDeploymentTypeSummaryCategoryEnum(string(m.Category)); !ok && m.Category != "" { - errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Category: %s. Supported values are: %s.", m.Category, strings.Join(GetDeploymentTypeSummaryCategoryEnumStringValues(), ","))) + if _, ok := GetMappingDeploymentCategoryEnum(string(m.Category)); !ok && m.Category != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for Category: %s. Supported values are: %s.", m.Category, strings.Join(GetDeploymentCategoryEnumStringValues(), ","))) } if _, ok := GetMappingDeploymentTypeEnum(string(m.DeploymentType)); !ok && m.DeploymentType != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for DeploymentType: %s. Supported values are: %s.", m.DeploymentType, strings.Join(GetDeploymentTypeEnumStringValues(), ","))) @@ -80,49 +82,3 @@ func (m DeploymentTypeSummary) ValidateEnumValue() (bool, error) { } return false, nil } - -// DeploymentTypeSummaryCategoryEnum Enum with underlying type: string -type DeploymentTypeSummaryCategoryEnum string - -// Set of constants representing the allowable values for DeploymentTypeSummaryCategoryEnum -const ( - DeploymentTypeSummaryCategoryDataReplication DeploymentTypeSummaryCategoryEnum = "DATA_REPLICATION" - DeploymentTypeSummaryCategoryStreamAnalytics DeploymentTypeSummaryCategoryEnum = "STREAM_ANALYTICS" - DeploymentTypeSummaryCategoryDataTransforms DeploymentTypeSummaryCategoryEnum = "DATA_TRANSFORMS" -) - -var mappingDeploymentTypeSummaryCategoryEnum = map[string]DeploymentTypeSummaryCategoryEnum{ - "DATA_REPLICATION": DeploymentTypeSummaryCategoryDataReplication, - "STREAM_ANALYTICS": DeploymentTypeSummaryCategoryStreamAnalytics, - "DATA_TRANSFORMS": DeploymentTypeSummaryCategoryDataTransforms, -} - -var mappingDeploymentTypeSummaryCategoryEnumLowerCase = map[string]DeploymentTypeSummaryCategoryEnum{ - "data_replication": DeploymentTypeSummaryCategoryDataReplication, - "stream_analytics": DeploymentTypeSummaryCategoryStreamAnalytics, - "data_transforms": DeploymentTypeSummaryCategoryDataTransforms, -} - -// GetDeploymentTypeSummaryCategoryEnumValues Enumerates the set of values for DeploymentTypeSummaryCategoryEnum -func GetDeploymentTypeSummaryCategoryEnumValues() []DeploymentTypeSummaryCategoryEnum { - values := make([]DeploymentTypeSummaryCategoryEnum, 0) - for _, v := range mappingDeploymentTypeSummaryCategoryEnum { - values = append(values, v) - } - return values -} - -// GetDeploymentTypeSummaryCategoryEnumStringValues Enumerates the set of values in String for DeploymentTypeSummaryCategoryEnum -func GetDeploymentTypeSummaryCategoryEnumStringValues() []string { - return []string{ - "DATA_REPLICATION", - "STREAM_ANALYTICS", - "DATA_TRANSFORMS", - } -} - -// GetMappingDeploymentTypeSummaryCategoryEnum performs case Insensitive comparison on enum value and return the desired enum -func GetMappingDeploymentTypeSummaryCategoryEnum(val string) (DeploymentTypeSummaryCategoryEnum, bool) { - enum, ok := mappingDeploymentTypeSummaryCategoryEnumLowerCase[strings.ToLower(val)] - return enum, ok -} diff --git a/goldengate/environment_type.go b/goldengate/environment_type.go new file mode 100644 index 0000000000..8889a49162 --- /dev/null +++ b/goldengate/environment_type.go @@ -0,0 +1,56 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "strings" +) + +// EnvironmentTypeEnum Enum with underlying type: string +type EnvironmentTypeEnum string + +// Set of constants representing the allowable values for EnvironmentTypeEnum +const ( + EnvironmentTypeProduction EnvironmentTypeEnum = "PRODUCTION" + EnvironmentTypeDevelopmentOrTesting EnvironmentTypeEnum = "DEVELOPMENT_OR_TESTING" +) + +var mappingEnvironmentTypeEnum = map[string]EnvironmentTypeEnum{ + "PRODUCTION": EnvironmentTypeProduction, + "DEVELOPMENT_OR_TESTING": EnvironmentTypeDevelopmentOrTesting, +} + +var mappingEnvironmentTypeEnumLowerCase = map[string]EnvironmentTypeEnum{ + "production": EnvironmentTypeProduction, + "development_or_testing": EnvironmentTypeDevelopmentOrTesting, +} + +// GetEnvironmentTypeEnumValues Enumerates the set of values for EnvironmentTypeEnum +func GetEnvironmentTypeEnumValues() []EnvironmentTypeEnum { + values := make([]EnvironmentTypeEnum, 0) + for _, v := range mappingEnvironmentTypeEnum { + values = append(values, v) + } + return values +} + +// GetEnvironmentTypeEnumStringValues Enumerates the set of values in String for EnvironmentTypeEnum +func GetEnvironmentTypeEnumStringValues() []string { + return []string{ + "PRODUCTION", + "DEVELOPMENT_OR_TESTING", + } +} + +// GetMappingEnvironmentTypeEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingEnvironmentTypeEnum(val string) (EnvironmentTypeEnum, bool) { + enum, ok := mappingEnvironmentTypeEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/goldengate/goldengate_client.go b/goldengate/goldengate_client.go index 0c0b7c8183..1d80d8981c 100644 --- a/goldengate/goldengate_client.go +++ b/goldengate/goldengate_client.go @@ -2576,6 +2576,64 @@ func (client GoldenGateClient) listDeploymentBackups(ctx context.Context, reques return response, err } +// ListDeploymentEnvironments Returns an array of DeploymentEnvironmentDescriptor +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/goldengate/ListDeploymentEnvironments.go.html to see an example of how to use ListDeploymentEnvironments API. +// A default retry strategy applies to this operation ListDeploymentEnvironments() +func (client GoldenGateClient) ListDeploymentEnvironments(ctx context.Context, request ListDeploymentEnvironmentsRequest) (response ListDeploymentEnvironmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.DefaultRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDeploymentEnvironments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDeploymentEnvironmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDeploymentEnvironmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDeploymentEnvironmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDeploymentEnvironmentsResponse") + } + return +} + +// listDeploymentEnvironments implements the OCIOperation interface (enables retrying operations) +func (client GoldenGateClient) listDeploymentEnvironments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/deploymentEnvironments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDeploymentEnvironmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/goldengate/20200407/DeploymentEnvironmentCollection/ListDeploymentEnvironments" + err = common.PostProcessServiceError(err, "GoldenGate", "ListDeploymentEnvironments", apiReferenceLink) + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + // ListDeploymentTypes Returns an array of DeploymentTypeDescriptor // // # See also diff --git a/goldengate/group_to_roles_mapping_details.go b/goldengate/group_to_roles_mapping_details.go new file mode 100644 index 0000000000..6bf96f4805 --- /dev/null +++ b/goldengate/group_to_roles_mapping_details.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// GroupToRolesMappingDetails Defines the IDP Groups to GoldenGate roles mapping. This field is used only for IAM deployment and does not have any impact on non-IAM deployments. +// For IAM deployment, when user does not specify this mapping, then it has null value and default mapping is used. +// User belonging to each group can only perform the actions according to the role the respective group is mapped to. +type GroupToRolesMappingDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role securityGroup. + // It grants administration of security related objects and invoke security related service requests. This role has full privileges. + SecurityGroupId *string `mandatory:"true" json:"securityGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role administratorGroup. + // It grants full access to the user, including the ability to alter general, non-security related operational parameters + // and profiles of the server. + AdministratorGroupId *string `mandatory:"false" json:"administratorGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role operatorGroup. + // It allows users to perform only operational actions, like starting and stopping resources. + // Operators cannot alter the operational parameters or profiles of the MA server. + OperatorGroupId *string `mandatory:"false" json:"operatorGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role userGroup. + // It allows information-only service requests, which do not alter or affect the operation of either the MA. + // Examples of query and read-only information include performance metric information and resource status and monitoring information + UserGroupId *string `mandatory:"false" json:"userGroupId"` +} + +func (m GroupToRolesMappingDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m GroupToRolesMappingDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/goldengate/list_deployment_environments_request_response.go b/goldengate/list_deployment_environments_request_response.go new file mode 100644 index 0000000000..3bfb28cffe --- /dev/null +++ b/goldengate/list_deployment_environments_request_response.go @@ -0,0 +1,202 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package goldengate + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "net/http" + "strings" +) + +// ListDeploymentEnvironmentsRequest wrapper for the ListDeploymentEnvironments operation +// +// # See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/goldengate/ListDeploymentEnvironments.go.html to see an example of how to use ListDeploymentEnvironmentsRequest. +type ListDeploymentEnvironmentsRequest struct { + + // The OCID of the compartment that contains the work request. Work requests should be scoped + // to the same compartment as the resource the work request affects. If the work request concerns + // multiple resources, and those resources are not in the same compartment, it is up to the service team + // to pick the primary resource whose compartment should be used. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The client request ID for tracing. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The maximum number of items to return. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The page token representing the page at which to start retrieving results. This is usually + // retrieved from a previous list call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either 'asc' or 'desc'. + SortOrder ListDeploymentEnvironmentsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // The field to sort by. Only one sort order can be provided. Default order for 'timeCreated' is + // descending. Default order for 'displayName' is ascending. If no value is specified + // timeCreated is the default. + SortBy ListDeploymentEnvironmentsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDeploymentEnvironmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDeploymentEnvironmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + _, err := request.ValidateEnumValue() + if err != nil { + return http.Request{}, err + } + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDeploymentEnvironmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDeploymentEnvironmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (request ListDeploymentEnvironmentsRequest) ValidateEnumValue() (bool, error) { + errMessage := []string{} + if _, ok := GetMappingListDeploymentEnvironmentsSortOrderEnum(string(request.SortOrder)); !ok && request.SortOrder != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for SortOrder: %s. Supported values are: %s.", request.SortOrder, strings.Join(GetListDeploymentEnvironmentsSortOrderEnumStringValues(), ","))) + } + if _, ok := GetMappingListDeploymentEnvironmentsSortByEnum(string(request.SortBy)); !ok && request.SortBy != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for SortBy: %s. Supported values are: %s.", request.SortBy, strings.Join(GetListDeploymentEnvironmentsSortByEnumStringValues(), ","))) + } + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} + +// ListDeploymentEnvironmentsResponse wrapper for the ListDeploymentEnvironments operation +type ListDeploymentEnvironmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of DeploymentEnvironmentCollection instances + DeploymentEnvironmentCollection `presentIn:"body"` + + // A unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please include the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The page token represents the page to start retrieving results. This is usually retrieved + // from a previous list call. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListDeploymentEnvironmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDeploymentEnvironmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDeploymentEnvironmentsSortOrderEnum Enum with underlying type: string +type ListDeploymentEnvironmentsSortOrderEnum string + +// Set of constants representing the allowable values for ListDeploymentEnvironmentsSortOrderEnum +const ( + ListDeploymentEnvironmentsSortOrderAsc ListDeploymentEnvironmentsSortOrderEnum = "ASC" + ListDeploymentEnvironmentsSortOrderDesc ListDeploymentEnvironmentsSortOrderEnum = "DESC" +) + +var mappingListDeploymentEnvironmentsSortOrderEnum = map[string]ListDeploymentEnvironmentsSortOrderEnum{ + "ASC": ListDeploymentEnvironmentsSortOrderAsc, + "DESC": ListDeploymentEnvironmentsSortOrderDesc, +} + +var mappingListDeploymentEnvironmentsSortOrderEnumLowerCase = map[string]ListDeploymentEnvironmentsSortOrderEnum{ + "asc": ListDeploymentEnvironmentsSortOrderAsc, + "desc": ListDeploymentEnvironmentsSortOrderDesc, +} + +// GetListDeploymentEnvironmentsSortOrderEnumValues Enumerates the set of values for ListDeploymentEnvironmentsSortOrderEnum +func GetListDeploymentEnvironmentsSortOrderEnumValues() []ListDeploymentEnvironmentsSortOrderEnum { + values := make([]ListDeploymentEnvironmentsSortOrderEnum, 0) + for _, v := range mappingListDeploymentEnvironmentsSortOrderEnum { + values = append(values, v) + } + return values +} + +// GetListDeploymentEnvironmentsSortOrderEnumStringValues Enumerates the set of values in String for ListDeploymentEnvironmentsSortOrderEnum +func GetListDeploymentEnvironmentsSortOrderEnumStringValues() []string { + return []string{ + "ASC", + "DESC", + } +} + +// GetMappingListDeploymentEnvironmentsSortOrderEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingListDeploymentEnvironmentsSortOrderEnum(val string) (ListDeploymentEnvironmentsSortOrderEnum, bool) { + enum, ok := mappingListDeploymentEnvironmentsSortOrderEnumLowerCase[strings.ToLower(val)] + return enum, ok +} + +// ListDeploymentEnvironmentsSortByEnum Enum with underlying type: string +type ListDeploymentEnvironmentsSortByEnum string + +// Set of constants representing the allowable values for ListDeploymentEnvironmentsSortByEnum +const ( + ListDeploymentEnvironmentsSortByTimecreated ListDeploymentEnvironmentsSortByEnum = "timeCreated" + ListDeploymentEnvironmentsSortByDisplayname ListDeploymentEnvironmentsSortByEnum = "displayName" +) + +var mappingListDeploymentEnvironmentsSortByEnum = map[string]ListDeploymentEnvironmentsSortByEnum{ + "timeCreated": ListDeploymentEnvironmentsSortByTimecreated, + "displayName": ListDeploymentEnvironmentsSortByDisplayname, +} + +var mappingListDeploymentEnvironmentsSortByEnumLowerCase = map[string]ListDeploymentEnvironmentsSortByEnum{ + "timecreated": ListDeploymentEnvironmentsSortByTimecreated, + "displayname": ListDeploymentEnvironmentsSortByDisplayname, +} + +// GetListDeploymentEnvironmentsSortByEnumValues Enumerates the set of values for ListDeploymentEnvironmentsSortByEnum +func GetListDeploymentEnvironmentsSortByEnumValues() []ListDeploymentEnvironmentsSortByEnum { + values := make([]ListDeploymentEnvironmentsSortByEnum, 0) + for _, v := range mappingListDeploymentEnvironmentsSortByEnum { + values = append(values, v) + } + return values +} + +// GetListDeploymentEnvironmentsSortByEnumStringValues Enumerates the set of values in String for ListDeploymentEnvironmentsSortByEnum +func GetListDeploymentEnvironmentsSortByEnumStringValues() []string { + return []string{ + "timeCreated", + "displayName", + } +} + +// GetMappingListDeploymentEnvironmentsSortByEnum performs case Insensitive comparison on enum value and return the desired enum +func GetMappingListDeploymentEnvironmentsSortByEnum(val string) (ListDeploymentEnvironmentsSortByEnum, bool) { + enum, ok := mappingListDeploymentEnvironmentsSortByEnumLowerCase[strings.ToLower(val)] + return enum, ok +} diff --git a/goldengate/ogg_deployment.go b/goldengate/ogg_deployment.go index ac024c38ba..493c9dcc9c 100644 --- a/goldengate/ogg_deployment.go +++ b/goldengate/ogg_deployment.go @@ -39,6 +39,8 @@ type OggDeployment struct { // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Secret where the deployment password is stored. PasswordSecretId *string `mandatory:"false" json:"passwordSecretId"` + + GroupToRolesMapping *GroupToRolesMappingDetails `mandatory:"false" json:"groupToRolesMapping"` } func (m OggDeployment) String() string { diff --git a/goldengate/test_connection_assignment_result.go b/goldengate/test_connection_assignment_result.go index 4aa432001d..7824f65b1a 100644 --- a/goldengate/test_connection_assignment_result.go +++ b/goldengate/test_connection_assignment_result.go @@ -16,12 +16,16 @@ import ( ) // TestConnectionAssignmentResult The result of the connectivity test performed between the GoldenGate deployment and the associated database / service. +// The 'error' property is deprecated and will not contain values in the future. So, the error(s) will be returned in just the 'errors' property. type TestConnectionAssignmentResult struct { // Type of the result (i.e. Success, Failure or Timeout). ResultType TestConnectionAssignmentResultResultTypeEnum `mandatory:"true" json:"resultType"` Error *TestConnectionAssignmentError `mandatory:"false" json:"error"` + + // List of test connection assignment error objects. + Errors []TestConnectionAssignmentError `mandatory:"false" json:"errors"` } func (m TestConnectionAssignmentResult) String() string { diff --git a/goldengate/update_database_registration_details.go b/goldengate/update_database_registration_details.go index 861659ee8e..f92f2c143a 100644 --- a/goldengate/update_database_registration_details.go +++ b/goldengate/update_database_registration_details.go @@ -54,8 +54,8 @@ type UpdateDatabaseRegistrationDetails struct { // to the database node to connect to. By default the mode would be DIRECT. SessionMode UpdateDatabaseRegistrationDetailsSessionModeEnum `mandatory:"false" json:"sessionMode,omitempty"` - // The wallet contents Oracle GoldenGate uses to make connections to a database. This - // attribute is expected to be base64 encoded. + // The wallet contents Oracle GoldenGate uses to make connections to a database. + // This attribute is expected to be base64 encoded. Wallet *string `mandatory:"false" json:"wallet"` // Credential store alias. diff --git a/goldengate/update_deployment_details.go b/goldengate/update_deployment_details.go index ece0698871..2e9edc63e6 100644 --- a/goldengate/update_deployment_details.go +++ b/goldengate/update_deployment_details.go @@ -24,6 +24,9 @@ type UpdateDeploymentDetails struct { // The Oracle license model that applies to a Deployment. LicenseModel LicenseModelEnum `mandatory:"false" json:"licenseModel,omitempty"` + // Specifies whether the deployment is used in a production or development/testing environment. + EnvironmentType EnvironmentTypeEnum `mandatory:"false" json:"environmentType,omitempty"` + // Metadata about this specific object. Description *string `mandatory:"false" json:"description"` @@ -81,6 +84,9 @@ func (m UpdateDeploymentDetails) ValidateEnumValue() (bool, error) { if _, ok := GetMappingLicenseModelEnum(string(m.LicenseModel)); !ok && m.LicenseModel != "" { errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for LicenseModel: %s. Supported values are: %s.", m.LicenseModel, strings.Join(GetLicenseModelEnumStringValues(), ","))) } + if _, ok := GetMappingEnvironmentTypeEnum(string(m.EnvironmentType)); !ok && m.EnvironmentType != "" { + errMessage = append(errMessage, fmt.Sprintf("unsupported enum value for EnvironmentType: %s. Supported values are: %s.", m.EnvironmentType, strings.Join(GetEnvironmentTypeEnumStringValues(), ","))) + } if len(errMessage) > 0 { return true, fmt.Errorf(strings.Join(errMessage, "\n")) } diff --git a/goldengate/update_group_to_roles_mapping_details.go b/goldengate/update_group_to_roles_mapping_details.go new file mode 100644 index 0000000000..ceb9893c4b --- /dev/null +++ b/goldengate/update_group_to_roles_mapping_details.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2024, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// GoldenGate API +// +// Use the Oracle Cloud Infrastructure GoldenGate APIs to perform data replication operations. +// + +package goldengate + +import ( + "fmt" + "github.com/oracle/oci-go-sdk/v65/common" + "strings" +) + +// UpdateGroupToRolesMappingDetails Defines the IDP Groups to GoldenGate roles mapping. This field is used only for IAM deployment and does not have any impact on non-IAM deployments. +// For IAM deployment, when user does not specify this mapping, then it has null value and default mapping is used. +// User belonging to each group can only perform the actions according to the role the respective group is mapped to. +type UpdateGroupToRolesMappingDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role securityGroup. + // It grants administration of security related objects and invoke security related service requests. This role has full privileges. + SecurityGroupId *string `mandatory:"false" json:"securityGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role administratorGroup. + // It grants full access to the user, including the ability to alter general, non-security related operational parameters + // and profiles of the server. + AdministratorGroupId *string `mandatory:"false" json:"administratorGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role operatorGroup. + // It allows users to perform only operational actions, like starting and stopping resources. + // Operators cannot alter the operational parameters or profiles of the MA server. + OperatorGroupId *string `mandatory:"false" json:"operatorGroupId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IDP group which will be mapped to goldengate role userGroup. + // It allows information-only service requests, which do not alter or affect the operation of either the MA. + // Examples of query and read-only information include performance metric information and resource status and monitoring information + UserGroupId *string `mandatory:"false" json:"userGroupId"` +} + +func (m UpdateGroupToRolesMappingDetails) String() string { + return common.PointerString(m) +} + +// ValidateEnumValue returns an error when providing an unsupported enum value +// This function is being called during constructing API request process +// Not recommended for calling this function directly +func (m UpdateGroupToRolesMappingDetails) ValidateEnumValue() (bool, error) { + errMessage := []string{} + + if len(errMessage) > 0 { + return true, fmt.Errorf(strings.Join(errMessage, "\n")) + } + return false, nil +} diff --git a/goldengate/update_ogg_deployment_details.go b/goldengate/update_ogg_deployment_details.go index 7951fa55f4..445b26aba1 100644 --- a/goldengate/update_ogg_deployment_details.go +++ b/goldengate/update_ogg_deployment_details.go @@ -41,6 +41,8 @@ type UpdateOggDeploymentDetails struct { // The base64 encoded content of the PEM file containing the private key. Key *string `mandatory:"false" json:"key"` + + GroupToRolesMapping *UpdateGroupToRolesMappingDetails `mandatory:"false" json:"groupToRolesMapping"` } func (m UpdateOggDeploymentDetails) String() string { diff --git a/goldengate/update_oracle_connection_details.go b/goldengate/update_oracle_connection_details.go index a8d8c07592..3e3252e5d2 100644 --- a/goldengate/update_oracle_connection_details.go +++ b/goldengate/update_oracle_connection_details.go @@ -61,8 +61,8 @@ type UpdateOracleConnectionDetails struct { // Connect descriptor or Easy Connect Naming method used to connect to a database. ConnectionString *string `mandatory:"false" json:"connectionString"` - // The wallet contents Oracle GoldenGate uses to make connections to a database. This - // attribute is expected to be base64 encoded. + // The wallet contents Oracle GoldenGate uses to make connections to a database. + // This attribute is expected to be base64 encoded. Wallet *string `mandatory:"false" json:"wallet"` // Deprecated: this field will be removed in future versions. Either specify the private IP in the connectionString or host diff --git a/securityattribute/securityattribute_client.go b/securityattribute/securityattribute_client.go index 911d97a96a..3ecbd3b5b4 100644 --- a/securityattribute/securityattribute_client.go +++ b/securityattribute/securityattribute_client.go @@ -160,7 +160,7 @@ func (client SecurityAttributeClient) bulkDeleteSecurityAttributes(ctx context.C defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/BulkDeleteSecurityAttributes" err = common.PostProcessServiceError(err, "SecurityAttribute", "BulkDeleteSecurityAttributes", apiReferenceLink) return response, err } @@ -231,7 +231,7 @@ func (client SecurityAttributeClient) bulkEditSecurityAttributes(ctx context.Con defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/BulkEditSecurityAttributes" err = common.PostProcessServiceError(err, "SecurityAttribute", "BulkEditSecurityAttributes", apiReferenceLink) return response, err } @@ -307,7 +307,7 @@ func (client SecurityAttributeClient) cascadingDeleteSecurityAttributeNamespace( defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/CascadingDeleteSecurityAttributeNamespace" err = common.PostProcessServiceError(err, "SecurityAttribute", "CascadingDeleteSecurityAttributeNamespace", apiReferenceLink) return response, err } @@ -373,7 +373,7 @@ func (client SecurityAttributeClient) changeSecurityAttributeNamespaceCompartmen defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/ChangeSecurityAttributeNamespaceCompartment" err = common.PostProcessServiceError(err, "SecurityAttribute", "ChangeSecurityAttributeNamespaceCompartment", apiReferenceLink) return response, err } @@ -448,7 +448,7 @@ func (client SecurityAttributeClient) createSecurityAttribute(ctx context.Contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/CreateSecurityAttribute" err = common.PostProcessServiceError(err, "SecurityAttribute", "CreateSecurityAttribute", apiReferenceLink) return response, err } @@ -521,7 +521,7 @@ func (client SecurityAttributeClient) createSecurityAttributeNamespace(ctx conte defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/CreateSecurityAttributeNamespace" err = common.PostProcessServiceError(err, "SecurityAttribute", "CreateSecurityAttributeNamespace", apiReferenceLink) return response, err } @@ -593,7 +593,7 @@ func (client SecurityAttributeClient) deleteSecurityAttribute(ctx context.Contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/DeleteSecurityAttribute" err = common.PostProcessServiceError(err, "SecurityAttribute", "DeleteSecurityAttribute", apiReferenceLink) return response, err } @@ -658,7 +658,7 @@ func (client SecurityAttributeClient) deleteSecurityAttributeNamespace(ctx conte defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/DeleteSecurityAttributeNamespace" err = common.PostProcessServiceError(err, "SecurityAttribute", "DeleteSecurityAttributeNamespace", apiReferenceLink) return response, err } @@ -716,7 +716,7 @@ func (client SecurityAttributeClient) getSecurityAttribute(ctx context.Context, defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/GetSecurityAttribute" err = common.PostProcessServiceError(err, "SecurityAttribute", "GetSecurityAttribute", apiReferenceLink) return response, err } @@ -774,7 +774,7 @@ func (client SecurityAttributeClient) getSecurityAttributeNamespace(ctx context. defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/GetSecurityAttributeNamespace" err = common.PostProcessServiceError(err, "SecurityAttribute", "GetSecurityAttributeNamespace", apiReferenceLink) return response, err } @@ -833,7 +833,7 @@ func (client SecurityAttributeClient) getSecurityAttributeWorkRequest(ctx contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeWorkRequest/GetSecurityAttributeWorkRequest" err = common.PostProcessServiceError(err, "SecurityAttribute", "GetSecurityAttributeWorkRequest", apiReferenceLink) return response, err } @@ -891,7 +891,7 @@ func (client SecurityAttributeClient) listSecurityAttributeNamespaces(ctx contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespaceSummary/ListSecurityAttributeNamespaces" err = common.PostProcessServiceError(err, "SecurityAttribute", "ListSecurityAttributeNamespaces", apiReferenceLink) return response, err } @@ -949,7 +949,7 @@ func (client SecurityAttributeClient) listSecurityAttributeWorkRequestErrors(ctx defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeWorkRequestErrorSummary/ListSecurityAttributeWorkRequestErrors" err = common.PostProcessServiceError(err, "SecurityAttribute", "ListSecurityAttributeWorkRequestErrors", apiReferenceLink) return response, err } @@ -1007,7 +1007,7 @@ func (client SecurityAttributeClient) listSecurityAttributeWorkRequestLogs(ctx c defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeWorkRequestLogSummary/ListSecurityAttributeWorkRequestLogs" err = common.PostProcessServiceError(err, "SecurityAttribute", "ListSecurityAttributeWorkRequestLogs", apiReferenceLink) return response, err } @@ -1065,7 +1065,7 @@ func (client SecurityAttributeClient) listSecurityAttributeWorkRequests(ctx cont defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeWorkRequestSummary/ListSecurityAttributeWorkRequests" err = common.PostProcessServiceError(err, "SecurityAttribute", "ListSecurityAttributeWorkRequests", apiReferenceLink) return response, err } @@ -1123,7 +1123,7 @@ func (client SecurityAttributeClient) listSecurityAttributes(ctx context.Context defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeSummary/ListSecurityAttributes" err = common.PostProcessServiceError(err, "SecurityAttribute", "ListSecurityAttributes", apiReferenceLink) return response, err } @@ -1186,7 +1186,7 @@ func (client SecurityAttributeClient) updateSecurityAttribute(ctx context.Contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttribute/UpdateSecurityAttribute" err = common.PostProcessServiceError(err, "SecurityAttribute", "UpdateSecurityAttribute", apiReferenceLink) return response, err } @@ -1255,7 +1255,7 @@ func (client SecurityAttributeClient) updateSecurityAttributeNamespace(ctx conte defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/security-attribute/20240815/SecurityAttributeNamespace/UpdateSecurityAttributeNamespace" err = common.PostProcessServiceError(err, "SecurityAttribute", "UpdateSecurityAttributeNamespace", apiReferenceLink) return response, err } diff --git a/zpr/zpr_client.go b/zpr/zpr_client.go index a55a979c38..eea4e53e8c 100644 --- a/zpr/zpr_client.go +++ b/zpr/zpr_client.go @@ -146,7 +146,7 @@ func (client ZprClient) createConfiguration(ctx context.Context, request common. defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/Configuration/CreateConfiguration" err = common.PostProcessServiceError(err, "Zpr", "CreateConfiguration", apiReferenceLink) return response, err } @@ -209,7 +209,7 @@ func (client ZprClient) createZprPolicy(ctx context.Context, request common.OCIR defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/ZprPolicy/CreateZprPolicy" err = common.PostProcessServiceError(err, "Zpr", "CreateZprPolicy", apiReferenceLink) return response, err } @@ -267,7 +267,7 @@ func (client ZprClient) deleteZprPolicy(ctx context.Context, request common.OCIR defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/ZprPolicy/DeleteZprPolicy" err = common.PostProcessServiceError(err, "Zpr", "DeleteZprPolicy", apiReferenceLink) return response, err } @@ -326,7 +326,7 @@ func (client ZprClient) getConfiguration(ctx context.Context, request common.OCI defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/Configuration/GetConfiguration" err = common.PostProcessServiceError(err, "Zpr", "GetConfiguration", apiReferenceLink) return response, err } @@ -384,7 +384,7 @@ func (client ZprClient) getZprConfigurationWorkRequest(ctx context.Context, requ defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequest/GetZprConfigurationWorkRequest" err = common.PostProcessServiceError(err, "Zpr", "GetZprConfigurationWorkRequest", apiReferenceLink) return response, err } @@ -442,7 +442,7 @@ func (client ZprClient) getZprPolicy(ctx context.Context, request common.OCIRequ defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/ZprPolicy/GetZprPolicy" err = common.PostProcessServiceError(err, "Zpr", "GetZprPolicy", apiReferenceLink) return response, err } @@ -500,7 +500,7 @@ func (client ZprClient) getZprPolicyWorkRequest(ctx context.Context, request com defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequest/GetZprPolicyWorkRequest" err = common.PostProcessServiceError(err, "Zpr", "GetZprPolicyWorkRequest", apiReferenceLink) return response, err } @@ -558,7 +558,7 @@ func (client ZprClient) listZprConfigurationWorkRequestErrors(ctx context.Contex defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequestError/ListZprConfigurationWorkRequestErrors" err = common.PostProcessServiceError(err, "Zpr", "ListZprConfigurationWorkRequestErrors", apiReferenceLink) return response, err } @@ -616,7 +616,7 @@ func (client ZprClient) listZprConfigurationWorkRequestLogs(ctx context.Context, defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequestLogEntry/ListZprConfigurationWorkRequestLogs" err = common.PostProcessServiceError(err, "Zpr", "ListZprConfigurationWorkRequestLogs", apiReferenceLink) return response, err } @@ -674,7 +674,7 @@ func (client ZprClient) listZprConfigurationWorkRequests(ctx context.Context, re defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequest/ListZprConfigurationWorkRequests" err = common.PostProcessServiceError(err, "Zpr", "ListZprConfigurationWorkRequests", apiReferenceLink) return response, err } @@ -732,7 +732,7 @@ func (client ZprClient) listZprPolicies(ctx context.Context, request common.OCIR defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/ZprPolicyCollection/ListZprPolicies" err = common.PostProcessServiceError(err, "Zpr", "ListZprPolicies", apiReferenceLink) return response, err } @@ -790,7 +790,7 @@ func (client ZprClient) listZprPolicyWorkRequestErrors(ctx context.Context, requ defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequestError/ListZprPolicyWorkRequestErrors" err = common.PostProcessServiceError(err, "Zpr", "ListZprPolicyWorkRequestErrors", apiReferenceLink) return response, err } @@ -848,7 +848,7 @@ func (client ZprClient) listZprPolicyWorkRequestLogs(ctx context.Context, reques defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequestLogEntry/ListZprPolicyWorkRequestLogs" err = common.PostProcessServiceError(err, "Zpr", "ListZprPolicyWorkRequestLogs", apiReferenceLink) return response, err } @@ -906,7 +906,7 @@ func (client ZprClient) listZprPolicyWorkRequests(ctx context.Context, request c defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/WorkRequest/ListZprPolicyWorkRequests" err = common.PostProcessServiceError(err, "Zpr", "ListZprPolicyWorkRequests", apiReferenceLink) return response, err } @@ -969,7 +969,7 @@ func (client ZprClient) updateZprPolicy(ctx context.Context, request common.OCIR defer common.CloseBodyIfValid(httpResponse) response.RawResponse = httpResponse if err != nil { - apiReferenceLink := "" + apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/zero-trust-packet-routing/20240301/ZprPolicy/UpdateZprPolicy" err = common.PostProcessServiceError(err, "Zpr", "UpdateZprPolicy", apiReferenceLink) return response, err }