From da336224a5ff32b33d2c63188695a97c9bc6b0e5 Mon Sep 17 00:00:00 2001 From: SK Ali Arman Date: Mon, 20 Nov 2023 18:08:50 +0600 Subject: [PATCH] Update upjet to 1.0.0 Signed-off-by: SK Ali Arman --- .golangci.yml | 2 +- Makefile | 56 +- README.md | 2 +- apis/docdb/v1alpha1/zz_cluster_types.go | 87 +- .../v1alpha1/zz_clusterinstance_types.go | 62 +- .../zz_clusterparametergroup_types.go | 53 +- .../v1alpha1/zz_clustersnapshot_types.go | 22 +- .../v1alpha1/zz_eventsubscription_types.go | 43 +- apis/docdb/v1alpha1/zz_generated.deepcopy.go | 619 +- apis/docdb/v1alpha1/zz_generated.managed.go | 196 +- apis/docdb/v1alpha1/zz_generated.resolvers.go | 2 +- .../v1alpha1/zz_generated_terraformed.go | 289 +- apis/docdb/v1alpha1/zz_globalcluster_types.go | 45 +- apis/docdb/v1alpha1/zz_groupversion_info.go | 4 + apis/docdb/v1alpha1/zz_subnetgroup_types.go | 29 +- .../v1alpha1/zz_contributorinsights_types.go | 23 +- .../v1alpha1/zz_generated.deepcopy.go | 599 +- .../dynamodb/v1alpha1/zz_generated.managed.go | 196 +- .../v1alpha1/zz_generated.resolvers.go | 2 +- .../v1alpha1/zz_generated_terraformed.go | 289 +- .../dynamodb/v1alpha1/zz_globaltable_types.go | 33 +- .../dynamodb/v1alpha1/zz_groupversion_info.go | 4 + .../zz_kinesisstreamingdestination_types.go | 20 +- apis/dynamodb/v1alpha1/zz_table_types.go | 196 +- apis/dynamodb/v1alpha1/zz_tableitem_types.go | 33 +- .../v1alpha1/zz_tablereplica_types.go | 34 +- apis/dynamodb/v1alpha1/zz_tag_types.go | 25 +- apis/ec2/v1alpha1/zz_generated.deepcopy.go | 1040 ++- apis/ec2/v1alpha1/zz_generated.managed.go | 196 +- apis/ec2/v1alpha1/zz_generated.resolvers.go | 2 +- apis/ec2/v1alpha1/zz_generated_terraformed.go | 289 +- apis/ec2/v1alpha1/zz_groupversion_info.go | 4 + apis/ec2/v1alpha1/zz_route_types.go | 64 +- apis/ec2/v1alpha1/zz_securitygroup_types.go | 104 +- .../v1alpha1/zz_securitygrouprule_types.go | 59 +- apis/ec2/v1alpha1/zz_subnet_types.go | 76 +- apis/ec2/v1alpha1/zz_vpc_types.go | 62 +- apis/ec2/v1alpha1/zz_vpcendpoint_types.go | 62 +- .../v1alpha1/zz_vpcpeeringconnection_types.go | 61 +- apis/elasticache/v1alpha1/zz_cluster_types.go | 129 +- .../v1alpha1/zz_generated.deepcopy.go | 966 ++- .../v1alpha1/zz_generated.managed.go | 168 +- .../v1alpha1/zz_generated.resolvers.go | 2 +- .../v1alpha1/zz_generated_terraformed.go | 249 +- .../v1alpha1/zz_groupversion_info.go | 4 + .../v1alpha1/zz_parametergroup_types.go | 55 +- .../v1alpha1/zz_replicationgroup_types.go | 142 +- .../v1alpha1/zz_subnetgroup_types.go | 29 +- apis/elasticache/v1alpha1/zz_user_types.go | 54 +- .../v1alpha1/zz_usergroup_types.go | 31 +- .../elasticsearch/v1alpha1/zz_domain_types.go | 295 +- .../v1alpha1/zz_domainpolicy_types.go | 25 +- .../v1alpha1/zz_domainsamloptions_types.go | 57 +- .../v1alpha1/zz_generated.deepcopy.go | 803 ++- .../v1alpha1/zz_generated.managed.go | 84 +- .../v1alpha1/zz_generated_terraformed.go | 129 +- .../v1alpha1/zz_groupversion_info.go | 4 + apis/generate.go | 2 +- apis/kafka/v1alpha1/zz_cluster_types.go | 260 +- apis/kafka/v1alpha1/zz_configuration_types.go | 38 +- apis/kafka/v1alpha1/zz_generated.deepcopy.go | 767 ++- apis/kafka/v1alpha1/zz_generated.managed.go | 56 +- .../v1alpha1/zz_generated_terraformed.go | 89 +- apis/kafka/v1alpha1/zz_groupversion_info.go | 4 + .../kinesis/v1alpha1/zz_generated.deepcopy.go | 119 +- apis/kinesis/v1alpha1/zz_generated.managed.go | 28 +- .../v1alpha1/zz_generated_terraformed.go | 49 +- apis/kinesis/v1alpha1/zz_groupversion_info.go | 4 + apis/kinesis/v1alpha1/zz_stream_types.go | 53 +- apis/kms/v1alpha1/zz_generated.deepcopy.go | 111 +- apis/kms/v1alpha1/zz_generated.managed.go | 28 +- apis/kms/v1alpha1/zz_generated_terraformed.go | 49 +- apis/kms/v1alpha1/zz_groupversion_info.go | 4 + apis/kms/v1alpha1/zz_key_types.go | 63 +- apis/memorydb/v1alpha1/zz_acl_types.go | 29 +- apis/memorydb/v1alpha1/zz_cluster_types.go | 98 +- .../v1alpha1/zz_generated.deepcopy.go | 530 +- .../memorydb/v1alpha1/zz_generated.managed.go | 140 +- .../v1alpha1/zz_generated.resolvers.go | 2 +- .../v1alpha1/zz_generated_terraformed.go | 209 +- .../memorydb/v1alpha1/zz_groupversion_info.go | 4 + .../v1alpha1/zz_parametergroup_types.go | 50 +- apis/memorydb/v1alpha1/zz_snapshot_types.go | 29 +- .../memorydb/v1alpha1/zz_subnetgroup_types.go | 29 +- apis/rds/v1alpha1/zz_cluster_types.go | 219 +- .../zz_clusteractivitystream_types.go | 30 +- apis/rds/v1alpha1/zz_clusterendpoint_types.go | 39 +- apis/rds/v1alpha1/zz_clusterinstance_types.go | 83 +- .../zz_clusterparametergroup_types.go | 55 +- .../zz_clusterroleassociation_types.go | 32 +- apis/rds/v1alpha1/zz_clustersnapshot_types.go | 33 +- ...stanceautomatedbackupsreplication_types.go | 28 +- apis/rds/v1alpha1/zz_dbsnapshotcopy_types.go | 48 +- .../v1alpha1/zz_eventsubscription_types.go | 43 +- apis/rds/v1alpha1/zz_generated.deepcopy.go | 5785 ++++++++++++----- apis/rds/v1alpha1/zz_generated.managed.go | 588 +- apis/rds/v1alpha1/zz_generated.resolvers.go | 2 +- apis/rds/v1alpha1/zz_generated_terraformed.go | 849 ++- apis/rds/v1alpha1/zz_globalcluster_types.go | 43 +- apis/rds/v1alpha1/zz_groupversion_info.go | 4 + apis/rds/v1alpha1/zz_instance_types.go | 294 +- .../zz_instanceroleassociation_types.go | 30 +- apis/rds/v1alpha1/zz_optiongroup_types.go | 78 +- apis/rds/v1alpha1/zz_parametergroup_types.go | 55 +- apis/rds/v1alpha1/zz_proxy_types.go | 76 +- .../zz_proxydefaulttargetgroup_types.go | 41 +- apis/rds/v1alpha1/zz_proxyendpoint_types.go | 33 +- apis/rds/v1alpha1/zz_proxytarget_types.go | 28 +- apis/rds/v1alpha1/zz_snapshot_types.go | 29 +- apis/rds/v1alpha1/zz_subnetgroup_types.go | 29 +- apis/v1alpha1/zz_generated.deepcopy.go | 1 - apis/v1beta1/zz_generated.deepcopy.go | 1 - apis/zz_register.go | 4 + cmd/generator/main.go | 2 +- cmd/provider/main.go | 39 +- config/common/config.go | 2 +- config/docdb/config.go | 2 +- config/dynamodb/config.go | 2 +- config/ec2/config.go | 2 +- config/elasticache/config.go | 2 +- config/external_name.go | 2 +- config/groups.go | 2 +- config/kafka/config.go | 2 +- config/kinesis/config.go | 2 +- config/memorydb/config.go | 2 +- config/overrides.go | 6 +- config/provider-metadata.yaml | 112 +- config/provider.go | 4 +- config/rds/config.go | 4 +- examples-generated/docdb/cluster.yaml | 3 - examples-generated/docdb/clusterinstance.yaml | 3 - .../docdb/clusterparametergroup.yaml | 3 - examples-generated/docdb/clustersnapshot.yaml | 3 - .../docdb/eventsubscription.yaml | 3 - examples-generated/docdb/globalcluster.yaml | 3 - examples-generated/docdb/subnetgroup.yaml | 3 - .../dynamodb/contributorinsights.yaml | 3 - examples-generated/dynamodb/globaltable.yaml | 3 - .../dynamodb/kinesisstreamingdestination.yaml | 3 - examples-generated/dynamodb/table.yaml | 3 - examples-generated/dynamodb/tableitem.yaml | 3 - examples-generated/dynamodb/tablereplica.yaml | 3 - examples-generated/dynamodb/tag.yaml | 3 - examples-generated/ec2/route.yaml | 3 - examples-generated/ec2/securitygroup.yaml | 3 - examples-generated/ec2/securitygrouprule.yaml | 3 - examples-generated/ec2/subnet.yaml | 3 - examples-generated/ec2/vpc.yaml | 3 - examples-generated/ec2/vpcendpoint.yaml | 3 - .../ec2/vpcpeeringconnection.yaml | 3 - examples-generated/elasticache/cluster.yaml | 3 - .../elasticache/parametergroup.yaml | 3 - .../elasticache/replicationgroup.yaml | 3 - .../elasticache/subnetgroup.yaml | 3 - examples-generated/elasticache/user.yaml | 3 - examples-generated/elasticache/usergroup.yaml | 3 - examples-generated/elasticsearch/domain.yaml | 3 - .../elasticsearch/domainpolicy.yaml | 3 - .../elasticsearch/domainsamloptions.yaml | 3 - examples-generated/kafka/cluster.yaml | 3 - examples-generated/kafka/configuration.yaml | 3 - examples-generated/kinesis/stream.yaml | 3 - examples-generated/kms/key.yaml | 3 - examples-generated/memorydb/acl.yaml | 3 - examples-generated/memorydb/cluster.yaml | 3 - .../memorydb/parametergroup.yaml | 3 - examples-generated/memorydb/snapshot.yaml | 3 - examples-generated/memorydb/subnetgroup.yaml | 3 - examples-generated/rds/cluster.yaml | 3 - .../rds/clusteractivitystream.yaml | 3 - examples-generated/rds/clusterendpoint.yaml | 3 - examples-generated/rds/clusterinstance.yaml | 3 - .../rds/clusterparametergroup.yaml | 3 - .../rds/clusterroleassociation.yaml | 3 - examples-generated/rds/clustersnapshot.yaml | 3 - ...dbinstanceautomatedbackupsreplication.yaml | 3 - examples-generated/rds/dbsnapshotcopy.yaml | 3 - examples-generated/rds/eventsubscription.yaml | 3 - examples-generated/rds/globalcluster.yaml | 3 - examples-generated/rds/instance.yaml | 3 - .../rds/instanceroleassociation.yaml | 3 - examples-generated/rds/optiongroup.yaml | 3 - examples-generated/rds/parametergroup.yaml | 3 - examples-generated/rds/proxy.yaml | 3 - .../rds/proxydefaulttargetgroup.yaml | 3 - examples-generated/rds/proxyendpoint.yaml | 3 - examples-generated/rds/proxytarget.yaml | 3 - examples-generated/rds/snapshot.yaml | 3 - examples-generated/rds/subnetgroup.yaml | 3 - go.mod | 128 +- go.sum | 464 +- hack/embed.go | 8 + hack/main.go.tmpl | 117 + internal/clients/aws.go | 2 +- .../controller/docdb/cluster/zz_controller.go | 23 +- .../docdb/clusterinstance/zz_controller.go | 23 +- .../clusterparametergroup/zz_controller.go | 23 +- .../docdb/clustersnapshot/zz_controller.go | 23 +- .../docdb/eventsubscription/zz_controller.go | 23 +- .../docdb/globalcluster/zz_controller.go | 23 +- .../docdb/subnetgroup/zz_controller.go | 23 +- .../contributorinsights/zz_controller.go | 23 +- .../dynamodb/globaltable/zz_controller.go | 23 +- .../zz_controller.go | 23 +- .../dynamodb/table/zz_controller.go | 23 +- .../dynamodb/tableitem/zz_controller.go | 23 +- .../dynamodb/tablereplica/zz_controller.go | 23 +- .../controller/dynamodb/tag/zz_controller.go | 23 +- .../controller/ec2/route/zz_controller.go | 23 +- .../ec2/securitygroup/zz_controller.go | 23 +- .../ec2/securitygrouprule/zz_controller.go | 23 +- .../controller/ec2/subnet/zz_controller.go | 23 +- internal/controller/ec2/vpc/zz_controller.go | 23 +- .../ec2/vpcendpoint/zz_controller.go | 23 +- .../ec2/vpcpeeringconnection/zz_controller.go | 23 +- .../elasticache/cluster/zz_controller.go | 23 +- .../parametergroup/zz_controller.go | 23 +- .../replicationgroup/zz_controller.go | 23 +- .../elasticache/subnetgroup/zz_controller.go | 23 +- .../elasticache/user/zz_controller.go | 23 +- .../elasticache/usergroup/zz_controller.go | 23 +- .../elasticsearch/domain/zz_controller.go | 23 +- .../domainpolicy/zz_controller.go | 23 +- .../domainsamloptions/zz_controller.go | 23 +- .../controller/kafka/cluster/zz_controller.go | 23 +- .../kafka/configuration/zz_controller.go | 23 +- .../kinesis/stream/zz_controller.go | 23 +- internal/controller/kms/key/zz_controller.go | 23 +- .../controller/memorydb/acl/zz_controller.go | 23 +- .../memorydb/cluster/zz_controller.go | 23 +- .../memorydb/parametergroup/zz_controller.go | 23 +- .../memorydb/snapshot/zz_controller.go | 23 +- .../memorydb/subnetgroup/zz_controller.go | 23 +- internal/controller/providerconfig/config.go | 8 +- .../controller/rds/cluster/zz_controller.go | 23 +- .../clusteractivitystream/zz_controller.go | 23 +- .../rds/clusterendpoint/zz_controller.go | 23 +- .../rds/clusterinstance/zz_controller.go | 23 +- .../clusterparametergroup/zz_controller.go | 23 +- .../clusterroleassociation/zz_controller.go | 23 +- .../rds/clustersnapshot/zz_controller.go | 23 +- .../zz_controller.go | 23 +- .../rds/dbsnapshotcopy/zz_controller.go | 23 +- .../rds/eventsubscription/zz_controller.go | 23 +- .../rds/globalcluster/zz_controller.go | 23 +- .../controller/rds/instance/zz_controller.go | 23 +- .../instanceroleassociation/zz_controller.go | 23 +- .../rds/optiongroup/zz_controller.go | 23 +- .../rds/parametergroup/zz_controller.go | 23 +- .../controller/rds/proxy/zz_controller.go | 23 +- .../proxydefaulttargetgroup/zz_controller.go | 23 +- .../rds/proxyendpoint/zz_controller.go | 23 +- .../rds/proxytarget/zz_controller.go | 23 +- .../controller/rds/snapshot/zz_controller.go | 23 +- .../rds/subnetgroup/zz_controller.go | 23 +- internal/controller/zz_setup.go | 8 +- internal/features/features.go | 10 +- .../crds/aws.kubedb.com_providerconfigs.yaml | 6 +- .../aws.kubedb.com_providerconfigusages.yaml | 3 +- package/crds/aws.kubedb.com_storeconfigs.yaml | 146 +- ...docdb.aws.kubedb.com_clusterinstances.yaml | 169 +- ...aws.kubedb.com_clusterparametergroups.yaml | 151 +- .../crds/docdb.aws.kubedb.com_clusters.yaml | 199 +- ...docdb.aws.kubedb.com_clustersnapshots.yaml | 101 +- ...cdb.aws.kubedb.com_eventsubscriptions.yaml | 151 +- .../docdb.aws.kubedb.com_globalclusters.yaml | 135 +- .../docdb.aws.kubedb.com_subnetgroups.yaml | 119 +- ...db.aws.kubedb.com_contributorinsights.yaml | 105 +- .../dynamodb.aws.kubedb.com_globaltables.yaml | 121 +- ...bedb.com_kinesisstreamingdestinations.yaml | 101 +- .../dynamodb.aws.kubedb.com_tableitems.yaml | 128 +- ...dynamodb.aws.kubedb.com_tablereplicas.yaml | 125 +- .../crds/dynamodb.aws.kubedb.com_tables.yaml | 349 +- .../crds/dynamodb.aws.kubedb.com_tags.yaml | 111 +- package/crds/ec2.aws.kubedb.com_routes.yaml | 154 +- ...ec2.aws.kubedb.com_securitygrouprules.yaml | 171 +- .../ec2.aws.kubedb.com_securitygroups.yaml | 249 +- package/crds/ec2.aws.kubedb.com_subnets.yaml | 186 +- .../crds/ec2.aws.kubedb.com_vpcendpoints.yaml | 168 +- ....aws.kubedb.com_vpcpeeringconnections.yaml | 156 +- package/crds/ec2.aws.kubedb.com_vpcs.yaml | 180 +- .../elasticache.aws.kubedb.com_clusters.yaml | 268 +- ...icache.aws.kubedb.com_parametergroups.yaml | 152 +- ...ache.aws.kubedb.com_replicationgroups.yaml | 299 +- ...asticache.aws.kubedb.com_subnetgroups.yaml | 119 +- ...elasticache.aws.kubedb.com_usergroups.yaml | 125 +- .../elasticache.aws.kubedb.com_users.yaml | 156 +- ...csearch.aws.kubedb.com_domainpolicies.yaml | 112 +- .../elasticsearch.aws.kubedb.com_domains.yaml | 468 +- ...arch.aws.kubedb.com_domainsamloptions.yaml | 148 +- .../crds/kafka.aws.kubedb.com_clusters.yaml | 428 +- .../kafka.aws.kubedb.com_configurations.yaml | 135 +- .../crds/kinesis.aws.kubedb.com_streams.yaml | 159 +- package/crds/kms.aws.kubedb.com_keys.yaml | 172 +- .../crds/memorydb.aws.kubedb.com_acls.yaml | 122 +- .../memorydb.aws.kubedb.com_clusters.yaml | 210 +- ...morydb.aws.kubedb.com_parametergroups.yaml | 146 +- .../memorydb.aws.kubedb.com_snapshots.yaml | 116 +- .../memorydb.aws.kubedb.com_subnetgroups.yaml | 119 +- ...aws.kubedb.com_clusteractivitystreams.yaml | 120 +- .../rds.aws.kubedb.com_clusterendpoints.yaml | 139 +- .../rds.aws.kubedb.com_clusterinstances.yaml | 208 +- ...aws.kubedb.com_clusterparametergroups.yaml | 151 +- ...ws.kubedb.com_clusterroleassociations.yaml | 124 +- package/crds/rds.aws.kubedb.com_clusters.yaml | 428 +- .../rds.aws.kubedb.com_clustersnapshots.yaml | 126 +- ...binstanceautomatedbackupsreplications.yaml | 111 +- .../rds.aws.kubedb.com_dbsnapshotcopies.yaml | 142 +- ...rds.aws.kubedb.com_eventsubscriptions.yaml | 150 +- .../rds.aws.kubedb.com_globalclusters.yaml | 134 +- ...s.kubedb.com_instanceroleassociations.yaml | 124 +- .../crds/rds.aws.kubedb.com_instances.yaml | 450 +- .../crds/rds.aws.kubedb.com_optiongroups.yaml | 185 +- .../rds.aws.kubedb.com_parametergroups.yaml | 151 +- package/crds/rds.aws.kubedb.com_proxies.yaml | 216 +- ...s.kubedb.com_proxydefaulttargetgroups.yaml | 154 +- .../rds.aws.kubedb.com_proxyendpoints.yaml | 128 +- .../crds/rds.aws.kubedb.com_proxytargets.yaml | 114 +- .../crds/rds.aws.kubedb.com_snapshots.yaml | 122 +- .../crds/rds.aws.kubedb.com_subnetgroups.yaml | 119 +- 320 files changed, 24337 insertions(+), 8323 deletions(-) create mode 100644 hack/embed.go create mode 100644 hack/main.go.tmpl diff --git a/.golangci.yml b/.golangci.yml index 494a907..0126459 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -38,7 +38,7 @@ linters-settings: goimports: # put imports beginning with prefix after 3rd-party packages; # it's a comma-separated list of prefixes - local-prefixes: github.com/upbound/upjet-provider-template + local-prefixes: github.com/crossplane/upjet-provider-template gocyclo: # minimal code complexity to report, 30 by default (but we recommend 10-20) diff --git a/Makefile b/Makefile index 92eddbb..25262d4 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ PROJECT_NAME ?= provider-aws PROJECT_REPO ?= kubedb.dev/$(PROJECT_NAME) -export TERRAFORM_VERSION ?= 1.3.3 +export TERRAFORM_VERSION ?= 1.5.5 export TERRAFORM_PROVIDER_SOURCE ?= hashicorp/aws export TERRAFORM_PROVIDER_REPO ?= https://github.com/hashicorp/terraform-provider-aws @@ -40,7 +40,7 @@ NPROCS ?= 1 # to half the number of CPU cores. GO_TEST_PARALLEL := $(shell echo $$(( $(NPROCS) / 2 ))) -GO_REQUIRED_VERSION ?= 1.20 +GO_REQUIRED_VERSION ?= 1.19 GOLANGCILINT_VERSION ?= 1.50.0 GO_STATIC_PACKAGES = $(GO_PROJECT)/cmd/provider $(GO_PROJECT)/cmd/generator GO_LDFLAGS += -X $(GO_PROJECT)/internal/version.Version=$(VERSION) @@ -51,9 +51,9 @@ GO_SUBDIRS += cmd internal apis # Setup Kubernetes tools KIND_VERSION = v0.15.0 -UP_VERSION = v0.14.0 +UP_VERSION = v0.18.0 UP_CHANNEL = stable -UPTEST_VERSION = v0.2.1 +UPTEST_VERSION = v0.5.0 -include build/makelib/k8s_tools.mk # ==================================================================================== @@ -61,8 +61,7 @@ UPTEST_VERSION = v0.2.1 REGISTRY_ORGS ?= xpkg.upbound.io/upbound IMAGES = $(PROJECT_NAME) -DOCKER_REGISTRY=ghcr.io/kubedb --include build/makelib/image.mk +-include build/makelib/imagelight.mk # ==================================================================================== # Setup XPKG @@ -72,7 +71,7 @@ XPKG_REG_ORGS ?= xpkg.upbound.io/upbound # inferred. XPKG_REG_ORGS_NO_PROMOTE ?= xpkg.upbound.io/upbound XPKGS = $(PROJECT_NAME) -# -include build/makelib/xpkg.mk +-include build/makelib/xpkg.mk # ==================================================================================== # Fallthrough @@ -167,9 +166,23 @@ CROSSPLANE_NAMESPACE = upbound-system -include build/makelib/local.xpkg.mk -include build/makelib/controlplane.mk +# This target requires the following environment variables to be set: +# - UPTEST_EXAMPLE_LIST, a comma-separated list of examples to test +# To ensure the proper functioning of the end-to-end test resource pre-deletion hook, it is crucial to arrange your resources appropriately. +# You can check the basic implementation here: https://github.com/upbound/uptest/blob/main/internal/awss/01-delete.yaml.tmpl. +# - UPTEST_CLOUD_CREDENTIALS (optional), multiple sets of AWS IAM User credentials specified as key=value pairs. +# The support keys are currently `DEFAULT` and `PEER`. So, an example for the value of this env. variable is: +# DEFAULT='[default] +# aws_access_key_id = REDACTED +# aws_secret_access_key = REDACTED' +# PEER='[default] +# aws_access_key_id = REDACTED +# aws_secret_access_key = REDACTED' +# The associated `ProviderConfig`s will be named as `default` and `peer`. +# - UPTEST_DATASOURCE_PATH (optional), see https://github.com/upbound/uptest#injecting-dynamic-values-and-datasource uptest: $(UPTEST) $(KUBECTL) $(KUTTL) @$(INFO) running automated tests - @KUBECTL=$(KUBECTL) KUTTL=$(KUTTL) $(UPTEST) e2e "${UPTEST_EXAMPLE_LIST}" --setup-script=cluster/test/setup.sh || $(FAIL) + @KUBECTL=$(KUBECTL) KUTTL=$(KUTTL) $(UPTEST) e2e "${UPTEST_EXAMPLE_LIST}" --data-source="${UPTEST_DATASOURCE_PATH}" --setup-script=cluster/test/setup.sh --default-conditions="Test" || $(FAIL) @$(OK) running automated tests local-deploy: build controlplane.up local.xpkg.deploy.provider.$(PROJECT_NAME) @@ -180,6 +193,33 @@ local-deploy: build controlplane.up local.xpkg.deploy.provider.$(PROJECT_NAME) e2e: local-deploy uptest +crddiff: $(UPTEST) + @$(INFO) Checking breaking CRD schema changes + @for crd in $${MODIFIED_CRD_LIST}; do \ + if ! git cat-file -e "$${GITHUB_BASE_REF}:$${crd}" 2>/dev/null; then \ + echo "CRD $${crd} does not exist in the $${GITHUB_BASE_REF} branch. Skipping..." ; \ + continue ; \ + fi ; \ + echo "Checking $${crd} for breaking API changes..." ; \ + changes_detected=$$($(UPTEST) crddiff revision <(git cat-file -p "$${GITHUB_BASE_REF}:$${crd}") "$${crd}" 2>&1) ; \ + if [[ $$? != 0 ]] ; then \ + printf "\033[31m"; echo "Breaking change detected!"; printf "\033[0m" ; \ + echo "$${changes_detected}" ; \ + echo ; \ + fi ; \ + done + @$(OK) Checking breaking CRD schema changes + +schema-version-diff: + @$(INFO) Checking for native state schema version changes + @export PREV_PROVIDER_VERSION=$$(git cat-file -p "${GITHUB_BASE_REF}:Makefile" | sed -nr 's/^export[[:space:]]*TERRAFORM_PROVIDER_VERSION[[:space:]]*:=[[:space:]]*(.+)/\1/p'); \ + echo Detected previous Terraform provider version: $${PREV_PROVIDER_VERSION}; \ + echo Current Terraform provider version: $${TERRAFORM_PROVIDER_VERSION}; \ + mkdir -p $(WORK_DIR); \ + git cat-file -p "$${GITHUB_BASE_REF}:config/schema.json" > "$(WORK_DIR)/schema.json.$${PREV_PROVIDER_VERSION}"; \ + ./scripts/version_diff.py config/generated.lst "$(WORK_DIR)/schema.json.$${PREV_PROVIDER_VERSION}" config/schema.json + @$(OK) Checking for native state schema version changes + .PHONY: cobertura submodules fallthrough run crds.clean # ==================================================================================== diff --git a/README.md b/README.md index b87220c..44fccab 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Provider AWS `provider-aws` is a [Crossplane](https://crossplane.io/) provider that -is built using [Upjet](https://github.com/upbound/upjet) code +is built using [Upjet](https://github.com/crossplane/upjet) code generation tools and exposes XRM-conformant managed resources for the AWS API. diff --git a/apis/docdb/v1alpha1/zz_cluster_types.go b/apis/docdb/v1alpha1/zz_cluster_types.go index 3c20e4e..b5e5b18 100755 --- a/apis/docdb/v1alpha1/zz_cluster_types.go +++ b/apis/docdb/v1alpha1/zz_cluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,76 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterInitParameters struct { + + // Specifies whether any cluster modifications + // are applied immediately, or during the next maintenance window. Default is + // false. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // A list of EC2 Availability Zones that + // instances in the DB cluster can be created in. + AvailabilityZones []*string `json:"availabilityZones,omitempty" tf:"availability_zones,omitempty"` + + // The days to retain backups for. Default 1 + BackupRetentionPeriod *float64 `json:"backupRetentionPeriod,omitempty" tf:"backup_retention_period,omitempty"` + + // A cluster parameter group to associate with the cluster. + DBClusterParameterGroupName *string `json:"dbClusterParameterGroupName,omitempty" tf:"db_cluster_parameter_group_name,omitempty"` + + // A DB subnet group to associate with this DB instance. + DBSubnetGroupName *string `json:"dbSubnetGroupName,omitempty" tf:"db_subnet_group_name,omitempty"` + + // A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when deletion protection is enabled. By default, deletion protection is disabled. + DeletionProtection *bool `json:"deletionProtection,omitempty" tf:"deletion_protection,omitempty"` + + // List of log types to export to cloudwatch. If omitted, no logs will be exported. + // The following log types are supported: audit, profiler. + EnabledCloudwatchLogsExports []*string `json:"enabledCloudwatchLogsExports,omitempty" tf:"enabled_cloudwatch_logs_exports,omitempty"` + + // The name of the database engine to be used for this DB cluster. Defaults to docdb. Valid Values: docdb + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // The database engine version. Updating this argument results in an outage. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // The name of your final DB snapshot + // when this DB cluster is deleted. If omitted, no final snapshot will be + // made. + FinalSnapshotIdentifier *string `json:"finalSnapshotIdentifier,omitempty" tf:"final_snapshot_identifier,omitempty"` + + // The global cluster identifier specified on aws_docdb_global_cluster. + GlobalClusterIdentifier *string `json:"globalClusterIdentifier,omitempty" tf:"global_cluster_identifier,omitempty"` + + // Username for the master DB user. + MasterUsername *string `json:"masterUsername,omitempty" tf:"master_username,omitempty"` + + // The port on which the DB accepts connections + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // The daily time range during which automated backups are created if automated backups are enabled using the BackupRetentionPeriod parameter.Time in UTC + // Default: A 30-minute window selected at random from an 8-hour block of time per regionE.g., 04:00-09:00 + PreferredBackupWindow *string `json:"preferredBackupWindow,omitempty" tf:"preferred_backup_window,omitempty"` + + // The weekly time range during which system maintenance can occur, in (UTC) e.g., wed:04:00-wed:04:30 + PreferredMaintenanceWindow *string `json:"preferredMaintenanceWindow,omitempty" tf:"preferred_maintenance_window,omitempty"` + + // Determines whether a final DB snapshot is created before the DB cluster is deleted. If true is specified, no DB snapshot is created. If false is specified, a DB snapshot is created before the DB cluster is deleted, using the value from final_snapshot_identifier. Default is false. + SkipFinalSnapshot *bool `json:"skipFinalSnapshot,omitempty" tf:"skip_final_snapshot,omitempty"` + + // Specifies whether or not to create this cluster from a snapshot. You can use either the name or ARN when specifying a DB cluster snapshot, or the ARN when specifying a DB snapshot. Automated snapshots should not be used for this attribute, unless from a different cluster. Automated snapshots are deleted as part of cluster destruction when the resource is replaced. + SnapshotIdentifier *string `json:"snapshotIdentifier,omitempty" tf:"snapshot_identifier,omitempty"` + + // Specifies whether the DB cluster is encrypted. The default is false. + StorageEncrypted *bool `json:"storageEncrypted,omitempty" tf:"storage_encrypted,omitempty"` + + // A map of tags to assign to the DB cluster. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterObservation struct { // Specifies whether any cluster modifications @@ -244,6 +318,17 @@ type ClusterParameters struct { type ClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInitParameters `json:"initProvider,omitempty"` } // ClusterStatus defines the observed state of Cluster. @@ -264,7 +349,7 @@ type ClusterStatus struct { type Cluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSpec `json:"spec"` Status ClusterStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_clusterinstance_types.go b/apis/docdb/v1alpha1/zz_clusterinstance_types.go index cdb8102..5e31fd6 100755 --- a/apis/docdb/v1alpha1/zz_clusterinstance_types.go +++ b/apis/docdb/v1alpha1/zz_clusterinstance_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,49 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterInstanceInitParameters struct { + + // Specifies whether any database modifications + // are applied immediately, or during the next maintenance window. Default isfalse. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // This parameter does not apply to Amazon DocumentDB. Amazon DocumentDB does not perform minor version upgrades regardless of the value set (see docs). Default true. + AutoMinorVersionUpgrade *bool `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // The EC2 Availability Zone that the DB instance is created in. See docs about the details. + AvailabilityZone *string `json:"availabilityZone,omitempty" tf:"availability_zone,omitempty"` + + // The identifier of the CA certificate for the DB instance. + CACertIdentifier *string `json:"caCertIdentifier,omitempty" tf:"ca_cert_identifier,omitempty"` + + // A value that indicates whether to enable Performance Insights for the DB Instance. Default false. See [docs] (https://docs.aws.amazon.com/documentdb/latest/developerguide/performance-insights.html) about the details. + EnablePerformanceInsights *bool `json:"enablePerformanceInsights,omitempty" tf:"enable_performance_insights,omitempty"` + + // The name of the database engine to be used for the DocumentDB instance. Defaults to docdb. Valid Values: docdb. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // The instance class to use. For details on CPU and memory, see Scaling for DocumentDB Instances. + // DocumentDB currently supports the below instance classes. + // Please see AWS Documentation for complete details. + InstanceClass *string `json:"instanceClass,omitempty" tf:"instance_class,omitempty"` + + // The KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. If you do not specify a value for PerformanceInsightsKMSKeyId, then Amazon DocumentDB uses your default KMS key. + PerformanceInsightsKMSKeyID *string `json:"performanceInsightsKmsKeyId,omitempty" tf:"performance_insights_kms_key_id,omitempty"` + + // The window to perform maintenance in. + // Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00". + PreferredMaintenanceWindow *string `json:"preferredMaintenanceWindow,omitempty" tf:"preferred_maintenance_window,omitempty"` + + // Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer. + PromotionTier *float64 `json:"promotionTier,omitempty" tf:"promotion_tier,omitempty"` + + // A map of tags to assign to the instance. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterInstanceObservation struct { // Specifies whether any database modifications @@ -170,6 +217,17 @@ type ClusterInstanceParameters struct { type ClusterInstanceSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterInstanceParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInstanceInitParameters `json:"initProvider,omitempty"` } // ClusterInstanceStatus defines the observed state of ClusterInstance. @@ -190,8 +248,8 @@ type ClusterInstanceStatus struct { type ClusterInstance struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass)",message="instanceClass is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.instanceClass) || (has(self.initProvider) && has(self.initProvider.instanceClass))",message="spec.forProvider.instanceClass is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterInstanceSpec `json:"spec"` Status ClusterInstanceStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_clusterparametergroup_types.go b/apis/docdb/v1alpha1/zz_clusterparametergroup_types.go index c7f099d..e275228 100755 --- a/apis/docdb/v1alpha1/zz_clusterparametergroup_types.go +++ b/apis/docdb/v1alpha1/zz_clusterparametergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterParameterGroupInitParameters struct { + + // The description of the DocumentDB cluster parameter group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // The family of the DocumentDB cluster parameter group. + Family *string `json:"family,omitempty" tf:"family,omitempty"` + + // A list of DocumentDB parameters to apply. Setting parameters to system default values may show a difference on imported resources. + Parameter []ParameterInitParameters `json:"parameter,omitempty" tf:"parameter,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterParameterGroupObservation struct { // The ARN of the DocumentDB cluster parameter group. @@ -65,6 +87,18 @@ type ClusterParameterGroupParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ParameterInitParameters struct { + + // Valid values are immediate and pending-reboot. Defaults to pending-reboot. + ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` + + // The name of the DocumentDB cluster parameter group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The value of the DocumentDB parameter. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type ParameterObservation struct { // Valid values are immediate and pending-reboot. Defaults to pending-reboot. @@ -84,11 +118,11 @@ type ParameterParameters struct { ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` // The name of the DocumentDB cluster parameter group. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The value of the DocumentDB parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -96,6 +130,17 @@ type ParameterParameters struct { type ClusterParameterGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameterGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterParameterGroupInitParameters `json:"initProvider,omitempty"` } // ClusterParameterGroupStatus defines the observed state of ClusterParameterGroup. @@ -116,8 +161,8 @@ type ClusterParameterGroupStatus struct { type ClusterParameterGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family)",message="family is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.family) || (has(self.initProvider) && has(self.initProvider.family))",message="spec.forProvider.family is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterParameterGroupSpec `json:"spec"` Status ClusterParameterGroupStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_clustersnapshot_types.go b/apis/docdb/v1alpha1/zz_clustersnapshot_types.go index b47f857..1172011 100755 --- a/apis/docdb/v1alpha1/zz_clustersnapshot_types.go +++ b/apis/docdb/v1alpha1/zz_clustersnapshot_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterSnapshotInitParameters struct { +} + type ClusterSnapshotObservation struct { // List of EC2 Availability Zones that instances in the DocumentDB cluster snapshot can be restored in. @@ -57,7 +64,7 @@ type ClusterSnapshotParameters struct { // The DocumentDB Cluster Identifier from which to take the snapshot. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/docdb/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional DBClusterIdentifier *string `json:"dbClusterIdentifier,omitempty" tf:"db_cluster_identifier,omitempty"` @@ -79,6 +86,17 @@ type ClusterSnapshotParameters struct { type ClusterSnapshotSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterSnapshotParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterSnapshotInitParameters `json:"initProvider,omitempty"` } // ClusterSnapshotStatus defines the observed state of ClusterSnapshot. @@ -99,7 +117,7 @@ type ClusterSnapshotStatus struct { type ClusterSnapshot struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSnapshotSpec `json:"spec"` Status ClusterSnapshotStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_eventsubscription_types.go b/apis/docdb/v1alpha1/zz_eventsubscription_types.go index 5254187..ca3a4a1 100755 --- a/apis/docdb/v1alpha1/zz_eventsubscription_types.go +++ b/apis/docdb/v1alpha1/zz_eventsubscription_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,30 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type EventSubscriptionInitParameters struct { + + // A boolean flag to enable/disable the subscription. Defaults to true. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // A list of event categories for a SourceType that you want to subscribe to. See https://docs.aws.amazon.com/documentdb/latest/developerguide/API_Event.html or run aws docdb describe-event-categories. + EventCategories []*string `json:"eventCategories,omitempty" tf:"event_categories,omitempty"` + + // The Amazon Resource Name of the DocumentDB event notification subscription + SnsTopicArn *string `json:"snsTopicArn,omitempty" tf:"sns_topic_arn,omitempty"` + + // A list of identifiers of the event sources for which events will be returned. If not specified, then all sources are included in the response. If specified, a source_type must also be specified. + SourceIds []*string `json:"sourceIds,omitempty" tf:"source_ids,omitempty"` + + // The type of source that will be generating the events. Valid options are db-instance, db-cluster, db-parameter-group, db-security-group, db-cluster-snapshot. If not set, all sources will be subscribed to. + SourceType *string `json:"sourceType,omitempty" tf:"source_type,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type EventSubscriptionObservation struct { // The Amazon Resource Name of the DocumentDB event notification subscription @@ -86,6 +114,17 @@ type EventSubscriptionParameters struct { type EventSubscriptionSpec struct { v1.ResourceSpec `json:",inline"` ForProvider EventSubscriptionParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider EventSubscriptionInitParameters `json:"initProvider,omitempty"` } // EventSubscriptionStatus defines the observed state of EventSubscription. @@ -106,8 +145,8 @@ type EventSubscriptionStatus struct { type EventSubscription struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.snsTopicArn)",message="snsTopicArn is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.snsTopicArn) || (has(self.initProvider) && has(self.initProvider.snsTopicArn))",message="spec.forProvider.snsTopicArn is a required parameter" Spec EventSubscriptionSpec `json:"spec"` Status EventSubscriptionStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_generated.deepcopy.go b/apis/docdb/v1alpha1/zz_generated.deepcopy.go index 419d03a..af2ef1f 100644 --- a/apis/docdb/v1alpha1/zz_generated.deepcopy.go +++ b/apis/docdb/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -41,6 +40,155 @@ func (in *Cluster) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInitParameters) DeepCopyInto(out *ClusterInitParameters) { + *out = *in + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } + if in.AvailabilityZones != nil { + in, out := &in.AvailabilityZones, &out.AvailabilityZones + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.BackupRetentionPeriod != nil { + in, out := &in.BackupRetentionPeriod, &out.BackupRetentionPeriod + *out = new(float64) + **out = **in + } + if in.DBClusterParameterGroupName != nil { + in, out := &in.DBClusterParameterGroupName, &out.DBClusterParameterGroupName + *out = new(string) + **out = **in + } + if in.DBSubnetGroupName != nil { + in, out := &in.DBSubnetGroupName, &out.DBSubnetGroupName + *out = new(string) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.EnabledCloudwatchLogsExports != nil { + in, out := &in.EnabledCloudwatchLogsExports, &out.EnabledCloudwatchLogsExports + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.GlobalClusterIdentifier != nil { + in, out := &in.GlobalClusterIdentifier, &out.GlobalClusterIdentifier + *out = new(string) + **out = **in + } + if in.MasterUsername != nil { + in, out := &in.MasterUsername, &out.MasterUsername + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PreferredBackupWindow != nil { + in, out := &in.PreferredBackupWindow, &out.PreferredBackupWindow + *out = new(string) + **out = **in + } + if in.PreferredMaintenanceWindow != nil { + in, out := &in.PreferredMaintenanceWindow, &out.PreferredMaintenanceWindow + *out = new(string) + **out = **in + } + if in.SkipFinalSnapshot != nil { + in, out := &in.SkipFinalSnapshot, &out.SkipFinalSnapshot + *out = new(bool) + **out = **in + } + if in.SnapshotIdentifier != nil { + in, out := &in.SnapshotIdentifier, &out.SnapshotIdentifier + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInitParameters. +func (in *ClusterInitParameters) DeepCopy() *ClusterInitParameters { + if in == nil { + return nil + } + out := new(ClusterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterInstance) DeepCopyInto(out *ClusterInstance) { *out = *in @@ -68,6 +216,103 @@ func (in *ClusterInstance) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInstanceInitParameters) DeepCopyInto(out *ClusterInstanceInitParameters) { + *out = *in + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(bool) + **out = **in + } + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) + **out = **in + } + if in.CACertIdentifier != nil { + in, out := &in.CACertIdentifier, &out.CACertIdentifier + *out = new(string) + **out = **in + } + if in.EnablePerformanceInsights != nil { + in, out := &in.EnablePerformanceInsights, &out.EnablePerformanceInsights + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.InstanceClass != nil { + in, out := &in.InstanceClass, &out.InstanceClass + *out = new(string) + **out = **in + } + if in.PerformanceInsightsKMSKeyID != nil { + in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID + *out = new(string) + **out = **in + } + if in.PreferredMaintenanceWindow != nil { + in, out := &in.PreferredMaintenanceWindow, &out.PreferredMaintenanceWindow + *out = new(string) + **out = **in + } + if in.PromotionTier != nil { + in, out := &in.PromotionTier, &out.PromotionTier + *out = new(float64) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceInitParameters. +func (in *ClusterInstanceInitParameters) DeepCopy() *ClusterInstanceInitParameters { + if in == nil { + return nil + } + out := new(ClusterInstanceInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterInstanceList) DeepCopyInto(out *ClusterInstanceList) { *out = *in @@ -221,7 +466,8 @@ func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -236,7 +482,8 @@ func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -341,7 +588,8 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -356,7 +604,8 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -380,6 +629,7 @@ func (in *ClusterInstanceSpec) DeepCopyInto(out *ClusterInstanceSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceSpec. @@ -600,7 +850,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -615,7 +866,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -672,6 +924,70 @@ func (in *ClusterParameterGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterParameterGroupInitParameters) DeepCopyInto(out *ClusterParameterGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Family != nil { + in, out := &in.Family, &out.Family + *out = new(string) + **out = **in + } + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ParameterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupInitParameters. +func (in *ClusterParameterGroupInitParameters) DeepCopy() *ClusterParameterGroupInitParameters { + if in == nil { + return nil + } + out := new(ClusterParameterGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterParameterGroupList) DeepCopyInto(out *ClusterParameterGroupList) { *out = *in @@ -742,7 +1058,8 @@ func (in *ClusterParameterGroupObservation) DeepCopyInto(out *ClusterParameterGr if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -757,7 +1074,8 @@ func (in *ClusterParameterGroupObservation) DeepCopyInto(out *ClusterParameterGr if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -809,7 +1127,8 @@ func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGro if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -824,7 +1143,8 @@ func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGro if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -848,6 +1168,7 @@ func (in *ClusterParameterGroupSpec) DeepCopyInto(out *ClusterParameterGroupSpec *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupSpec. @@ -1015,7 +1336,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1030,7 +1352,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1099,6 +1422,21 @@ func (in *ClusterSnapshot) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterSnapshotInitParameters) DeepCopyInto(out *ClusterSnapshotInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotInitParameters. +func (in *ClusterSnapshotInitParameters) DeepCopy() *ClusterSnapshotInitParameters { + if in == nil { + return nil + } + out := new(ClusterSnapshotInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterSnapshotList) DeepCopyInto(out *ClusterSnapshotList) { *out = *in @@ -1257,6 +1595,7 @@ func (in *ClusterSnapshotSpec) DeepCopyInto(out *ClusterSnapshotSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + out.InitProvider = in.InitProvider } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotSpec. @@ -1291,6 +1630,7 @@ func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. @@ -1347,6 +1687,90 @@ func (in *EventSubscription) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionInitParameters) DeepCopyInto(out *EventSubscriptionInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.EventCategories != nil { + in, out := &in.EventCategories, &out.EventCategories + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnsTopicArn != nil { + in, out := &in.SnsTopicArn, &out.SnsTopicArn + *out = new(string) + **out = **in + } + if in.SourceIds != nil { + in, out := &in.SourceIds, &out.SourceIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SourceType != nil { + in, out := &in.SourceType, &out.SourceType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionInitParameters. +func (in *EventSubscriptionInitParameters) DeepCopy() *EventSubscriptionInitParameters { + if in == nil { + return nil + } + out := new(EventSubscriptionInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EventSubscriptionList) DeepCopyInto(out *EventSubscriptionList) { *out = *in @@ -1442,7 +1866,8 @@ func (in *EventSubscriptionObservation) DeepCopyInto(out *EventSubscriptionObser if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1457,7 +1882,8 @@ func (in *EventSubscriptionObservation) DeepCopyInto(out *EventSubscriptionObser if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1529,7 +1955,8 @@ func (in *EventSubscriptionParameters) DeepCopyInto(out *EventSubscriptionParame if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1544,7 +1971,8 @@ func (in *EventSubscriptionParameters) DeepCopyInto(out *EventSubscriptionParame if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1568,6 +1996,7 @@ func (in *EventSubscriptionSpec) DeepCopyInto(out *EventSubscriptionSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionSpec. @@ -1624,6 +2053,51 @@ func (in *GlobalCluster) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterInitParameters) DeepCopyInto(out *GlobalClusterInitParameters) { + *out = *in + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName + *out = new(string) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.GlobalClusterIdentifier != nil { + in, out := &in.GlobalClusterIdentifier, &out.GlobalClusterIdentifier + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterInitParameters. +func (in *GlobalClusterInitParameters) DeepCopy() *GlobalClusterInitParameters { + if in == nil { + return nil + } + out := new(GlobalClusterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GlobalClusterList) DeepCopyInto(out *GlobalClusterList) { *out = *in @@ -1656,6 +2130,21 @@ func (in *GlobalClusterList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterMembersInitParameters) DeepCopyInto(out *GlobalClusterMembersInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersInitParameters. +func (in *GlobalClusterMembersInitParameters) DeepCopy() *GlobalClusterMembersInitParameters { + if in == nil { + return nil + } + out := new(GlobalClusterMembersInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GlobalClusterMembersObservation) DeepCopyInto(out *GlobalClusterMembersObservation) { *out = *in @@ -1843,6 +2332,7 @@ func (in *GlobalClusterSpec) DeepCopyInto(out *GlobalClusterSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterSpec. @@ -1872,6 +2362,36 @@ func (in *GlobalClusterStatus) DeepCopy() *GlobalClusterStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterInitParameters) DeepCopyInto(out *ParameterInitParameters) { + *out = *in + if in.ApplyMethod != nil { + in, out := &in.ApplyMethod, &out.ApplyMethod + *out = new(string) + **out = **in + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterInitParameters. +func (in *ParameterInitParameters) DeepCopy() *ParameterInitParameters { + if in == nil { + return nil + } + out := new(ParameterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterObservation) DeepCopyInto(out *ParameterObservation) { *out = *in @@ -1959,6 +2479,58 @@ func (in *SubnetGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SubnetGroupInitParameters) DeepCopyInto(out *SubnetGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupInitParameters. +func (in *SubnetGroupInitParameters) DeepCopy() *SubnetGroupInitParameters { + if in == nil { + return nil + } + out := new(SubnetGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SubnetGroupList) DeepCopyInto(out *SubnetGroupList) { *out = *in @@ -2028,7 +2600,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2043,7 +2616,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2106,7 +2680,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2121,7 +2696,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2145,6 +2721,7 @@ func (in *SubnetGroupSpec) DeepCopyInto(out *SubnetGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupSpec. diff --git a/apis/docdb/v1alpha1/zz_generated.managed.go b/apis/docdb/v1alpha1/zz_generated.managed.go index e67b718..4d85967 100644 --- a/apis/docdb/v1alpha1/zz_generated.managed.go +++ b/apis/docdb/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Cluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Cluster. -func (mg *Cluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Cluster. +func (mg *Cluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Cluster. @@ -27,14 +27,6 @@ func (mg *Cluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Cluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Cluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Cluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Cluster. -func (mg *Cluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Cluster. +func (mg *Cluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Cluster. @@ -65,14 +57,6 @@ func (mg *Cluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Cluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Cluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *ClusterInstance) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterInstance. -func (mg *ClusterInstance) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterInstance. +func (mg *ClusterInstance) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterInstance. @@ -103,14 +87,6 @@ func (mg *ClusterInstance) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterInstance. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterInstance) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterInstance. func (mg *ClusterInstance) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *ClusterInstance) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterInstance. -func (mg *ClusterInstance) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterInstance. +func (mg *ClusterInstance) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterInstance. @@ -141,14 +117,6 @@ func (mg *ClusterInstance) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterInstance. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterInstance) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterInstance. func (mg *ClusterInstance) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *ClusterParameterGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterParameterGroup. -func (mg *ClusterParameterGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterParameterGroup. +func (mg *ClusterParameterGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterParameterGroup. @@ -179,14 +147,6 @@ func (mg *ClusterParameterGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterParameterGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterParameterGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterParameterGroup. func (mg *ClusterParameterGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *ClusterParameterGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterParameterGroup. -func (mg *ClusterParameterGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterParameterGroup. +func (mg *ClusterParameterGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterParameterGroup. @@ -217,14 +177,6 @@ func (mg *ClusterParameterGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterParameterGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterParameterGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterParameterGroup. func (mg *ClusterParameterGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *ClusterSnapshot) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterSnapshot. -func (mg *ClusterSnapshot) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterSnapshot. +func (mg *ClusterSnapshot) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterSnapshot. @@ -255,14 +207,6 @@ func (mg *ClusterSnapshot) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterSnapshot. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterSnapshot) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterSnapshot. func (mg *ClusterSnapshot) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *ClusterSnapshot) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterSnapshot. -func (mg *ClusterSnapshot) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterSnapshot. +func (mg *ClusterSnapshot) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterSnapshot. @@ -293,14 +237,6 @@ func (mg *ClusterSnapshot) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterSnapshot. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterSnapshot) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterSnapshot. func (mg *ClusterSnapshot) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *EventSubscription) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this EventSubscription. -func (mg *EventSubscription) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this EventSubscription. +func (mg *EventSubscription) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this EventSubscription. @@ -331,14 +267,6 @@ func (mg *EventSubscription) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this EventSubscription. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *EventSubscription) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this EventSubscription. func (mg *EventSubscription) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *EventSubscription) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this EventSubscription. -func (mg *EventSubscription) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this EventSubscription. +func (mg *EventSubscription) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this EventSubscription. @@ -369,14 +297,6 @@ func (mg *EventSubscription) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this EventSubscription. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *EventSubscription) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this EventSubscription. func (mg *EventSubscription) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -397,9 +317,9 @@ func (mg *GlobalCluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this GlobalCluster. -func (mg *GlobalCluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this GlobalCluster. +func (mg *GlobalCluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this GlobalCluster. @@ -407,14 +327,6 @@ func (mg *GlobalCluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this GlobalCluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *GlobalCluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this GlobalCluster. func (mg *GlobalCluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -435,9 +347,9 @@ func (mg *GlobalCluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this GlobalCluster. -func (mg *GlobalCluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this GlobalCluster. +func (mg *GlobalCluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this GlobalCluster. @@ -445,14 +357,6 @@ func (mg *GlobalCluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this GlobalCluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *GlobalCluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this GlobalCluster. func (mg *GlobalCluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -473,9 +377,9 @@ func (mg *SubnetGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SubnetGroup. @@ -483,14 +387,6 @@ func (mg *SubnetGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SubnetGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SubnetGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -511,9 +407,9 @@ func (mg *SubnetGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SubnetGroup. @@ -521,14 +417,6 @@ func (mg *SubnetGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SubnetGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SubnetGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/docdb/v1alpha1/zz_generated.resolvers.go b/apis/docdb/v1alpha1/zz_generated.resolvers.go index a1b2f9e..271edbd 100644 --- a/apis/docdb/v1alpha1/zz_generated.resolvers.go +++ b/apis/docdb/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" v1alpha11 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" v1alpha1 "kubedb.dev/provider-aws/apis/kms/v1alpha1" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/docdb/v1alpha1/zz_generated_terraformed.go b/apis/docdb/v1alpha1/zz_generated_terraformed.go index d6318da..5194fe3 100755 --- a/apis/docdb/v1alpha1/zz_generated_terraformed.go +++ b/apis/docdb/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Cluster @@ -69,6 +74,46 @@ func (tr *Cluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Cluster +func (tr *Cluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Cluster +func (tr *Cluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Cluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Cluster) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *ClusterInstance) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterInstance +func (tr *ClusterInstance) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterInstance +func (tr *ClusterInstance) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterInstance using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterInstance) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *ClusterParameterGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterParameterGroup +func (tr *ClusterParameterGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterParameterGroup +func (tr *ClusterParameterGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterParameterGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterParameterGroup) LateInitialize(attrs []byte) (bool, error) { @@ -291,6 +416,46 @@ func (tr *ClusterSnapshot) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterSnapshot +func (tr *ClusterSnapshot) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterSnapshot +func (tr *ClusterSnapshot) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterSnapshot using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterSnapshot) LateInitialize(attrs []byte) (bool, error) { @@ -365,6 +530,46 @@ func (tr *EventSubscription) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this EventSubscription +func (tr *EventSubscription) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this EventSubscription +func (tr *EventSubscription) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this EventSubscription using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *EventSubscription) LateInitialize(attrs []byte) (bool, error) { @@ -439,6 +644,46 @@ func (tr *GlobalCluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this GlobalCluster +func (tr *GlobalCluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this GlobalCluster +func (tr *GlobalCluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this GlobalCluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *GlobalCluster) LateInitialize(attrs []byte) (bool, error) { @@ -513,6 +758,46 @@ func (tr *SubnetGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SubnetGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SubnetGroup) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/docdb/v1alpha1/zz_globalcluster_types.go b/apis/docdb/v1alpha1/zz_globalcluster_types.go index efde16e..b80ee1f 100755 --- a/apis/docdb/v1alpha1/zz_globalcluster_types.go +++ b/apis/docdb/v1alpha1/zz_globalcluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,30 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type GlobalClusterInitParameters struct { + + // Name for an automatically created database on cluster creation. + DatabaseName *string `json:"databaseName,omitempty" tf:"database_name,omitempty"` + + // If the Global Cluster should have deletion protection enabled. The database can't be deleted when this value is set to true. The default is false. + DeletionProtection *bool `json:"deletionProtection,omitempty" tf:"deletion_protection,omitempty"` + + // Name of the database engine to be used for this DB cluster. Current Valid values: docdb. Defaults to docdb. Conflicts with source_db_cluster_identifier. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Engine version of the global database. Upgrading the engine version will result in all cluster members being immediately updated and will. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // The global cluster identifier. + GlobalClusterIdentifier *string `json:"globalClusterIdentifier,omitempty" tf:"global_cluster_identifier,omitempty"` + + // Specifies whether the DB cluster is encrypted. The default is false unless source_db_cluster_identifier is specified and encrypted. + StorageEncrypted *bool `json:"storageEncrypted,omitempty" tf:"storage_encrypted,omitempty"` +} + +type GlobalClusterMembersInitParameters struct { +} + type GlobalClusterMembersObservation struct { // Amazon Resource Name (ARN) of member DB Cluster. @@ -92,7 +120,7 @@ type GlobalClusterParameters struct { // Amazon Resource Name (ARN) to use as the primary DB Cluster of the Global Cluster on creation. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/docdb/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true) // +kubebuilder:validation:Optional SourceDBClusterIdentifier *string `json:"sourceDbClusterIdentifier,omitempty" tf:"source_db_cluster_identifier,omitempty"` @@ -113,6 +141,17 @@ type GlobalClusterParameters struct { type GlobalClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider GlobalClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider GlobalClusterInitParameters `json:"initProvider,omitempty"` } // GlobalClusterStatus defines the observed state of GlobalCluster. @@ -133,8 +172,8 @@ type GlobalClusterStatus struct { type GlobalCluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.globalClusterIdentifier)",message="globalClusterIdentifier is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.globalClusterIdentifier) || (has(self.initProvider) && has(self.initProvider.globalClusterIdentifier))",message="spec.forProvider.globalClusterIdentifier is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec GlobalClusterSpec `json:"spec"` Status GlobalClusterStatus `json:"status,omitempty"` } diff --git a/apis/docdb/v1alpha1/zz_groupversion_info.go b/apis/docdb/v1alpha1/zz_groupversion_info.go index b446986..d64a3ad 100755 --- a/apis/docdb/v1alpha1/zz_groupversion_info.go +++ b/apis/docdb/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/docdb/v1alpha1/zz_subnetgroup_types.go b/apis/docdb/v1alpha1/zz_subnetgroup_types.go index 25fc732..f3619bf 100755 --- a/apis/docdb/v1alpha1/zz_subnetgroup_types.go +++ b/apis/docdb/v1alpha1/zz_subnetgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SubnetGroupInitParameters struct { + + // The description of the docDB subnet group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SubnetGroupObservation struct { // The ARN of the docDB subnet group. @@ -71,6 +87,17 @@ type SubnetGroupParameters struct { type SubnetGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SubnetGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SubnetGroupInitParameters `json:"initProvider,omitempty"` } // SubnetGroupStatus defines the observed state of SubnetGroup. @@ -91,7 +118,7 @@ type SubnetGroupStatus struct { type SubnetGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SubnetGroupSpec `json:"spec"` Status SubnetGroupStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_contributorinsights_types.go b/apis/dynamodb/v1alpha1/zz_contributorinsights_types.go index 33ceaf2..dd031a9 100755 --- a/apis/dynamodb/v1alpha1/zz_contributorinsights_types.go +++ b/apis/dynamodb/v1alpha1/zz_contributorinsights_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ContributorInsightsInitParameters struct { + + // The global secondary index name + IndexName *string `json:"indexName,omitempty" tf:"index_name,omitempty"` +} + type ContributorInsightsObservation struct { ID *string `json:"id,omitempty" tf:"id,omitempty"` @@ -52,6 +62,17 @@ type ContributorInsightsParameters struct { type ContributorInsightsSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ContributorInsightsParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ContributorInsightsInitParameters `json:"initProvider,omitempty"` } // ContributorInsightsStatus defines the observed state of ContributorInsights. @@ -72,7 +93,7 @@ type ContributorInsightsStatus struct { type ContributorInsights struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ContributorInsightsSpec `json:"spec"` Status ContributorInsightsStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_generated.deepcopy.go b/apis/dynamodb/v1alpha1/zz_generated.deepcopy.go index 666a5b1..aa1ae99 100644 --- a/apis/dynamodb/v1alpha1/zz_generated.deepcopy.go +++ b/apis/dynamodb/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,31 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AttributeInitParameters) DeepCopyInto(out *AttributeInitParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AttributeInitParameters. +func (in *AttributeInitParameters) DeepCopy() *AttributeInitParameters { + if in == nil { + return nil + } + out := new(AttributeInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AttributeObservation) DeepCopyInto(out *AttributeObservation) { *out = *in @@ -91,6 +115,26 @@ func (in *ContributorInsights) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ContributorInsightsInitParameters) DeepCopyInto(out *ContributorInsightsInitParameters) { + *out = *in + if in.IndexName != nil { + in, out := &in.IndexName, &out.IndexName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContributorInsightsInitParameters. +func (in *ContributorInsightsInitParameters) DeepCopy() *ContributorInsightsInitParameters { + if in == nil { + return nil + } + out := new(ContributorInsightsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ContributorInsightsList) DeepCopyInto(out *ContributorInsightsList) { *out = *in @@ -198,6 +242,7 @@ func (in *ContributorInsightsSpec) DeepCopyInto(out *ContributorInsightsSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContributorInsightsSpec. @@ -227,6 +272,62 @@ func (in *ContributorInsightsStatus) DeepCopy() *ContributorInsightsStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalSecondaryIndexInitParameters) DeepCopyInto(out *GlobalSecondaryIndexInitParameters) { + *out = *in + if in.HashKey != nil { + in, out := &in.HashKey, &out.HashKey + *out = new(string) + **out = **in + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.NonKeyAttributes != nil { + in, out := &in.NonKeyAttributes, &out.NonKeyAttributes + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ProjectionType != nil { + in, out := &in.ProjectionType, &out.ProjectionType + *out = new(string) + **out = **in + } + if in.RangeKey != nil { + in, out := &in.RangeKey, &out.RangeKey + *out = new(string) + **out = **in + } + if in.ReadCapacity != nil { + in, out := &in.ReadCapacity, &out.ReadCapacity + *out = new(float64) + **out = **in + } + if in.WriteCapacity != nil { + in, out := &in.WriteCapacity, &out.WriteCapacity + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalSecondaryIndexInitParameters. +func (in *GlobalSecondaryIndexInitParameters) DeepCopy() *GlobalSecondaryIndexInitParameters { + if in == nil { + return nil + } + out := new(GlobalSecondaryIndexInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GlobalSecondaryIndexObservation) DeepCopyInto(out *GlobalSecondaryIndexObservation) { *out = *in @@ -366,6 +467,28 @@ func (in *GlobalTable) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalTableInitParameters) DeepCopyInto(out *GlobalTableInitParameters) { + *out = *in + if in.Replica != nil { + in, out := &in.Replica, &out.Replica + *out = make([]ReplicaInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalTableInitParameters. +func (in *GlobalTableInitParameters) DeepCopy() *GlobalTableInitParameters { + if in == nil { + return nil + } + out := new(GlobalTableInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GlobalTableList) DeepCopyInto(out *GlobalTableList) { *out = *in @@ -462,6 +585,7 @@ func (in *GlobalTableSpec) DeepCopyInto(out *GlobalTableSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalTableSpec. @@ -518,6 +642,21 @@ func (in *KinesisStreamingDestination) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *KinesisStreamingDestinationInitParameters) DeepCopyInto(out *KinesisStreamingDestinationInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KinesisStreamingDestinationInitParameters. +func (in *KinesisStreamingDestinationInitParameters) DeepCopy() *KinesisStreamingDestinationInitParameters { + if in == nil { + return nil + } + out := new(KinesisStreamingDestinationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *KinesisStreamingDestinationList) DeepCopyInto(out *KinesisStreamingDestinationList) { *out = *in @@ -635,6 +774,7 @@ func (in *KinesisStreamingDestinationSpec) DeepCopyInto(out *KinesisStreamingDes *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + out.InitProvider = in.InitProvider } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KinesisStreamingDestinationSpec. @@ -664,6 +804,47 @@ func (in *KinesisStreamingDestinationStatus) DeepCopy() *KinesisStreamingDestina return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *LocalSecondaryIndexInitParameters) DeepCopyInto(out *LocalSecondaryIndexInitParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.NonKeyAttributes != nil { + in, out := &in.NonKeyAttributes, &out.NonKeyAttributes + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ProjectionType != nil { + in, out := &in.ProjectionType, &out.ProjectionType + *out = new(string) + **out = **in + } + if in.RangeKey != nil { + in, out := &in.RangeKey, &out.RangeKey + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalSecondaryIndexInitParameters. +func (in *LocalSecondaryIndexInitParameters) DeepCopy() *LocalSecondaryIndexInitParameters { + if in == nil { + return nil + } + out := new(LocalSecondaryIndexInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LocalSecondaryIndexObservation) DeepCopyInto(out *LocalSecondaryIndexObservation) { *out = *in @@ -746,6 +927,26 @@ func (in *LocalSecondaryIndexParameters) DeepCopy() *LocalSecondaryIndexParamete return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *PointInTimeRecoveryInitParameters) DeepCopyInto(out *PointInTimeRecoveryInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PointInTimeRecoveryInitParameters. +func (in *PointInTimeRecoveryInitParameters) DeepCopy() *PointInTimeRecoveryInitParameters { + if in == nil { + return nil + } + out := new(PointInTimeRecoveryInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *PointInTimeRecoveryObservation) DeepCopyInto(out *PointInTimeRecoveryObservation) { *out = *in @@ -786,6 +987,26 @@ func (in *PointInTimeRecoveryParameters) DeepCopy() *PointInTimeRecoveryParamete return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ReplicaInitParameters) DeepCopyInto(out *ReplicaInitParameters) { + *out = *in + if in.RegionName != nil { + in, out := &in.RegionName, &out.RegionName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaInitParameters. +func (in *ReplicaInitParameters) DeepCopy() *ReplicaInitParameters { + if in == nil { + return nil + } + out := new(ReplicaInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ReplicaObservation) DeepCopyInto(out *ReplicaObservation) { *out = *in @@ -826,6 +1047,31 @@ func (in *ReplicaParameters) DeepCopy() *ReplicaParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ServerSideEncryptionInitParameters) DeepCopyInto(out *ServerSideEncryptionInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.KMSKeyArn != nil { + in, out := &in.KMSKeyArn, &out.KMSKeyArn + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServerSideEncryptionInitParameters. +func (in *ServerSideEncryptionInitParameters) DeepCopy() *ServerSideEncryptionInitParameters { + if in == nil { + return nil + } + out := new(ServerSideEncryptionInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ServerSideEncryptionObservation) DeepCopyInto(out *ServerSideEncryptionObservation) { *out = *in @@ -876,6 +1122,31 @@ func (in *ServerSideEncryptionParameters) DeepCopy() *ServerSideEncryptionParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TTLInitParameters) DeepCopyInto(out *TTLInitParameters) { + *out = *in + if in.AttributeName != nil { + in, out := &in.AttributeName, &out.AttributeName + *out = new(string) + **out = **in + } + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TTLInitParameters. +func (in *TTLInitParameters) DeepCopy() *TTLInitParameters { + if in == nil { + return nil + } + out := new(TTLInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TTLObservation) DeepCopyInto(out *TTLObservation) { *out = *in @@ -953,6 +1224,162 @@ func (in *Table) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TableInitParameters) DeepCopyInto(out *TableInitParameters) { + *out = *in + if in.Attribute != nil { + in, out := &in.Attribute, &out.Attribute + *out = make([]AttributeInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.BillingMode != nil { + in, out := &in.BillingMode, &out.BillingMode + *out = new(string) + **out = **in + } + if in.DeletionProtectionEnabled != nil { + in, out := &in.DeletionProtectionEnabled, &out.DeletionProtectionEnabled + *out = new(bool) + **out = **in + } + if in.GlobalSecondaryIndex != nil { + in, out := &in.GlobalSecondaryIndex, &out.GlobalSecondaryIndex + *out = make([]GlobalSecondaryIndexInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.HashKey != nil { + in, out := &in.HashKey, &out.HashKey + *out = new(string) + **out = **in + } + if in.LocalSecondaryIndex != nil { + in, out := &in.LocalSecondaryIndex, &out.LocalSecondaryIndex + *out = make([]LocalSecondaryIndexInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.PointInTimeRecovery != nil { + in, out := &in.PointInTimeRecovery, &out.PointInTimeRecovery + *out = make([]PointInTimeRecoveryInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.RangeKey != nil { + in, out := &in.RangeKey, &out.RangeKey + *out = new(string) + **out = **in + } + if in.ReadCapacity != nil { + in, out := &in.ReadCapacity, &out.ReadCapacity + *out = new(float64) + **out = **in + } + if in.Replica != nil { + in, out := &in.Replica, &out.Replica + *out = make([]TableReplicaInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.RestoreDateTime != nil { + in, out := &in.RestoreDateTime, &out.RestoreDateTime + *out = new(string) + **out = **in + } + if in.RestoreSourceName != nil { + in, out := &in.RestoreSourceName, &out.RestoreSourceName + *out = new(string) + **out = **in + } + if in.RestoreToLatestTime != nil { + in, out := &in.RestoreToLatestTime, &out.RestoreToLatestTime + *out = new(bool) + **out = **in + } + if in.ServerSideEncryption != nil { + in, out := &in.ServerSideEncryption, &out.ServerSideEncryption + *out = make([]ServerSideEncryptionInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.StreamEnabled != nil { + in, out := &in.StreamEnabled, &out.StreamEnabled + *out = new(bool) + **out = **in + } + if in.StreamViewType != nil { + in, out := &in.StreamViewType, &out.StreamViewType + *out = new(string) + **out = **in + } + if in.TTL != nil { + in, out := &in.TTL, &out.TTL + *out = make([]TTLInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.TableClass != nil { + in, out := &in.TableClass, &out.TableClass + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.WriteCapacity != nil { + in, out := &in.WriteCapacity, &out.WriteCapacity + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableInitParameters. +func (in *TableInitParameters) DeepCopy() *TableInitParameters { + if in == nil { + return nil + } + out := new(TableInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TableItem) DeepCopyInto(out *TableItem) { *out = *in @@ -980,6 +1407,36 @@ func (in *TableItem) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TableItemInitParameters) DeepCopyInto(out *TableItemInitParameters) { + *out = *in + if in.HashKey != nil { + in, out := &in.HashKey, &out.HashKey + *out = new(string) + **out = **in + } + if in.Item != nil { + in, out := &in.Item, &out.Item + *out = new(string) + **out = **in + } + if in.RangeKey != nil { + in, out := &in.RangeKey, &out.RangeKey + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableItemInitParameters. +func (in *TableItemInitParameters) DeepCopy() *TableItemInitParameters { + if in == nil { + return nil + } + out := new(TableItemInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TableItemList) DeepCopyInto(out *TableItemList) { *out = *in @@ -1107,6 +1564,7 @@ func (in *TableItemSpec) DeepCopyInto(out *TableItemSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableItemSpec. @@ -1303,7 +1761,8 @@ func (in *TableObservation) DeepCopyInto(out *TableObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1318,7 +1777,8 @@ func (in *TableObservation) DeepCopyInto(out *TableObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1462,7 +1922,8 @@ func (in *TableParameters) DeepCopyInto(out *TableParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1477,7 +1938,8 @@ func (in *TableParameters) DeepCopyInto(out *TableParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1528,6 +1990,98 @@ func (in *TableReplica) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TableReplicaInitParameters) DeepCopyInto(out *TableReplicaInitParameters) { + *out = *in + if in.KMSKeyArn != nil { + in, out := &in.KMSKeyArn, &out.KMSKeyArn + *out = new(string) + **out = **in + } + if in.PointInTimeRecovery != nil { + in, out := &in.PointInTimeRecovery, &out.PointInTimeRecovery + *out = new(bool) + **out = **in + } + if in.PropagateTags != nil { + in, out := &in.PropagateTags, &out.PropagateTags + *out = new(bool) + **out = **in + } + if in.RegionName != nil { + in, out := &in.RegionName, &out.RegionName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableReplicaInitParameters. +func (in *TableReplicaInitParameters) DeepCopy() *TableReplicaInitParameters { + if in == nil { + return nil + } + out := new(TableReplicaInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TableReplicaInitParameters_2) DeepCopyInto(out *TableReplicaInitParameters_2) { + *out = *in + if in.PointInTimeRecovery != nil { + in, out := &in.PointInTimeRecovery, &out.PointInTimeRecovery + *out = new(bool) + **out = **in + } + if in.TableClassOverride != nil { + in, out := &in.TableClassOverride, &out.TableClassOverride + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableReplicaInitParameters_2. +func (in *TableReplicaInitParameters_2) DeepCopy() *TableReplicaInitParameters_2 { + if in == nil { + return nil + } + out := new(TableReplicaInitParameters_2) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TableReplicaList) DeepCopyInto(out *TableReplicaList) { *out = *in @@ -1651,7 +2205,8 @@ func (in *TableReplicaObservation_2) DeepCopyInto(out *TableReplicaObservation_2 if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1666,7 +2221,8 @@ func (in *TableReplicaObservation_2) DeepCopyInto(out *TableReplicaObservation_2 if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1776,7 +2332,8 @@ func (in *TableReplicaParameters_2) DeepCopyInto(out *TableReplicaParameters_2) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1791,7 +2348,8 @@ func (in *TableReplicaParameters_2) DeepCopyInto(out *TableReplicaParameters_2) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1815,6 +2373,7 @@ func (in *TableReplicaSpec) DeepCopyInto(out *TableReplicaSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableReplicaSpec. @@ -1849,6 +2408,7 @@ func (in *TableSpec) DeepCopyInto(out *TableSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TableSpec. @@ -1905,6 +2465,26 @@ func (in *Tag) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TagInitParameters) DeepCopyInto(out *TagInitParameters) { + *out = *in + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TagInitParameters. +func (in *TagInitParameters) DeepCopy() *TagInitParameters { + if in == nil { + return nil + } + out := new(TagInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TagList) DeepCopyInto(out *TagList) { *out = *in @@ -2012,6 +2592,7 @@ func (in *TagSpec) DeepCopyInto(out *TagSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TagSpec. diff --git a/apis/dynamodb/v1alpha1/zz_generated.managed.go b/apis/dynamodb/v1alpha1/zz_generated.managed.go index 3886437..8fca001 100644 --- a/apis/dynamodb/v1alpha1/zz_generated.managed.go +++ b/apis/dynamodb/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *ContributorInsights) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ContributorInsights. -func (mg *ContributorInsights) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ContributorInsights. +func (mg *ContributorInsights) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ContributorInsights. @@ -27,14 +27,6 @@ func (mg *ContributorInsights) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ContributorInsights. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ContributorInsights) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ContributorInsights. func (mg *ContributorInsights) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *ContributorInsights) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ContributorInsights. -func (mg *ContributorInsights) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ContributorInsights. +func (mg *ContributorInsights) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ContributorInsights. @@ -65,14 +57,6 @@ func (mg *ContributorInsights) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ContributorInsights. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ContributorInsights) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ContributorInsights. func (mg *ContributorInsights) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *GlobalTable) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this GlobalTable. -func (mg *GlobalTable) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this GlobalTable. +func (mg *GlobalTable) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this GlobalTable. @@ -103,14 +87,6 @@ func (mg *GlobalTable) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this GlobalTable. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *GlobalTable) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this GlobalTable. func (mg *GlobalTable) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *GlobalTable) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this GlobalTable. -func (mg *GlobalTable) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this GlobalTable. +func (mg *GlobalTable) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this GlobalTable. @@ -141,14 +117,6 @@ func (mg *GlobalTable) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this GlobalTable. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *GlobalTable) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this GlobalTable. func (mg *GlobalTable) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *KinesisStreamingDestination) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this KinesisStreamingDestination. -func (mg *KinesisStreamingDestination) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this KinesisStreamingDestination. +func (mg *KinesisStreamingDestination) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this KinesisStreamingDestination. @@ -179,14 +147,6 @@ func (mg *KinesisStreamingDestination) GetProviderConfigReference() *xpv1.Refere return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this KinesisStreamingDestination. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *KinesisStreamingDestination) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this KinesisStreamingDestination. func (mg *KinesisStreamingDestination) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *KinesisStreamingDestination) SetDeletionPolicy(r xpv1.DeletionPolicy) mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this KinesisStreamingDestination. -func (mg *KinesisStreamingDestination) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this KinesisStreamingDestination. +func (mg *KinesisStreamingDestination) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this KinesisStreamingDestination. @@ -217,14 +177,6 @@ func (mg *KinesisStreamingDestination) SetProviderConfigReference(r *xpv1.Refere mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this KinesisStreamingDestination. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *KinesisStreamingDestination) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this KinesisStreamingDestination. func (mg *KinesisStreamingDestination) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *Table) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Table. -func (mg *Table) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Table. +func (mg *Table) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Table. @@ -255,14 +207,6 @@ func (mg *Table) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Table. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Table) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Table. func (mg *Table) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *Table) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Table. -func (mg *Table) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Table. +func (mg *Table) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Table. @@ -293,14 +237,6 @@ func (mg *Table) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Table. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Table) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Table. func (mg *Table) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *TableItem) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this TableItem. -func (mg *TableItem) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this TableItem. +func (mg *TableItem) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this TableItem. @@ -331,14 +267,6 @@ func (mg *TableItem) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this TableItem. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *TableItem) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this TableItem. func (mg *TableItem) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *TableItem) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this TableItem. -func (mg *TableItem) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this TableItem. +func (mg *TableItem) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this TableItem. @@ -369,14 +297,6 @@ func (mg *TableItem) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this TableItem. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *TableItem) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this TableItem. func (mg *TableItem) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -397,9 +317,9 @@ func (mg *TableReplica) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this TableReplica. -func (mg *TableReplica) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this TableReplica. +func (mg *TableReplica) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this TableReplica. @@ -407,14 +327,6 @@ func (mg *TableReplica) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this TableReplica. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *TableReplica) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this TableReplica. func (mg *TableReplica) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -435,9 +347,9 @@ func (mg *TableReplica) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this TableReplica. -func (mg *TableReplica) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this TableReplica. +func (mg *TableReplica) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this TableReplica. @@ -445,14 +357,6 @@ func (mg *TableReplica) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this TableReplica. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *TableReplica) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this TableReplica. func (mg *TableReplica) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -473,9 +377,9 @@ func (mg *Tag) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Tag. -func (mg *Tag) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Tag. +func (mg *Tag) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Tag. @@ -483,14 +387,6 @@ func (mg *Tag) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Tag. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Tag) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Tag. func (mg *Tag) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -511,9 +407,9 @@ func (mg *Tag) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Tag. -func (mg *Tag) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Tag. +func (mg *Tag) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Tag. @@ -521,14 +417,6 @@ func (mg *Tag) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Tag. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Tag) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Tag. func (mg *Tag) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/dynamodb/v1alpha1/zz_generated.resolvers.go b/apis/dynamodb/v1alpha1/zz_generated.resolvers.go index e241fce..62ce945 100644 --- a/apis/dynamodb/v1alpha1/zz_generated.resolvers.go +++ b/apis/dynamodb/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" v1alpha1 "kubedb.dev/provider-aws/apis/kinesis/v1alpha1" v1alpha11 "kubedb.dev/provider-aws/apis/kms/v1alpha1" common "kubedb.dev/provider-aws/config/common" diff --git a/apis/dynamodb/v1alpha1/zz_generated_terraformed.go b/apis/dynamodb/v1alpha1/zz_generated_terraformed.go index d4a8527..eac95e4 100755 --- a/apis/dynamodb/v1alpha1/zz_generated_terraformed.go +++ b/apis/dynamodb/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this ContributorInsights @@ -69,6 +74,46 @@ func (tr *ContributorInsights) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ContributorInsights +func (tr *ContributorInsights) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ContributorInsights +func (tr *ContributorInsights) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ContributorInsights using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ContributorInsights) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *GlobalTable) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this GlobalTable +func (tr *GlobalTable) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this GlobalTable +func (tr *GlobalTable) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this GlobalTable using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *GlobalTable) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *KinesisStreamingDestination) SetParameters(params map[string]any) erro return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this KinesisStreamingDestination +func (tr *KinesisStreamingDestination) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this KinesisStreamingDestination +func (tr *KinesisStreamingDestination) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this KinesisStreamingDestination using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *KinesisStreamingDestination) LateInitialize(attrs []byte) (bool, error) { @@ -291,6 +416,46 @@ func (tr *Table) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Table +func (tr *Table) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Table +func (tr *Table) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Table using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Table) LateInitialize(attrs []byte) (bool, error) { @@ -365,6 +530,46 @@ func (tr *TableItem) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this TableItem +func (tr *TableItem) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this TableItem +func (tr *TableItem) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this TableItem using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *TableItem) LateInitialize(attrs []byte) (bool, error) { @@ -439,6 +644,46 @@ func (tr *TableReplica) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this TableReplica +func (tr *TableReplica) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this TableReplica +func (tr *TableReplica) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this TableReplica using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *TableReplica) LateInitialize(attrs []byte) (bool, error) { @@ -513,6 +758,46 @@ func (tr *Tag) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Tag +func (tr *Tag) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Tag +func (tr *Tag) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Tag using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Tag) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/dynamodb/v1alpha1/zz_globaltable_types.go b/apis/dynamodb/v1alpha1/zz_globaltable_types.go index 0c90cbe..e89d191 100755 --- a/apis/dynamodb/v1alpha1/zz_globaltable_types.go +++ b/apis/dynamodb/v1alpha1/zz_globaltable_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type GlobalTableInitParameters struct { + + // Underlying DynamoDB Table. At least 1 replica must be defined. See below. + Replica []ReplicaInitParameters `json:"replica,omitempty" tf:"replica,omitempty"` +} + type GlobalTableObservation struct { // The ARN of the DynamoDB Global Table @@ -37,6 +47,12 @@ type GlobalTableParameters struct { Replica []ReplicaParameters `json:"replica,omitempty" tf:"replica,omitempty"` } +type ReplicaInitParameters struct { + + // AWS region name of replica DynamoDB TableE.g., us-east-1 + RegionName *string `json:"regionName,omitempty" tf:"region_name,omitempty"` +} + type ReplicaObservation struct { // AWS region name of replica DynamoDB TableE.g., us-east-1 @@ -46,7 +62,7 @@ type ReplicaObservation struct { type ReplicaParameters struct { // AWS region name of replica DynamoDB TableE.g., us-east-1 - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional RegionName *string `json:"regionName" tf:"region_name,omitempty"` } @@ -54,6 +70,17 @@ type ReplicaParameters struct { type GlobalTableSpec struct { v1.ResourceSpec `json:",inline"` ForProvider GlobalTableParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider GlobalTableInitParameters `json:"initProvider,omitempty"` } // GlobalTableStatus defines the observed state of GlobalTable. @@ -74,8 +101,8 @@ type GlobalTableStatus struct { type GlobalTable struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.replica)",message="replica is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.replica) || (has(self.initProvider) && has(self.initProvider.replica))",message="spec.forProvider.replica is a required parameter" Spec GlobalTableSpec `json:"spec"` Status GlobalTableStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_groupversion_info.go b/apis/dynamodb/v1alpha1/zz_groupversion_info.go index 5c64650..0929789 100755 --- a/apis/dynamodb/v1alpha1/zz_groupversion_info.go +++ b/apis/dynamodb/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/dynamodb/v1alpha1/zz_kinesisstreamingdestination_types.go b/apis/dynamodb/v1alpha1/zz_kinesisstreamingdestination_types.go index 5035dcc..6bd38da 100755 --- a/apis/dynamodb/v1alpha1/zz_kinesisstreamingdestination_types.go +++ b/apis/dynamodb/v1alpha1/zz_kinesisstreamingdestination_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type KinesisStreamingDestinationInitParameters struct { +} + type KinesisStreamingDestinationObservation struct { // The table_name and stream_arn separated by a comma (,). @@ -66,6 +73,17 @@ type KinesisStreamingDestinationParameters struct { type KinesisStreamingDestinationSpec struct { v1.ResourceSpec `json:",inline"` ForProvider KinesisStreamingDestinationParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider KinesisStreamingDestinationInitParameters `json:"initProvider,omitempty"` } // KinesisStreamingDestinationStatus defines the observed state of KinesisStreamingDestination. @@ -86,7 +104,7 @@ type KinesisStreamingDestinationStatus struct { type KinesisStreamingDestination struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec KinesisStreamingDestinationSpec `json:"spec"` Status KinesisStreamingDestinationStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_table_types.go b/apis/dynamodb/v1alpha1/zz_table_types.go index 9fe58f1..a9fc92d 100755 --- a/apis/dynamodb/v1alpha1/zz_table_types.go +++ b/apis/dynamodb/v1alpha1/zz_table_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type AttributeInitParameters struct { + + // Name of the attribute + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // Attribute type. Valid values are S (string), N (number), B (binary). + Type *string `json:"type,omitempty" tf:"type,omitempty"` +} + type AttributeObservation struct { // Name of the attribute @@ -25,14 +38,38 @@ type AttributeObservation struct { type AttributeParameters struct { // Name of the attribute - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // Attribute type. Valid values are S (string), N (number), B (binary). - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Type *string `json:"type" tf:"type,omitempty"` } +type GlobalSecondaryIndexInitParameters struct { + + // Name of the hash key in the index; must be defined as an attribute in the resource. + HashKey *string `json:"hashKey,omitempty" tf:"hash_key,omitempty"` + + // Name of the index. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // Only required with INCLUDE as a projection type; a list of attributes to project into the index. These do not need to be defined as attributes on the table. + NonKeyAttributes []*string `json:"nonKeyAttributes,omitempty" tf:"non_key_attributes,omitempty"` + + // One of ALL, INCLUDE or KEYS_ONLY where ALL projects every attribute into the index, KEYS_ONLY projects into the index only the table and index hash_key and sort_key attributes , INCLUDE projects into the index all of the attributes that are defined in non_key_attributes in addition to the attributes that thatKEYS_ONLY project. + ProjectionType *string `json:"projectionType,omitempty" tf:"projection_type,omitempty"` + + // Name of the range key; must be defined + RangeKey *string `json:"rangeKey,omitempty" tf:"range_key,omitempty"` + + // Number of read units for this index. Must be set if billing_mode is set to PROVISIONED. + ReadCapacity *float64 `json:"readCapacity,omitempty" tf:"read_capacity,omitempty"` + + // Number of write units for this index. Must be set if billing_mode is set to PROVISIONED. + WriteCapacity *float64 `json:"writeCapacity,omitempty" tf:"write_capacity,omitempty"` +} + type GlobalSecondaryIndexObservation struct { // Name of the hash key in the index; must be defined as an attribute in the resource. @@ -60,11 +97,11 @@ type GlobalSecondaryIndexObservation struct { type GlobalSecondaryIndexParameters struct { // Name of the hash key in the index; must be defined as an attribute in the resource. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional HashKey *string `json:"hashKey" tf:"hash_key,omitempty"` // Name of the index. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // Only required with INCLUDE as a projection type; a list of attributes to project into the index. These do not need to be defined as attributes on the table. @@ -72,7 +109,7 @@ type GlobalSecondaryIndexParameters struct { NonKeyAttributes []*string `json:"nonKeyAttributes,omitempty" tf:"non_key_attributes,omitempty"` // One of ALL, INCLUDE or KEYS_ONLY where ALL projects every attribute into the index, KEYS_ONLY projects into the index only the table and index hash_key and sort_key attributes , INCLUDE projects into the index all of the attributes that are defined in non_key_attributes in addition to the attributes that thatKEYS_ONLY project. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional ProjectionType *string `json:"projectionType" tf:"projection_type,omitempty"` // Name of the range key; must be defined @@ -88,6 +125,21 @@ type GlobalSecondaryIndexParameters struct { WriteCapacity *float64 `json:"writeCapacity,omitempty" tf:"write_capacity,omitempty"` } +type LocalSecondaryIndexInitParameters struct { + + // Name of the index + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // Only required with INCLUDE as a projection type; a list of attributes to project into the index. These do not need to be defined as attributes on the table. + NonKeyAttributes []*string `json:"nonKeyAttributes,omitempty" tf:"non_key_attributes,omitempty"` + + // One of ALL, INCLUDE or KEYS_ONLY where ALL projects every attribute into the index, KEYS_ONLY projects into the index only the table and index hash_key and sort_key attributes , INCLUDE projects into the index all of the attributes that are defined in non_key_attributes in addition to the attributes that thatKEYS_ONLY project. + ProjectionType *string `json:"projectionType,omitempty" tf:"projection_type,omitempty"` + + // Name of the range key. + RangeKey *string `json:"rangeKey,omitempty" tf:"range_key,omitempty"` +} + type LocalSecondaryIndexObservation struct { // Name of the index @@ -106,7 +158,7 @@ type LocalSecondaryIndexObservation struct { type LocalSecondaryIndexParameters struct { // Name of the index - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // Only required with INCLUDE as a projection type; a list of attributes to project into the index. These do not need to be defined as attributes on the table. @@ -114,14 +166,20 @@ type LocalSecondaryIndexParameters struct { NonKeyAttributes []*string `json:"nonKeyAttributes,omitempty" tf:"non_key_attributes,omitempty"` // One of ALL, INCLUDE or KEYS_ONLY where ALL projects every attribute into the index, KEYS_ONLY projects into the index only the table and index hash_key and sort_key attributes , INCLUDE projects into the index all of the attributes that are defined in non_key_attributes in addition to the attributes that thatKEYS_ONLY project. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional ProjectionType *string `json:"projectionType" tf:"projection_type,omitempty"` // Name of the range key. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional RangeKey *string `json:"rangeKey" tf:"range_key,omitempty"` } +type PointInTimeRecoveryInitParameters struct { + + // Whether to enable point-in-time recovery. It can take 10 minutes to enable for new tables. If the point_in_time_recovery block is not provided, this defaults to false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type PointInTimeRecoveryObservation struct { // Whether to enable point-in-time recovery. It can take 10 minutes to enable for new tables. If the point_in_time_recovery block is not provided, this defaults to false. @@ -131,10 +189,19 @@ type PointInTimeRecoveryObservation struct { type PointInTimeRecoveryParameters struct { // Whether to enable point-in-time recovery. It can take 10 minutes to enable for new tables. If the point_in_time_recovery block is not provided, this defaults to false. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` } +type ServerSideEncryptionInitParameters struct { + + // Whether or not to enable encryption at rest using an AWS managed KMS customer master key (CMK). If enabled is false then server-side encryption is set to AWS-owned key (shown as DEFAULT in the AWS console). Potentially confusingly, if enabled is true and no kms_key_arn is specified then server-side encryption is set to the default KMS-managed key (shown as KMS in the AWS console). The AWS KMS documentation explains the difference between AWS-owned and KMS-managed keys. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // ARN of the CMK that should be used for the AWS KMS encryption. This argument should only be used if the key is different from the default KMS-managed DynamoDB key, alias/aws/dynamodb. Note: This attribute will not be populated with the ARN of default keys. + KMSKeyArn *string `json:"kmsKeyArn,omitempty" tf:"kms_key_arn,omitempty"` +} + type ServerSideEncryptionObservation struct { // Whether or not to enable encryption at rest using an AWS managed KMS customer master key (CMK). If enabled is false then server-side encryption is set to AWS-owned key (shown as DEFAULT in the AWS console). Potentially confusingly, if enabled is true and no kms_key_arn is specified then server-side encryption is set to the default KMS-managed key (shown as KMS in the AWS console). The AWS KMS documentation explains the difference between AWS-owned and KMS-managed keys. @@ -147,7 +214,7 @@ type ServerSideEncryptionObservation struct { type ServerSideEncryptionParameters struct { // Whether or not to enable encryption at rest using an AWS managed KMS customer master key (CMK). If enabled is false then server-side encryption is set to AWS-owned key (shown as DEFAULT in the AWS console). Potentially confusingly, if enabled is true and no kms_key_arn is specified then server-side encryption is set to the default KMS-managed key (shown as KMS in the AWS console). The AWS KMS documentation explains the difference between AWS-owned and KMS-managed keys. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` // ARN of the CMK that should be used for the AWS KMS encryption. This argument should only be used if the key is different from the default KMS-managed DynamoDB key, alias/aws/dynamodb. Note: This attribute will not be populated with the ARN of default keys. @@ -155,6 +222,15 @@ type ServerSideEncryptionParameters struct { KMSKeyArn *string `json:"kmsKeyArn,omitempty" tf:"kms_key_arn,omitempty"` } +type TTLInitParameters struct { + + // Name of the table attribute to store the TTL timestamp in. + AttributeName *string `json:"attributeName,omitempty" tf:"attribute_name,omitempty"` + + // Whether TTL is enabled. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type TTLObservation struct { // Name of the table attribute to store the TTL timestamp in. @@ -167,7 +243,7 @@ type TTLObservation struct { type TTLParameters struct { // Name of the table attribute to store the TTL timestamp in. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional AttributeName *string `json:"attributeName" tf:"attribute_name,omitempty"` // Whether TTL is enabled. @@ -175,6 +251,74 @@ type TTLParameters struct { Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` } +type TableInitParameters struct { + + // Set of nested attribute definitions. Only required for hash_key and range_key attributes. See below. + Attribute []AttributeInitParameters `json:"attribute,omitempty" tf:"attribute,omitempty"` + + // Controls how you are charged for read and write throughput and how you manage capacity. The valid values are PROVISIONED and PAY_PER_REQUEST. Defaults to PROVISIONED. + BillingMode *string `json:"billingMode,omitempty" tf:"billing_mode,omitempty"` + + // Enables deletion protection for table. Defaults to false. + DeletionProtectionEnabled *bool `json:"deletionProtectionEnabled,omitempty" tf:"deletion_protection_enabled,omitempty"` + + // Describe a GSI for the table; subject to the normal limits on the number of GSIs, projected attributes, etc. See below. + GlobalSecondaryIndex []GlobalSecondaryIndexInitParameters `json:"globalSecondaryIndex,omitempty" tf:"global_secondary_index,omitempty"` + + // Attribute to use as the hash (partition) key. Must also be defined as an attribute. See below. + HashKey *string `json:"hashKey,omitempty" tf:"hash_key,omitempty"` + + // Describe an LSI on the table; these can only be allocated at creation so you cannot change this definition after you have created the resource. See below. + LocalSecondaryIndex []LocalSecondaryIndexInitParameters `json:"localSecondaryIndex,omitempty" tf:"local_secondary_index,omitempty"` + + // Enable point-in-time recovery options. See below. + PointInTimeRecovery []PointInTimeRecoveryInitParameters `json:"pointInTimeRecovery,omitempty" tf:"point_in_time_recovery,omitempty"` + + // Attribute to use as the range (sort) key. Must also be defined as an attribute, see below. + RangeKey *string `json:"rangeKey,omitempty" tf:"range_key,omitempty"` + + // Number of read units for this table. If the billing_mode is PROVISIONED, this field is required. + ReadCapacity *float64 `json:"readCapacity,omitempty" tf:"read_capacity,omitempty"` + + // Configuration block(s) with DynamoDB Global Tables V2 (version 2019.11.21) replication configurations. See below. + Replica []TableReplicaInitParameters `json:"replica,omitempty" tf:"replica,omitempty"` + + // Time of the point-in-time recovery point to restore. + RestoreDateTime *string `json:"restoreDateTime,omitempty" tf:"restore_date_time,omitempty"` + + // Name of the table to restore. Must match the name of an existing table. + RestoreSourceName *string `json:"restoreSourceName,omitempty" tf:"restore_source_name,omitempty"` + + // If set, restores table to the most recent point-in-time recovery point. + RestoreToLatestTime *bool `json:"restoreToLatestTime,omitempty" tf:"restore_to_latest_time,omitempty"` + + // Encryption at rest options. AWS DynamoDB tables are automatically encrypted at rest with an AWS-owned Customer Master Key if this argument isn't specified. See below. + ServerSideEncryption []ServerSideEncryptionInitParameters `json:"serverSideEncryption,omitempty" tf:"server_side_encryption,omitempty"` + + // Whether Streams are enabled. + StreamEnabled *bool `json:"streamEnabled,omitempty" tf:"stream_enabled,omitempty"` + + // When an item in the table is modified, StreamViewType determines what information is written to the table's stream. Valid values are KEYS_ONLY, NEW_IMAGE, OLD_IMAGE, NEW_AND_OLD_IMAGES. + StreamViewType *string `json:"streamViewType,omitempty" tf:"stream_view_type,omitempty"` + + // Configuration block for TTL. See below. + TTL []TTLInitParameters `json:"ttl,omitempty" tf:"ttl,omitempty"` + + // Storage class of the table. + // Valid values are STANDARD and STANDARD_INFREQUENT_ACCESS. + // Default value is STANDARD. + TableClass *string `json:"tableClass,omitempty" tf:"table_class,omitempty"` + + // A map of tags to populate on the created table. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Number of write units for this table. If the billing_mode is PROVISIONED, this field is required. + WriteCapacity *float64 `json:"writeCapacity,omitempty" tf:"write_capacity,omitempty"` +} + type TableObservation struct { // ARN of the table @@ -349,6 +493,21 @@ type TableParameters struct { WriteCapacity *float64 `json:"writeCapacity,omitempty" tf:"write_capacity,omitempty"` } +type TableReplicaInitParameters struct { + + // ARN of the CMK that should be used for the AWS KMS encryption. This argument should only be used if the key is different from the default KMS-managed DynamoDB key, alias/aws/dynamodb. Note: This attribute will not be populated with the ARN of default keys. + KMSKeyArn *string `json:"kmsKeyArn,omitempty" tf:"kms_key_arn,omitempty"` + + // Whether to enable Point In Time Recovery for the replica. Default is false. + PointInTimeRecovery *bool `json:"pointInTimeRecovery,omitempty" tf:"point_in_time_recovery,omitempty"` + + // Whether to propagate the global table's tags to a replica. Default is false. Changes to tags only move in one direction: from global (source) to replica. In other words, tag drift on a replica will not trigger an update. Tag or replica changes on the global table, whether from drift or configuration changes, are propagated to replicas. Changing from true to false on a subsequent apply means replica tags are left as they were, unmanaged, not deleted. + PropagateTags *bool `json:"propagateTags,omitempty" tf:"propagate_tags,omitempty"` + + // Region name of the replica. + RegionName *string `json:"regionName,omitempty" tf:"region_name,omitempty"` +} + type TableReplicaObservation struct { // ARN of the replica @@ -388,7 +547,7 @@ type TableReplicaParameters struct { PropagateTags *bool `json:"propagateTags,omitempty" tf:"propagate_tags,omitempty"` // Region name of the replica. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional RegionName *string `json:"regionName" tf:"region_name,omitempty"` } @@ -396,6 +555,17 @@ type TableReplicaParameters struct { type TableSpec struct { v1.ResourceSpec `json:",inline"` ForProvider TableParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider TableInitParameters `json:"initProvider,omitempty"` } // TableStatus defines the observed state of Table. @@ -416,7 +586,7 @@ type TableStatus struct { type Table struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec TableSpec `json:"spec"` Status TableStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_tableitem_types.go b/apis/dynamodb/v1alpha1/zz_tableitem_types.go index 7548e6f..0d230f4 100755 --- a/apis/dynamodb/v1alpha1/zz_tableitem_types.go +++ b/apis/dynamodb/v1alpha1/zz_tableitem_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type TableItemInitParameters struct { + + // Hash key to use for lookups and identification of the item + HashKey *string `json:"hashKey,omitempty" tf:"hash_key,omitempty"` + + // JSON representation of a map of attribute name/value pairs, one for each attribute. Only the primary key attributes are required; you can optionally provide other attribute name-value pairs for the item. + Item *string `json:"item,omitempty" tf:"item,omitempty"` + + // Range key to use for lookups and identification of the item. Required if there is range key defined in the table. + RangeKey *string `json:"rangeKey,omitempty" tf:"range_key,omitempty"` +} + type TableItemObservation struct { // Hash key to use for lookups and identification of the item @@ -67,6 +83,17 @@ type TableItemParameters struct { type TableItemSpec struct { v1.ResourceSpec `json:",inline"` ForProvider TableItemParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider TableItemInitParameters `json:"initProvider,omitempty"` } // TableItemStatus defines the observed state of TableItem. @@ -87,9 +114,9 @@ type TableItemStatus struct { type TableItem struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.hashKey)",message="hashKey is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.item)",message="item is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.hashKey) || (has(self.initProvider) && has(self.initProvider.hashKey))",message="spec.forProvider.hashKey is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.item) || (has(self.initProvider) && has(self.initProvider.item))",message="spec.forProvider.item is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec TableItemSpec `json:"spec"` Status TableItemStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_tablereplica_types.go b/apis/dynamodb/v1alpha1/zz_tablereplica_types.go index f313022..a0ceb2f 100755 --- a/apis/dynamodb/v1alpha1/zz_tablereplica_types.go +++ b/apis/dynamodb/v1alpha1/zz_tablereplica_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,21 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type TableReplicaInitParameters_2 struct { + + // Whether to enable Point In Time Recovery for the replica. Default is false. + PointInTimeRecovery *bool `json:"pointInTimeRecovery,omitempty" tf:"point_in_time_recovery,omitempty"` + + // Storage class of the table replica. Valid values are STANDARD and STANDARD_INFREQUENT_ACCESS. If not used, the table replica will use the same class as the global table. + TableClassOverride *string `json:"tableClassOverride,omitempty" tf:"table_class_override,omitempty"` + + // Map of tags to populate on the created table. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type TableReplicaObservation_2 struct { // ARN of the table replica. @@ -44,7 +63,7 @@ type TableReplicaParameters_2 struct { // ARN of the main or global table which this resource will replicate. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/dynamodb/v1alpha1.Table - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true) // +kubebuilder:validation:Optional GlobalTableArn *string `json:"globalTableArn,omitempty" tf:"global_table_arn,omitempty"` @@ -95,6 +114,17 @@ type TableReplicaParameters_2 struct { type TableReplicaSpec struct { v1.ResourceSpec `json:",inline"` ForProvider TableReplicaParameters_2 `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider TableReplicaInitParameters_2 `json:"initProvider,omitempty"` } // TableReplicaStatus defines the observed state of TableReplica. @@ -115,7 +145,7 @@ type TableReplicaStatus struct { type TableReplica struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec TableReplicaSpec `json:"spec"` Status TableReplicaStatus `json:"status,omitempty"` } diff --git a/apis/dynamodb/v1alpha1/zz_tag_types.go b/apis/dynamodb/v1alpha1/zz_tag_types.go index 7655a8e..f827f1c 100755 --- a/apis/dynamodb/v1alpha1/zz_tag_types.go +++ b/apis/dynamodb/v1alpha1/zz_tag_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type TagInitParameters struct { + + // Tag value. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type TagObservation struct { // DynamoDB resource identifier and key, separated by a comma (,) @@ -52,6 +62,17 @@ type TagParameters struct { type TagSpec struct { v1.ResourceSpec `json:",inline"` ForProvider TagParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider TagInitParameters `json:"initProvider,omitempty"` } // TagStatus defines the observed state of Tag. @@ -72,8 +93,8 @@ type TagStatus struct { type Tag struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.value)",message="value is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.value) || (has(self.initProvider) && has(self.initProvider.value))",message="spec.forProvider.value is a required parameter" Spec TagSpec `json:"spec"` Status TagStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_generated.deepcopy.go b/apis/ec2/v1alpha1/zz_generated.deepcopy.go index deef37b..d02e342 100644 --- a/apis/ec2/v1alpha1/zz_generated.deepcopy.go +++ b/apis/ec2/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,26 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AccepterInitParameters) DeepCopyInto(out *AccepterInitParameters) { + *out = *in + if in.AllowRemoteVPCDNSResolution != nil { + in, out := &in.AllowRemoteVPCDNSResolution, &out.AllowRemoteVPCDNSResolution + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccepterInitParameters. +func (in *AccepterInitParameters) DeepCopy() *AccepterInitParameters { + if in == nil { + return nil + } + out := new(AccepterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AccepterObservation) DeepCopyInto(out *AccepterObservation) { *out = *in @@ -54,6 +73,21 @@ func (in *AccepterParameters) DeepCopy() *AccepterParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DNSEntryInitParameters) DeepCopyInto(out *DNSEntryInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSEntryInitParameters. +func (in *DNSEntryInitParameters) DeepCopy() *DNSEntryInitParameters { + if in == nil { + return nil + } + out := new(DNSEntryInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DNSEntryObservation) DeepCopyInto(out *DNSEntryObservation) { *out = *in @@ -94,6 +128,26 @@ func (in *DNSEntryParameters) DeepCopy() *DNSEntryParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DNSOptionsInitParameters) DeepCopyInto(out *DNSOptionsInitParameters) { + *out = *in + if in.DNSRecordIPType != nil { + in, out := &in.DNSRecordIPType, &out.DNSRecordIPType + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSOptionsInitParameters. +func (in *DNSOptionsInitParameters) DeepCopy() *DNSOptionsInitParameters { + if in == nil { + return nil + } + out := new(DNSOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DNSOptionsObservation) DeepCopyInto(out *DNSOptionsObservation) { *out = *in @@ -134,6 +188,90 @@ func (in *DNSOptionsParameters) DeepCopy() *DNSOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EgressInitParameters) DeepCopyInto(out *EgressInitParameters) { + *out = *in + if in.CidrBlocks != nil { + in, out := &in.CidrBlocks, &out.CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.FromPort != nil { + in, out := &in.FromPort, &out.FromPort + *out = new(float64) + **out = **in + } + if in.IPv6CidrBlocks != nil { + in, out := &in.IPv6CidrBlocks, &out.IPv6CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.PrefixListIds != nil { + in, out := &in.PrefixListIds, &out.PrefixListIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(string) + **out = **in + } + if in.SecurityGroups != nil { + in, out := &in.SecurityGroups, &out.SecurityGroups + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Self != nil { + in, out := &in.Self, &out.Self + *out = new(bool) + **out = **in + } + if in.ToPort != nil { + in, out := &in.ToPort, &out.ToPort + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EgressInitParameters. +func (in *EgressInitParameters) DeepCopy() *EgressInitParameters { + if in == nil { + return nil + } + out := new(EgressInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EgressObservation) DeepCopyInto(out *EgressObservation) { *out = *in @@ -302,6 +440,90 @@ func (in *EgressParameters) DeepCopy() *EgressParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *IngressInitParameters) DeepCopyInto(out *IngressInitParameters) { + *out = *in + if in.CidrBlocks != nil { + in, out := &in.CidrBlocks, &out.CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.FromPort != nil { + in, out := &in.FromPort, &out.FromPort + *out = new(float64) + **out = **in + } + if in.IPv6CidrBlocks != nil { + in, out := &in.IPv6CidrBlocks, &out.IPv6CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.PrefixListIds != nil { + in, out := &in.PrefixListIds, &out.PrefixListIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(string) + **out = **in + } + if in.SecurityGroups != nil { + in, out := &in.SecurityGroups, &out.SecurityGroups + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Self != nil { + in, out := &in.Self, &out.Self + *out = new(bool) + **out = **in + } + if in.ToPort != nil { + in, out := &in.ToPort, &out.ToPort + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressInitParameters. +func (in *IngressInitParameters) DeepCopy() *IngressInitParameters { + if in == nil { + return nil + } + out := new(IngressInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IngressObservation) DeepCopyInto(out *IngressObservation) { *out = *in @@ -470,6 +692,26 @@ func (in *IngressParameters) DeepCopy() *IngressParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RequesterInitParameters) DeepCopyInto(out *RequesterInitParameters) { + *out = *in + if in.AllowRemoteVPCDNSResolution != nil { + in, out := &in.AllowRemoteVPCDNSResolution, &out.AllowRemoteVPCDNSResolution + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RequesterInitParameters. +func (in *RequesterInitParameters) DeepCopy() *RequesterInitParameters { + if in == nil { + return nil + } + out := new(RequesterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RequesterObservation) DeepCopyInto(out *RequesterObservation) { *out = *in @@ -537,6 +779,91 @@ func (in *Route) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RouteInitParameters) DeepCopyInto(out *RouteInitParameters) { + *out = *in + if in.CarrierGatewayID != nil { + in, out := &in.CarrierGatewayID, &out.CarrierGatewayID + *out = new(string) + **out = **in + } + if in.CoreNetworkArn != nil { + in, out := &in.CoreNetworkArn, &out.CoreNetworkArn + *out = new(string) + **out = **in + } + if in.DestinationCidrBlock != nil { + in, out := &in.DestinationCidrBlock, &out.DestinationCidrBlock + *out = new(string) + **out = **in + } + if in.DestinationIPv6CidrBlock != nil { + in, out := &in.DestinationIPv6CidrBlock, &out.DestinationIPv6CidrBlock + *out = new(string) + **out = **in + } + if in.DestinationPrefixListID != nil { + in, out := &in.DestinationPrefixListID, &out.DestinationPrefixListID + *out = new(string) + **out = **in + } + if in.EgressOnlyGatewayID != nil { + in, out := &in.EgressOnlyGatewayID, &out.EgressOnlyGatewayID + *out = new(string) + **out = **in + } + if in.GatewayID != nil { + in, out := &in.GatewayID, &out.GatewayID + *out = new(string) + **out = **in + } + if in.LocalGatewayID != nil { + in, out := &in.LocalGatewayID, &out.LocalGatewayID + *out = new(string) + **out = **in + } + if in.NATGatewayID != nil { + in, out := &in.NATGatewayID, &out.NATGatewayID + *out = new(string) + **out = **in + } + if in.NetworkInterfaceID != nil { + in, out := &in.NetworkInterfaceID, &out.NetworkInterfaceID + *out = new(string) + **out = **in + } + if in.RouteTableID != nil { + in, out := &in.RouteTableID, &out.RouteTableID + *out = new(string) + **out = **in + } + if in.TransitGatewayID != nil { + in, out := &in.TransitGatewayID, &out.TransitGatewayID + *out = new(string) + **out = **in + } + if in.VPCEndpointID != nil { + in, out := &in.VPCEndpointID, &out.VPCEndpointID + *out = new(string) + **out = **in + } + if in.VPCPeeringConnectionID != nil { + in, out := &in.VPCPeeringConnectionID, &out.VPCPeeringConnectionID + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteInitParameters. +func (in *RouteInitParameters) DeepCopy() *RouteInitParameters { + if in == nil { + return nil + } + out := new(RouteInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RouteList) DeepCopyInto(out *RouteList) { *out = *in @@ -774,6 +1101,7 @@ func (in *RouteSpec) DeepCopyInto(out *RouteSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteSpec. @@ -781,55 +1109,136 @@ func (in *RouteSpec) DeepCopy() *RouteSpec { if in == nil { return nil } - out := new(RouteSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteStatus) DeepCopyInto(out *RouteStatus) { - *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteStatus. -func (in *RouteStatus) DeepCopy() *RouteStatus { - if in == nil { - return nil + out := new(RouteSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RouteStatus) DeepCopyInto(out *RouteStatus) { + *out = *in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteStatus. +func (in *RouteStatus) DeepCopy() *RouteStatus { + if in == nil { + return nil + } + out := new(RouteStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SecurityGroup) DeepCopyInto(out *SecurityGroup) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroup. +func (in *SecurityGroup) DeepCopy() *SecurityGroup { + if in == nil { + return nil + } + out := new(SecurityGroup) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *SecurityGroup) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SecurityGroupInitParameters) DeepCopyInto(out *SecurityGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Egress != nil { + in, out := &in.Egress, &out.Egress + *out = make([]EgressInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]IngressInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.NamePrefix != nil { + in, out := &in.NamePrefix, &out.NamePrefix + *out = new(string) + **out = **in + } + if in.RevokeRulesOnDelete != nil { + in, out := &in.RevokeRulesOnDelete, &out.RevokeRulesOnDelete + *out = new(bool) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } - out := new(RouteStatus) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SecurityGroup) DeepCopyInto(out *SecurityGroup) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroup. -func (in *SecurityGroup) DeepCopy() *SecurityGroup { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroupInitParameters. +func (in *SecurityGroupInitParameters) DeepCopy() *SecurityGroupInitParameters { if in == nil { return nil } - out := new(SecurityGroup) + out := new(SecurityGroupInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *SecurityGroup) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SecurityGroupList) DeepCopyInto(out *SecurityGroupList) { *out = *in @@ -922,7 +1331,8 @@ func (in *SecurityGroupObservation) DeepCopyInto(out *SecurityGroupObservation) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -937,7 +1347,8 @@ func (in *SecurityGroupObservation) DeepCopyInto(out *SecurityGroupObservation) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1011,7 +1422,8 @@ func (in *SecurityGroupParameters) DeepCopyInto(out *SecurityGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1026,7 +1438,8 @@ func (in *SecurityGroupParameters) DeepCopyInto(out *SecurityGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1087,6 +1500,89 @@ func (in *SecurityGroupRule) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SecurityGroupRuleInitParameters) DeepCopyInto(out *SecurityGroupRuleInitParameters) { + *out = *in + if in.CidrBlocks != nil { + in, out := &in.CidrBlocks, &out.CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.FromPort != nil { + in, out := &in.FromPort, &out.FromPort + *out = new(float64) + **out = **in + } + if in.IPv6CidrBlocks != nil { + in, out := &in.IPv6CidrBlocks, &out.IPv6CidrBlocks + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.PrefixListIds != nil { + in, out := &in.PrefixListIds, &out.PrefixListIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(string) + **out = **in + } + if in.Self != nil { + in, out := &in.Self, &out.Self + *out = new(bool) + **out = **in + } + if in.SourceSecurityGroupID != nil { + in, out := &in.SourceSecurityGroupID, &out.SourceSecurityGroupID + *out = new(string) + **out = **in + } + if in.ToPort != nil { + in, out := &in.ToPort, &out.ToPort + *out = new(float64) + **out = **in + } + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroupRuleInitParameters. +func (in *SecurityGroupRuleInitParameters) DeepCopy() *SecurityGroupRuleInitParameters { + if in == nil { + return nil + } + out := new(SecurityGroupRuleInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SecurityGroupRuleList) DeepCopyInto(out *SecurityGroupRuleList) { *out = *in @@ -1325,6 +1821,7 @@ func (in *SecurityGroupRuleSpec) DeepCopyInto(out *SecurityGroupRuleSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroupRuleSpec. @@ -1359,6 +1856,7 @@ func (in *SecurityGroupSpec) DeepCopyInto(out *SecurityGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecurityGroupSpec. @@ -1412,7 +1910,129 @@ func (in *Subnet) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } - return nil + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SubnetInitParameters) DeepCopyInto(out *SubnetInitParameters) { + *out = *in + if in.AssignIPv6AddressOnCreation != nil { + in, out := &in.AssignIPv6AddressOnCreation, &out.AssignIPv6AddressOnCreation + *out = new(bool) + **out = **in + } + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) + **out = **in + } + if in.AvailabilityZoneID != nil { + in, out := &in.AvailabilityZoneID, &out.AvailabilityZoneID + *out = new(string) + **out = **in + } + if in.CidrBlock != nil { + in, out := &in.CidrBlock, &out.CidrBlock + *out = new(string) + **out = **in + } + if in.CustomerOwnedIPv4Pool != nil { + in, out := &in.CustomerOwnedIPv4Pool, &out.CustomerOwnedIPv4Pool + *out = new(string) + **out = **in + } + if in.EnableDns64 != nil { + in, out := &in.EnableDns64, &out.EnableDns64 + *out = new(bool) + **out = **in + } + if in.EnableLniAtDeviceIndex != nil { + in, out := &in.EnableLniAtDeviceIndex, &out.EnableLniAtDeviceIndex + *out = new(float64) + **out = **in + } + if in.EnableResourceNameDNSARecordOnLaunch != nil { + in, out := &in.EnableResourceNameDNSARecordOnLaunch, &out.EnableResourceNameDNSARecordOnLaunch + *out = new(bool) + **out = **in + } + if in.EnableResourceNameDNSAaaaRecordOnLaunch != nil { + in, out := &in.EnableResourceNameDNSAaaaRecordOnLaunch, &out.EnableResourceNameDNSAaaaRecordOnLaunch + *out = new(bool) + **out = **in + } + if in.IPv6CidrBlock != nil { + in, out := &in.IPv6CidrBlock, &out.IPv6CidrBlock + *out = new(string) + **out = **in + } + if in.IPv6Native != nil { + in, out := &in.IPv6Native, &out.IPv6Native + *out = new(bool) + **out = **in + } + if in.MapCustomerOwnedIPOnLaunch != nil { + in, out := &in.MapCustomerOwnedIPOnLaunch, &out.MapCustomerOwnedIPOnLaunch + *out = new(bool) + **out = **in + } + if in.MapPublicIPOnLaunch != nil { + in, out := &in.MapPublicIPOnLaunch, &out.MapPublicIPOnLaunch + *out = new(bool) + **out = **in + } + if in.OutpostArn != nil { + in, out := &in.OutpostArn, &out.OutpostArn + *out = new(string) + **out = **in + } + if in.PrivateDNSHostnameTypeOnLaunch != nil { + in, out := &in.PrivateDNSHostnameTypeOnLaunch, &out.PrivateDNSHostnameTypeOnLaunch + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetInitParameters. +func (in *SubnetInitParameters) DeepCopy() *SubnetInitParameters { + if in == nil { + return nil + } + out := new(SubnetInitParameters) + in.DeepCopyInto(out) + return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. @@ -1553,7 +2173,8 @@ func (in *SubnetObservation) DeepCopyInto(out *SubnetObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1568,7 +2189,8 @@ func (in *SubnetObservation) DeepCopyInto(out *SubnetObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1683,7 +2305,8 @@ func (in *SubnetParameters) DeepCopyInto(out *SubnetParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1698,7 +2321,8 @@ func (in *SubnetParameters) DeepCopyInto(out *SubnetParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1737,6 +2361,7 @@ func (in *SubnetSpec) DeepCopyInto(out *SubnetSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetSpec. @@ -1820,6 +2445,101 @@ func (in *VPCEndpoint) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *VPCEndpointInitParameters) DeepCopyInto(out *VPCEndpointInitParameters) { + *out = *in + if in.AutoAccept != nil { + in, out := &in.AutoAccept, &out.AutoAccept + *out = new(bool) + **out = **in + } + if in.DNSOptions != nil { + in, out := &in.DNSOptions, &out.DNSOptions + *out = make([]DNSOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.IPAddressType != nil { + in, out := &in.IPAddressType, &out.IPAddressType + *out = new(string) + **out = **in + } + if in.Policy != nil { + in, out := &in.Policy, &out.Policy + *out = new(string) + **out = **in + } + if in.PrivateDNSEnabled != nil { + in, out := &in.PrivateDNSEnabled, &out.PrivateDNSEnabled + *out = new(bool) + **out = **in + } + if in.RouteTableIds != nil { + in, out := &in.RouteTableIds, &out.RouteTableIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ServiceName != nil { + in, out := &in.ServiceName, &out.ServiceName + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.VPCEndpointType != nil { + in, out := &in.VPCEndpointType, &out.VPCEndpointType + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCEndpointInitParameters. +func (in *VPCEndpointInitParameters) DeepCopy() *VPCEndpointInitParameters { + if in == nil { + return nil + } + out := new(VPCEndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VPCEndpointList) DeepCopyInto(out *VPCEndpointList) { *out = *in @@ -1987,7 +2707,8 @@ func (in *VPCEndpointObservation) DeepCopyInto(out *VPCEndpointObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2002,7 +2723,8 @@ func (in *VPCEndpointObservation) DeepCopyInto(out *VPCEndpointObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2136,7 +2858,8 @@ func (in *VPCEndpointParameters) DeepCopyInto(out *VPCEndpointParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2151,7 +2874,8 @@ func (in *VPCEndpointParameters) DeepCopyInto(out *VPCEndpointParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2195,6 +2919,7 @@ func (in *VPCEndpointSpec) DeepCopyInto(out *VPCEndpointSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCEndpointSpec. @@ -2224,6 +2949,113 @@ func (in *VPCEndpointStatus) DeepCopy() *VPCEndpointStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *VPCInitParameters) DeepCopyInto(out *VPCInitParameters) { + *out = *in + if in.AssignGeneratedIPv6CidrBlock != nil { + in, out := &in.AssignGeneratedIPv6CidrBlock, &out.AssignGeneratedIPv6CidrBlock + *out = new(bool) + **out = **in + } + if in.CidrBlock != nil { + in, out := &in.CidrBlock, &out.CidrBlock + *out = new(string) + **out = **in + } + if in.EnableDNSHostnames != nil { + in, out := &in.EnableDNSHostnames, &out.EnableDNSHostnames + *out = new(bool) + **out = **in + } + if in.EnableDNSSupport != nil { + in, out := &in.EnableDNSSupport, &out.EnableDNSSupport + *out = new(bool) + **out = **in + } + if in.EnableNetworkAddressUsageMetrics != nil { + in, out := &in.EnableNetworkAddressUsageMetrics, &out.EnableNetworkAddressUsageMetrics + *out = new(bool) + **out = **in + } + if in.IPv4IpamPoolID != nil { + in, out := &in.IPv4IpamPoolID, &out.IPv4IpamPoolID + *out = new(string) + **out = **in + } + if in.IPv4NetmaskLength != nil { + in, out := &in.IPv4NetmaskLength, &out.IPv4NetmaskLength + *out = new(float64) + **out = **in + } + if in.IPv6CidrBlock != nil { + in, out := &in.IPv6CidrBlock, &out.IPv6CidrBlock + *out = new(string) + **out = **in + } + if in.IPv6CidrBlockNetworkBorderGroup != nil { + in, out := &in.IPv6CidrBlockNetworkBorderGroup, &out.IPv6CidrBlockNetworkBorderGroup + *out = new(string) + **out = **in + } + if in.IPv6IpamPoolID != nil { + in, out := &in.IPv6IpamPoolID, &out.IPv6IpamPoolID + *out = new(string) + **out = **in + } + if in.IPv6NetmaskLength != nil { + in, out := &in.IPv6NetmaskLength, &out.IPv6NetmaskLength + *out = new(float64) + **out = **in + } + if in.InstanceTenancy != nil { + in, out := &in.InstanceTenancy, &out.InstanceTenancy + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCInitParameters. +func (in *VPCInitParameters) DeepCopy() *VPCInitParameters { + if in == nil { + return nil + } + out := new(VPCInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VPCList) DeepCopyInto(out *VPCList) { *out = *in @@ -2372,7 +3204,8 @@ func (in *VPCObservation) DeepCopyInto(out *VPCObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2387,7 +3220,8 @@ func (in *VPCObservation) DeepCopyInto(out *VPCObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2482,7 +3316,8 @@ func (in *VPCParameters) DeepCopyInto(out *VPCParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2497,7 +3332,8 @@ func (in *VPCParameters) DeepCopyInto(out *VPCParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2543,6 +3379,82 @@ func (in *VPCPeeringConnection) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *VPCPeeringConnectionInitParameters) DeepCopyInto(out *VPCPeeringConnectionInitParameters) { + *out = *in + if in.Accepter != nil { + in, out := &in.Accepter, &out.Accepter + *out = make([]AccepterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.AutoAccept != nil { + in, out := &in.AutoAccept, &out.AutoAccept + *out = new(bool) + **out = **in + } + if in.PeerOwnerID != nil { + in, out := &in.PeerOwnerID, &out.PeerOwnerID + *out = new(string) + **out = **in + } + if in.PeerRegion != nil { + in, out := &in.PeerRegion, &out.PeerRegion + *out = new(string) + **out = **in + } + if in.Requester != nil { + in, out := &in.Requester, &out.Requester + *out = make([]RequesterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCPeeringConnectionInitParameters. +func (in *VPCPeeringConnectionInitParameters) DeepCopy() *VPCPeeringConnectionInitParameters { + if in == nil { + return nil + } + out := new(VPCPeeringConnectionInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VPCPeeringConnectionList) DeepCopyInto(out *VPCPeeringConnectionList) { *out = *in @@ -2630,7 +3542,8 @@ func (in *VPCPeeringConnectionObservation) DeepCopyInto(out *VPCPeeringConnectio if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2645,7 +3558,8 @@ func (in *VPCPeeringConnectionObservation) DeepCopyInto(out *VPCPeeringConnectio if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2729,7 +3643,8 @@ func (in *VPCPeeringConnectionParameters) DeepCopyInto(out *VPCPeeringConnection if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2744,7 +3659,8 @@ func (in *VPCPeeringConnectionParameters) DeepCopyInto(out *VPCPeeringConnection if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2783,6 +3699,7 @@ func (in *VPCPeeringConnectionSpec) DeepCopyInto(out *VPCPeeringConnectionSpec) *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCPeeringConnectionSpec. @@ -2817,6 +3734,7 @@ func (in *VPCSpec) DeepCopyInto(out *VPCSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCSpec. diff --git a/apis/ec2/v1alpha1/zz_generated.managed.go b/apis/ec2/v1alpha1/zz_generated.managed.go index 8fc10c9..f82ed4c 100644 --- a/apis/ec2/v1alpha1/zz_generated.managed.go +++ b/apis/ec2/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Route) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Route. -func (mg *Route) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Route. +func (mg *Route) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Route. @@ -27,14 +27,6 @@ func (mg *Route) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Route. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Route) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Route. func (mg *Route) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Route) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Route. -func (mg *Route) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Route. +func (mg *Route) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Route. @@ -65,14 +57,6 @@ func (mg *Route) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Route. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Route) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Route. func (mg *Route) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *SecurityGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SecurityGroup. -func (mg *SecurityGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SecurityGroup. +func (mg *SecurityGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SecurityGroup. @@ -103,14 +87,6 @@ func (mg *SecurityGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SecurityGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SecurityGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SecurityGroup. func (mg *SecurityGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *SecurityGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SecurityGroup. -func (mg *SecurityGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SecurityGroup. +func (mg *SecurityGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SecurityGroup. @@ -141,14 +117,6 @@ func (mg *SecurityGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SecurityGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SecurityGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SecurityGroup. func (mg *SecurityGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *SecurityGroupRule) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SecurityGroupRule. -func (mg *SecurityGroupRule) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SecurityGroupRule. +func (mg *SecurityGroupRule) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SecurityGroupRule. @@ -179,14 +147,6 @@ func (mg *SecurityGroupRule) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SecurityGroupRule. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SecurityGroupRule) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SecurityGroupRule. func (mg *SecurityGroupRule) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *SecurityGroupRule) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SecurityGroupRule. -func (mg *SecurityGroupRule) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SecurityGroupRule. +func (mg *SecurityGroupRule) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SecurityGroupRule. @@ -217,14 +177,6 @@ func (mg *SecurityGroupRule) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SecurityGroupRule. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SecurityGroupRule) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SecurityGroupRule. func (mg *SecurityGroupRule) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *Subnet) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Subnet. -func (mg *Subnet) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Subnet. +func (mg *Subnet) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Subnet. @@ -255,14 +207,6 @@ func (mg *Subnet) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Subnet. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Subnet) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Subnet. func (mg *Subnet) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *Subnet) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Subnet. -func (mg *Subnet) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Subnet. +func (mg *Subnet) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Subnet. @@ -293,14 +237,6 @@ func (mg *Subnet) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Subnet. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Subnet) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Subnet. func (mg *Subnet) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *VPC) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this VPC. -func (mg *VPC) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this VPC. +func (mg *VPC) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this VPC. @@ -331,14 +267,6 @@ func (mg *VPC) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this VPC. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *VPC) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this VPC. func (mg *VPC) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *VPC) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this VPC. -func (mg *VPC) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this VPC. +func (mg *VPC) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this VPC. @@ -369,14 +297,6 @@ func (mg *VPC) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this VPC. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *VPC) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this VPC. func (mg *VPC) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -397,9 +317,9 @@ func (mg *VPCEndpoint) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this VPCEndpoint. -func (mg *VPCEndpoint) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this VPCEndpoint. +func (mg *VPCEndpoint) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this VPCEndpoint. @@ -407,14 +327,6 @@ func (mg *VPCEndpoint) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this VPCEndpoint. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *VPCEndpoint) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this VPCEndpoint. func (mg *VPCEndpoint) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -435,9 +347,9 @@ func (mg *VPCEndpoint) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this VPCEndpoint. -func (mg *VPCEndpoint) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this VPCEndpoint. +func (mg *VPCEndpoint) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this VPCEndpoint. @@ -445,14 +357,6 @@ func (mg *VPCEndpoint) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this VPCEndpoint. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *VPCEndpoint) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this VPCEndpoint. func (mg *VPCEndpoint) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -473,9 +377,9 @@ func (mg *VPCPeeringConnection) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this VPCPeeringConnection. -func (mg *VPCPeeringConnection) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this VPCPeeringConnection. +func (mg *VPCPeeringConnection) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this VPCPeeringConnection. @@ -483,14 +387,6 @@ func (mg *VPCPeeringConnection) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this VPCPeeringConnection. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *VPCPeeringConnection) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this VPCPeeringConnection. func (mg *VPCPeeringConnection) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -511,9 +407,9 @@ func (mg *VPCPeeringConnection) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this VPCPeeringConnection. -func (mg *VPCPeeringConnection) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this VPCPeeringConnection. +func (mg *VPCPeeringConnection) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this VPCPeeringConnection. @@ -521,14 +417,6 @@ func (mg *VPCPeeringConnection) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this VPCPeeringConnection. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *VPCPeeringConnection) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this VPCPeeringConnection. func (mg *VPCPeeringConnection) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/ec2/v1alpha1/zz_generated.resolvers.go b/apis/ec2/v1alpha1/zz_generated.resolvers.go index 38bdefb..50f483a 100644 --- a/apis/ec2/v1alpha1/zz_generated.resolvers.go +++ b/apis/ec2/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" client "sigs.k8s.io/controller-runtime/pkg/client" ) diff --git a/apis/ec2/v1alpha1/zz_generated_terraformed.go b/apis/ec2/v1alpha1/zz_generated_terraformed.go index 57a06f2..bde9e81 100755 --- a/apis/ec2/v1alpha1/zz_generated_terraformed.go +++ b/apis/ec2/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Route @@ -69,6 +74,46 @@ func (tr *Route) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Route +func (tr *Route) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Route +func (tr *Route) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Route using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Route) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *SecurityGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SecurityGroup +func (tr *SecurityGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SecurityGroup +func (tr *SecurityGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SecurityGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SecurityGroup) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *SecurityGroupRule) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SecurityGroupRule +func (tr *SecurityGroupRule) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SecurityGroupRule +func (tr *SecurityGroupRule) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SecurityGroupRule using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SecurityGroupRule) LateInitialize(attrs []byte) (bool, error) { @@ -291,6 +416,46 @@ func (tr *Subnet) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Subnet +func (tr *Subnet) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Subnet +func (tr *Subnet) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Subnet using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Subnet) LateInitialize(attrs []byte) (bool, error) { @@ -366,6 +531,46 @@ func (tr *VPC) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this VPC +func (tr *VPC) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this VPC +func (tr *VPC) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this VPC using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *VPC) LateInitialize(attrs []byte) (bool, error) { @@ -440,6 +645,46 @@ func (tr *VPCEndpoint) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this VPCEndpoint +func (tr *VPCEndpoint) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this VPCEndpoint +func (tr *VPCEndpoint) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this VPCEndpoint using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *VPCEndpoint) LateInitialize(attrs []byte) (bool, error) { @@ -514,6 +759,46 @@ func (tr *VPCPeeringConnection) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this VPCPeeringConnection +func (tr *VPCPeeringConnection) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this VPCPeeringConnection +func (tr *VPCPeeringConnection) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this VPCPeeringConnection using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *VPCPeeringConnection) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/ec2/v1alpha1/zz_groupversion_info.go b/apis/ec2/v1alpha1/zz_groupversion_info.go index 2deccbf..ed86fe3 100755 --- a/apis/ec2/v1alpha1/zz_groupversion_info.go +++ b/apis/ec2/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/ec2/v1alpha1/zz_route_types.go b/apis/ec2/v1alpha1/zz_route_types.go index 9eb3383..f2ab28c 100755 --- a/apis/ec2/v1alpha1/zz_route_types.go +++ b/apis/ec2/v1alpha1/zz_route_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,51 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type RouteInitParameters struct { + + // Identifier of a carrier gateway. This attribute can only be used when the VPC contains a subnet which is associated with a Wavelength Zone. + CarrierGatewayID *string `json:"carrierGatewayId,omitempty" tf:"carrier_gateway_id,omitempty"` + + // The Amazon Resource Name (ARN) of a core network. + CoreNetworkArn *string `json:"coreNetworkArn,omitempty" tf:"core_network_arn,omitempty"` + + // The destination CIDR block. + DestinationCidrBlock *string `json:"destinationCidrBlock,omitempty" tf:"destination_cidr_block,omitempty"` + + // The destination IPv6 CIDR block. + DestinationIPv6CidrBlock *string `json:"destinationIpv6CidrBlock,omitempty" tf:"destination_ipv6_cidr_block,omitempty"` + + // The ID of a managed prefix list destination. + DestinationPrefixListID *string `json:"destinationPrefixListId,omitempty" tf:"destination_prefix_list_id,omitempty"` + + // Identifier of a VPC Egress Only Internet Gateway. + EgressOnlyGatewayID *string `json:"egressOnlyGatewayId,omitempty" tf:"egress_only_gateway_id,omitempty"` + + // Identifier of a VPC internet gateway or a virtual private gateway. Specify local when updating a previously imported local route. + GatewayID *string `json:"gatewayId,omitempty" tf:"gateway_id,omitempty"` + + // Identifier of a Outpost local gateway. + LocalGatewayID *string `json:"localGatewayId,omitempty" tf:"local_gateway_id,omitempty"` + + // Identifier of a VPC NAT gateway. + NATGatewayID *string `json:"natGatewayId,omitempty" tf:"nat_gateway_id,omitempty"` + + // Identifier of an EC2 network interface. + NetworkInterfaceID *string `json:"networkInterfaceId,omitempty" tf:"network_interface_id,omitempty"` + + // The ID of the routing table. + RouteTableID *string `json:"routeTableId,omitempty" tf:"route_table_id,omitempty"` + + // Identifier of an EC2 Transit Gateway. + TransitGatewayID *string `json:"transitGatewayId,omitempty" tf:"transit_gateway_id,omitempty"` + + // Identifier of a VPC Endpoint. + VPCEndpointID *string `json:"vpcEndpointId,omitempty" tf:"vpc_endpoint_id,omitempty"` + + // Identifier of a VPC peering connection. + VPCPeeringConnectionID *string `json:"vpcPeeringConnectionId,omitempty" tf:"vpc_peering_connection_id,omitempty"` +} + type RouteObservation struct { // Identifier of a carrier gateway. This attribute can only be used when the VPC contains a subnet which is associated with a Wavelength Zone. @@ -141,6 +190,17 @@ type RouteParameters struct { type RouteSpec struct { v1.ResourceSpec `json:",inline"` ForProvider RouteParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider RouteInitParameters `json:"initProvider,omitempty"` } // RouteStatus defines the observed state of Route. @@ -161,8 +221,8 @@ type RouteStatus struct { type Route struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.routeTableId)",message="routeTableId is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.routeTableId) || (has(self.initProvider) && has(self.initProvider.routeTableId))",message="spec.forProvider.routeTableId is a required parameter" Spec RouteSpec `json:"spec"` Status RouteStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_securitygroup_types.go b/apis/ec2/v1alpha1/zz_securitygroup_types.go index bddd274..56bbf58 100755 --- a/apis/ec2/v1alpha1/zz_securitygroup_types.go +++ b/apis/ec2/v1alpha1/zz_securitygroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,36 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type EgressInitParameters struct { + + // List of CIDR blocks. + CidrBlocks []*string `json:"cidrBlocks,omitempty" tf:"cidr_blocks"` + + // Security group description. Cannot be "". NOTE: This field maps to the AWS GroupDescription attribute, for which there is no Update API. If you'd like to classify your security groups in a way that can be updated, use tags. + Description *string `json:"description,omitempty" tf:"description"` + + // Start port (or ICMP type number if protocol is icmp or icmpv6). + FromPort *float64 `json:"fromPort,omitempty" tf:"from_port"` + + // List of IPv6 CIDR blocks. + IPv6CidrBlocks []*string `json:"ipv6CidrBlocks,omitempty" tf:"ipv6_cidr_blocks"` + + // List of Prefix List IDs. + PrefixListIds []*string `json:"prefixListIds,omitempty" tf:"prefix_list_ids"` + + // Protocol. If you select a protocol of -1 (semantically equivalent to all, which is not a valid value here), you must specify a from_port and to_port equal to 0. The supported values are defined in the IpProtocol argument on the IpPermission API reference.12. + Protocol *string `json:"protocol,omitempty" tf:"protocol"` + + // List of security groups. A group name can be used relative to the default VPC. Otherwise, group ID. + SecurityGroups []*string `json:"securityGroups,omitempty" tf:"security_groups"` + + // Whether the security group itself will be added as a source to this ingress rule. + Self *bool `json:"self,omitempty" tf:"self"` + + // End range port (or ICMP code if protocol is icmp). + ToPort *float64 `json:"toPort,omitempty" tf:"to_port"` +} + type EgressObservation struct { // List of CIDR blocks. @@ -82,6 +116,36 @@ type EgressParameters struct { ToPort *float64 `json:"toPort,omitempty" tf:"to_port"` } +type IngressInitParameters struct { + + // List of CIDR blocks. + CidrBlocks []*string `json:"cidrBlocks,omitempty" tf:"cidr_blocks"` + + // Security group description. Cannot be "". NOTE: This field maps to the AWS GroupDescription attribute, for which there is no Update API. If you'd like to classify your security groups in a way that can be updated, use tags. + Description *string `json:"description,omitempty" tf:"description"` + + // Start port (or ICMP type number if protocol is icmp or icmpv6). + FromPort *float64 `json:"fromPort,omitempty" tf:"from_port"` + + // List of IPv6 CIDR blocks. + IPv6CidrBlocks []*string `json:"ipv6CidrBlocks,omitempty" tf:"ipv6_cidr_blocks"` + + // List of Prefix List IDs. + PrefixListIds []*string `json:"prefixListIds,omitempty" tf:"prefix_list_ids"` + + // Protocol. If you select a protocol of -1 (semantically equivalent to all, which is not a valid value here), you must specify a from_port and to_port equal to 0. The supported values are defined in the IpProtocol argument on the IpPermission API reference.12. + Protocol *string `json:"protocol,omitempty" tf:"protocol"` + + // List of security groups. A group name can be used relative to the default VPC. Otherwise, group ID. + SecurityGroups []*string `json:"securityGroups,omitempty" tf:"security_groups"` + + // Whether the security group itself will be added as a source to this ingress rule. + Self *bool `json:"self,omitempty" tf:"self"` + + // End range port (or ICMP code if protocol is icmp). + ToPort *float64 `json:"toPort,omitempty" tf:"to_port"` +} + type IngressObservation struct { // List of CIDR blocks. @@ -151,6 +215,33 @@ type IngressParameters struct { ToPort *float64 `json:"toPort,omitempty" tf:"to_port"` } +type SecurityGroupInitParameters struct { + + // Security group description. Cannot be "". NOTE: This field maps to the AWS GroupDescription attribute, for which there is no Update API. If you'd like to classify your security groups in a way that can be updated, use tags. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Configuration block for egress rules. Can be specified multiple times for each egress rule. Each egress block supports fields documented below. This argument is processed in attribute-as-blocks mode. + Egress []EgressInitParameters `json:"egress,omitempty" tf:"egress,omitempty"` + + // Configuration block for ingress rules. Can be specified multiple times for each ingress rule. Each ingress block supports fields documented below. This argument is processed in attribute-as-blocks mode. + Ingress []IngressInitParameters `json:"ingress,omitempty" tf:"ingress,omitempty"` + + // Name of the security group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // Creates a unique name beginning with the specified prefix. Conflicts with name. + NamePrefix *string `json:"namePrefix,omitempty" tf:"name_prefix,omitempty"` + + // This is normally not needed, however certain AWS services such as Elastic Map Reduce may automatically add required rules to security groups used with the service, and those rules may contain a cyclic dependency that prevent the security groups from being destroyed without removing the dependency first. Default false. + RevokeRulesOnDelete *bool `json:"revokeRulesOnDelete,omitempty" tf:"revoke_rules_on_delete,omitempty"` + + // Map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SecurityGroupObservation struct { // ARN of the security group. @@ -247,6 +338,17 @@ type SecurityGroupParameters struct { type SecurityGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SecurityGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SecurityGroupInitParameters `json:"initProvider,omitempty"` } // SecurityGroupStatus defines the observed state of SecurityGroup. @@ -267,7 +369,7 @@ type SecurityGroupStatus struct { type SecurityGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SecurityGroupSpec `json:"spec"` Status SecurityGroupStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_securitygrouprule_types.go b/apis/ec2/v1alpha1/zz_securitygrouprule_types.go index 399c45c..5aa3db9 100755 --- a/apis/ec2/v1alpha1/zz_securitygrouprule_types.go +++ b/apis/ec2/v1alpha1/zz_securitygrouprule_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,40 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SecurityGroupRuleInitParameters struct { + + // List of CIDR blocks. Cannot be specified with source_security_group_id or self. + CidrBlocks []*string `json:"cidrBlocks,omitempty" tf:"cidr_blocks,omitempty"` + + // Description of the rule. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Start port (or ICMP type number if protocol is "icmp" or "icmpv6"). + FromPort *float64 `json:"fromPort,omitempty" tf:"from_port,omitempty"` + + // List of IPv6 CIDR blocks. Cannot be specified with source_security_group_id or self. + IPv6CidrBlocks []*string `json:"ipv6CidrBlocks,omitempty" tf:"ipv6_cidr_blocks,omitempty"` + + // List of Prefix List IDs. + PrefixListIds []*string `json:"prefixListIds,omitempty" tf:"prefix_list_ids,omitempty"` + + // Protocol. If not icmp, icmpv6, tcp, udp, or all use the protocol number + Protocol *string `json:"protocol,omitempty" tf:"protocol,omitempty"` + + // Whether the security group itself will be added as a source to this ingress rule. Cannot be specified with cidr_blocks, ipv6_cidr_blocks, or source_security_group_id. + Self *bool `json:"self,omitempty" tf:"self,omitempty"` + + // Security group id to allow access to/from, depending on the type. Cannot be specified with cidr_blocks, ipv6_cidr_blocks, or self. + SourceSecurityGroupID *string `json:"sourceSecurityGroupId,omitempty" tf:"source_security_group_id,omitempty"` + + // End port (or ICMP code if protocol is "icmp"). + ToPort *float64 `json:"toPort,omitempty" tf:"to_port,omitempty"` + + // Type of rule being created. Valid options are ingress (inbound) + // or egress (outbound). + Type *string `json:"type,omitempty" tf:"type,omitempty"` +} + type SecurityGroupRuleObservation struct { // List of CIDR blocks. Cannot be specified with source_security_group_id or self. @@ -122,6 +160,17 @@ type SecurityGroupRuleParameters struct { type SecurityGroupRuleSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SecurityGroupRuleParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SecurityGroupRuleInitParameters `json:"initProvider,omitempty"` } // SecurityGroupRuleStatus defines the observed state of SecurityGroupRule. @@ -142,11 +191,11 @@ type SecurityGroupRuleStatus struct { type SecurityGroupRule struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.fromPort)",message="fromPort is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.protocol)",message="protocol is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.toPort)",message="toPort is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.type)",message="type is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.fromPort) || (has(self.initProvider) && has(self.initProvider.fromPort))",message="spec.forProvider.fromPort is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.protocol) || (has(self.initProvider) && has(self.initProvider.protocol))",message="spec.forProvider.protocol is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.toPort) || (has(self.initProvider) && has(self.initProvider.toPort))",message="spec.forProvider.toPort is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.type) || (has(self.initProvider) && has(self.initProvider.type))",message="spec.forProvider.type is a required parameter" Spec SecurityGroupRuleSpec `json:"spec"` Status SecurityGroupRuleStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_subnet_types.go b/apis/ec2/v1alpha1/zz_subnet_types.go index 07d87b9..0f1ea49 100755 --- a/apis/ec2/v1alpha1/zz_subnet_types.go +++ b/apis/ec2/v1alpha1/zz_subnet_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,65 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SubnetInitParameters struct { + + // Specify true to indicate + // that network interfaces created in the specified subnet should be + // assigned an IPv6 address. Default is false + AssignIPv6AddressOnCreation *bool `json:"assignIpv6AddressOnCreation,omitempty" tf:"assign_ipv6_address_on_creation,omitempty"` + + // AZ for the subnet. + AvailabilityZone *string `json:"availabilityZone,omitempty" tf:"availability_zone,omitempty"` + + // AZ ID of the subnet. This argument is not supported in all regions or partitions. If necessary, use availability_zone instead. + AvailabilityZoneID *string `json:"availabilityZoneId,omitempty" tf:"availability_zone_id,omitempty"` + + // The IPv4 CIDR block for the subnet. + CidrBlock *string `json:"cidrBlock,omitempty" tf:"cidr_block,omitempty"` + + // The customer owned IPv4 address pool. Typically used with the map_customer_owned_ip_on_launch argument. The outpost_arn argument must be specified when configured. + CustomerOwnedIPv4Pool *string `json:"customerOwnedIpv4Pool,omitempty" tf:"customer_owned_ipv4_pool,omitempty"` + + // Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations. Default: false. + EnableDns64 *bool `json:"enableDns64,omitempty" tf:"enable_dns64,omitempty"` + + // Indicates the device position for local network interfaces in this subnet. For example, 1 indicates local network interfaces in this subnet are the secondary network interface (eth1). A local network interface cannot be the primary network interface (eth0). + EnableLniAtDeviceIndex *float64 `json:"enableLniAtDeviceIndex,omitempty" tf:"enable_lni_at_device_index,omitempty"` + + // Indicates whether to respond to DNS queries for instance hostnames with DNS A records. Default: false. + EnableResourceNameDNSARecordOnLaunch *bool `json:"enableResourceNameDnsARecordOnLaunch,omitempty" tf:"enable_resource_name_dns_a_record_on_launch,omitempty"` + + // Indicates whether to respond to DNS queries for instance hostnames with DNS AAAA records. Default: false. + EnableResourceNameDNSAaaaRecordOnLaunch *bool `json:"enableResourceNameDnsAaaaRecordOnLaunch,omitempty" tf:"enable_resource_name_dns_aaaa_record_on_launch,omitempty"` + + // The IPv6 network range for the subnet, + // in CIDR notation. The subnet size must use a /64 prefix length. + IPv6CidrBlock *string `json:"ipv6CidrBlock,omitempty" tf:"ipv6_cidr_block,omitempty"` + + // Indicates whether to create an IPv6-only subnet. Default: false. + IPv6Native *bool `json:"ipv6Native,omitempty" tf:"ipv6_native,omitempty"` + + // Specify true to indicate that network interfaces created in the subnet should be assigned a customer owned IP address. The customer_owned_ipv4_pool and outpost_arn arguments must be specified when set to true. Default is false. + MapCustomerOwnedIPOnLaunch *bool `json:"mapCustomerOwnedIpOnLaunch,omitempty" tf:"map_customer_owned_ip_on_launch,omitempty"` + + // Specify true to indicate + // that instances launched into the subnet should be assigned + // a public IP address. Default is false. + MapPublicIPOnLaunch *bool `json:"mapPublicIpOnLaunch,omitempty" tf:"map_public_ip_on_launch,omitempty"` + + // The Amazon Resource Name (ARN) of the Outpost. + OutpostArn *string `json:"outpostArn,omitempty" tf:"outpost_arn,omitempty"` + + // The type of hostnames to assign to instances in the subnet at launch. For IPv6-only subnets, an instance DNS name must be based on the instance ID. For dual-stack and IPv4-only subnets, you can specify whether DNS names use the instance IPv4 address or the instance ID. Valid values: ip-name, resource-name. + PrivateDNSHostnameTypeOnLaunch *string `json:"privateDnsHostnameTypeOnLaunch,omitempty" tf:"private_dns_hostname_type_on_launch,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SubnetObservation struct { // The ARN of the subnet. @@ -185,6 +248,17 @@ type SubnetParameters struct { type SubnetSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SubnetParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SubnetInitParameters `json:"initProvider,omitempty"` } // SubnetStatus defines the observed state of Subnet. @@ -205,7 +279,7 @@ type SubnetStatus struct { type Subnet struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SubnetSpec `json:"spec"` Status SubnetStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_vpc_types.go b/apis/ec2/v1alpha1/zz_vpc_types.go index 224a50f..b9a90c6 100755 --- a/apis/ec2/v1alpha1/zz_vpc_types.go +++ b/apis/ec2/v1alpha1/zz_vpc_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,51 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type VPCInitParameters struct { + + // Requests an Amazon-provided IPv6 CIDR block with a /56 prefix length for the VPC. You cannot specify the range of IP addresses, or the size of the CIDR block. Default is false. Conflicts with ipv6_ipam_pool_id + AssignGeneratedIPv6CidrBlock *bool `json:"assignGeneratedIpv6CidrBlock,omitempty" tf:"assign_generated_ipv6_cidr_block,omitempty"` + + // The IPv4 CIDR block for the VPC. CIDR can be explicitly set or it can be derived from IPAM using ipv4_netmask_length. + CidrBlock *string `json:"cidrBlock,omitempty" tf:"cidr_block,omitempty"` + + // A boolean flag to enable/disable DNS hostnames in the VPC. Defaults false. + EnableDNSHostnames *bool `json:"enableDnsHostnames,omitempty" tf:"enable_dns_hostnames,omitempty"` + + // A boolean flag to enable/disable DNS support in the VPC. Defaults to true. + EnableDNSSupport *bool `json:"enableDnsSupport,omitempty" tf:"enable_dns_support,omitempty"` + + // Indicates whether Network Address Usage metrics are enabled for your VPC. Defaults to false. + EnableNetworkAddressUsageMetrics *bool `json:"enableNetworkAddressUsageMetrics,omitempty" tf:"enable_network_address_usage_metrics,omitempty"` + + // The ID of an IPv4 IPAM pool you want to use for allocating this VPC's CIDR. IPAM is a VPC feature that you can use to automate your IP address management workflows including assigning, tracking, troubleshooting, and auditing IP addresses across AWS Regions and accounts. Using IPAM you can monitor IP address usage throughout your AWS Organization. + IPv4IpamPoolID *string `json:"ipv4IpamPoolId,omitempty" tf:"ipv4_ipam_pool_id,omitempty"` + + // The netmask length of the IPv4 CIDR you want to allocate to this VPC. Requires specifying a ipv4_ipam_pool_id. + IPv4NetmaskLength *float64 `json:"ipv4NetmaskLength,omitempty" tf:"ipv4_netmask_length,omitempty"` + + // IPv6 CIDR block to request from an IPAM Pool. Can be set explicitly or derived from IPAM using ipv6_netmask_length. + IPv6CidrBlock *string `json:"ipv6CidrBlock,omitempty" tf:"ipv6_cidr_block,omitempty"` + + // By default when an IPv6 CIDR is assigned to a VPC a default ipv6_cidr_block_network_border_group will be set to the region of the VPC. This can be changed to restrict advertisement of public addresses to specific Network Border Groups such as LocalZones. + IPv6CidrBlockNetworkBorderGroup *string `json:"ipv6CidrBlockNetworkBorderGroup,omitempty" tf:"ipv6_cidr_block_network_border_group,omitempty"` + + // IPAM Pool ID for a IPv6 pool. Conflicts with assign_generated_ipv6_cidr_block. + IPv6IpamPoolID *string `json:"ipv6IpamPoolId,omitempty" tf:"ipv6_ipam_pool_id,omitempty"` + + // Netmask length to request from IPAM Pool. Conflicts with ipv6_cidr_block. This can be omitted if IPAM pool as a allocation_default_netmask_length set. Valid values: 56. + IPv6NetmaskLength *float64 `json:"ipv6NetmaskLength,omitempty" tf:"ipv6_netmask_length,omitempty"` + + // A tenancy option for instances launched into the VPC. Default is default, which ensures that EC2 instances launched in this VPC use the EC2 instance tenancy attribute specified when the EC2 instance is launched. The only other option is dedicated, which ensures that EC2 instances launched in this VPC are run on dedicated tenancy instances regardless of the tenancy attribute specified at launch. This has a dedicated per region fee of $2 per hour, plus an hourly per instance usage fee. + InstanceTenancy *string `json:"instanceTenancy,omitempty" tf:"instance_tenancy,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type VPCObservation struct { // Amazon Resource Name (ARN) of VPC @@ -155,6 +204,17 @@ type VPCParameters struct { type VPCSpec struct { v1.ResourceSpec `json:",inline"` ForProvider VPCParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider VPCInitParameters `json:"initProvider,omitempty"` } // VPCStatus defines the observed state of VPC. @@ -175,7 +235,7 @@ type VPCStatus struct { type VPC struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec VPCSpec `json:"spec"` Status VPCStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_vpcendpoint_types.go b/apis/ec2/v1alpha1/zz_vpcendpoint_types.go index 899f589..2d9adb1 100755 --- a/apis/ec2/v1alpha1/zz_vpcendpoint_types.go +++ b/apis/ec2/v1alpha1/zz_vpcendpoint_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type DNSEntryInitParameters struct { +} + type DNSEntryObservation struct { // The DNS name. @@ -25,6 +32,12 @@ type DNSEntryObservation struct { type DNSEntryParameters struct { } +type DNSOptionsInitParameters struct { + + // The DNS records created for the endpoint. Valid values are ipv4, dualstack, service-defined, and ipv6. + DNSRecordIPType *string `json:"dnsRecordIpType,omitempty" tf:"dns_record_ip_type,omitempty"` +} + type DNSOptionsObservation struct { // The DNS records created for the endpoint. Valid values are ipv4, dualstack, service-defined, and ipv6. @@ -38,6 +51,40 @@ type DNSOptionsParameters struct { DNSRecordIPType *string `json:"dnsRecordIpType,omitempty" tf:"dns_record_ip_type,omitempty"` } +type VPCEndpointInitParameters struct { + + // Accept the VPC endpoint (the VPC endpoint and service need to be in the same AWS account). + AutoAccept *bool `json:"autoAccept,omitempty" tf:"auto_accept,omitempty"` + + // The DNS options for the endpoint. See dns_options below. + DNSOptions []DNSOptionsInitParameters `json:"dnsOptions,omitempty" tf:"dns_options,omitempty"` + + // The IP address type for the endpoint. Valid values are ipv4, dualstack, and ipv6. + IPAddressType *string `json:"ipAddressType,omitempty" tf:"ip_address_type,omitempty"` + + // A policy to attach to the endpoint that controls access to the service. This is a JSON formatted string. Defaults to full access. All Gateway and some Interface endpoints support policies - see the relevant AWS documentation for more details. + Policy *string `json:"policy,omitempty" tf:"policy,omitempty"` + + // Whether or not to associate a private hosted zone with the specified VPC. Applicable for endpoints of type Interface. + // Defaults to false. + PrivateDNSEnabled *bool `json:"privateDnsEnabled,omitempty" tf:"private_dns_enabled,omitempty"` + + // One or more route table IDs. Applicable for endpoints of type Gateway. + RouteTableIds []*string `json:"routeTableIds,omitempty" tf:"route_table_ids,omitempty"` + + // The service name. For AWS services the service name is usually in the form com.amazonaws.. (the SageMaker Notebook service is an exception to this rule, the service name is in the form aws.sagemaker..notebook). + ServiceName *string `json:"serviceName,omitempty" tf:"service_name,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // The VPC endpoint type, Gateway, GatewayLoadBalancer, or Interface. Defaults to Gateway. + VPCEndpointType *string `json:"vpcEndpointType,omitempty" tf:"vpc_endpoint_type,omitempty"` +} + type VPCEndpointObservation struct { // The Amazon Resource Name (ARN) of the VPC endpoint. @@ -206,6 +253,17 @@ type VPCEndpointParameters struct { type VPCEndpointSpec struct { v1.ResourceSpec `json:",inline"` ForProvider VPCEndpointParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider VPCEndpointInitParameters `json:"initProvider,omitempty"` } // VPCEndpointStatus defines the observed state of VPCEndpoint. @@ -226,8 +284,8 @@ type VPCEndpointStatus struct { type VPCEndpoint struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.serviceName)",message="serviceName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec VPCEndpointSpec `json:"spec"` Status VPCEndpointStatus `json:"status,omitempty"` } diff --git a/apis/ec2/v1alpha1/zz_vpcpeeringconnection_types.go b/apis/ec2/v1alpha1/zz_vpcpeeringconnection_types.go index 15c6ddb..1519511 100755 --- a/apis/ec2/v1alpha1/zz_vpcpeeringconnection_types.go +++ b/apis/ec2/v1alpha1/zz_vpcpeeringconnection_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,13 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type AccepterInitParameters struct { + + // Allow a local VPC to resolve public DNS hostnames to + // private IP addresses when queried from instances in the peer VPC. + AllowRemoteVPCDNSResolution *bool `json:"allowRemoteVpcDnsResolution,omitempty" tf:"allow_remote_vpc_dns_resolution,omitempty"` +} + type AccepterObservation struct { // Allow a local VPC to resolve public DNS hostnames to @@ -28,6 +39,13 @@ type AccepterParameters struct { AllowRemoteVPCDNSResolution *bool `json:"allowRemoteVpcDnsResolution,omitempty" tf:"allow_remote_vpc_dns_resolution,omitempty"` } +type RequesterInitParameters struct { + + // Allow a local VPC to resolve public DNS hostnames to + // private IP addresses when queried from instances in the peer VPC. + AllowRemoteVPCDNSResolution *bool `json:"allowRemoteVpcDnsResolution,omitempty" tf:"allow_remote_vpc_dns_resolution,omitempty"` +} + type RequesterObservation struct { // Allow a local VPC to resolve public DNS hostnames to @@ -43,6 +61,34 @@ type RequesterParameters struct { AllowRemoteVPCDNSResolution *bool `json:"allowRemoteVpcDnsResolution,omitempty" tf:"allow_remote_vpc_dns_resolution,omitempty"` } +type VPCPeeringConnectionInitParameters struct { + + // An optional configuration block that allows for VPC Peering Connection options to be set for the VPC that accepts + // the peering connection (a maximum of one). + Accepter []AccepterInitParameters `json:"accepter,omitempty" tf:"accepter,omitempty"` + + // Accept the peering (both VPCs need to be in the same AWS account and region). + AutoAccept *bool `json:"autoAccept,omitempty" tf:"auto_accept,omitempty"` + + // The AWS account ID of the owner of the peer VPC. + // Defaults to the account ID the AWS provider is currently connected to. + PeerOwnerID *string `json:"peerOwnerId,omitempty" tf:"peer_owner_id,omitempty"` + + // The region of the accepter VPC of the VPC Peering Connection. auto_accept must be false, + // and use the aws_vpc_peering_connection_accepter to manage the accepter side. + PeerRegion *string `json:"peerRegion,omitempty" tf:"peer_region,omitempty"` + + // A optional configuration block that allows for VPC Peering Connection options to be set for the VPC that requests + // the peering connection (a maximum of one). + Requester []RequesterInitParameters `json:"requester,omitempty" tf:"requester,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type VPCPeeringConnectionObservation struct { // The status of the VPC Peering Connection request. @@ -106,7 +152,7 @@ type VPCPeeringConnectionParameters struct { // The ID of the VPC with which you are creating the VPC Peering Connection. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/ec2/v1alpha1.VPC - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional PeerVPCID *string `json:"peerVpcId,omitempty" tf:"peer_vpc_id,omitempty"` @@ -154,6 +200,17 @@ type VPCPeeringConnectionParameters struct { type VPCPeeringConnectionSpec struct { v1.ResourceSpec `json:",inline"` ForProvider VPCPeeringConnectionParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider VPCPeeringConnectionInitParameters `json:"initProvider,omitempty"` } // VPCPeeringConnectionStatus defines the observed state of VPCPeeringConnection. @@ -174,7 +231,7 @@ type VPCPeeringConnectionStatus struct { type VPCPeeringConnection struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec VPCPeeringConnectionSpec `json:"spec"` Status VPCPeeringConnectionStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_cluster_types.go b/apis/elasticache/v1alpha1/zz_cluster_types.go index c8d2f33..e8ef657 100755 --- a/apis/elasticache/v1alpha1/zz_cluster_types.go +++ b/apis/elasticache/v1alpha1/zz_cluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type CacheNodesInitParameters struct { +} + type CacheNodesObservation struct { Address *string `json:"address,omitempty" tf:"address,omitempty"` @@ -31,6 +38,90 @@ type CacheNodesObservation struct { type CacheNodesParameters struct { } +type ClusterInitParameters struct { + + // Whether any database modifications are applied immediately, or during the next maintenance window. Default is false. See Amazon ElastiCache Documentation for more information.. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // Specifies whether minor version engine upgrades will be applied automatically to the underlying Cache Cluster instances during the maintenance window. + // Only supported for engine type "redis" and if the engine version is 6 or higher. + // Defaults to true. + AutoMinorVersionUpgrade *string `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // Availability Zone for the cache cluster. If you want to create cache nodes in multi-az, use preferred_availability_zones instead. Default: System chosen Availability Zone. Changing this value will re-create the resource. + AvailabilityZone *string `json:"availabilityZone,omitempty" tf:"availability_zone,omitempty"` + + // Whether the nodes in this Memcached node group are created in a single Availability Zone or created across multiple Availability Zones in the cluster's region. Valid values for this parameter are single-az or cross-az, default is single-az. If you want to choose cross-az, num_cache_nodes must be greater than 1. + AzMode *string `json:"azMode,omitempty" tf:"az_mode,omitempty"` + + // – Name of the cache engine to be used for this cache cluster. Valid values are memcached or redis. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // – Version number of the cache engine to be used. + // If not set, defaults to the latest version. + // See Describe Cache Engine Versions in the AWS Documentation for supported versions. + // When engine is redis and the version is 6 or higher, the major and minor version can be set, e.g., 6.2, + // or the minor version can be unspecified which will use the latest version at creation time, e.g., 6.x. + // Otherwise, specify the full version desired, e.g., 5.0.6. + // The actual engine version used is returned in the attribute engine_version_actual, see Attributes Reference below. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // Name of your final cluster snapshot. If omitted, no final snapshot will be made. + FinalSnapshotIdentifier *string `json:"finalSnapshotIdentifier,omitempty" tf:"final_snapshot_identifier,omitempty"` + + // The IP version to advertise in the discovery protocol. Valid values are ipv4 or ipv6. + IPDiscovery *string `json:"ipDiscovery,omitempty" tf:"ip_discovery,omitempty"` + + // Specifies the destination and format of Redis SLOWLOG or Redis Engine Log. See the documentation on Amazon ElastiCache. See Log Delivery Configuration below for more details. + LogDeliveryConfiguration []LogDeliveryConfigurationInitParameters `json:"logDeliveryConfiguration,omitempty" tf:"log_delivery_configuration,omitempty"` + + // ddd:hh24:mi (24H Clock UTC). + // The minimum maintenance window is a 60 minute period. Example: sun:05:00-sun:09:00. + MaintenanceWindow *string `json:"maintenanceWindow,omitempty" tf:"maintenance_window,omitempty"` + + // The IP versions for cache cluster connections. IPv6 is supported with Redis engine 6.2 onword or Memcached version 1.6.6 for all Nitro system instances. Valid values are ipv4, ipv6 or dual_stack. + NetworkType *string `json:"networkType,omitempty" tf:"network_type,omitempty"` + + // create the resource. + NodeType *string `json:"nodeType,omitempty" tf:"node_type,omitempty"` + + // east-1:012345678999:my_sns_topic. + NotificationTopicArn *string `json:"notificationTopicArn,omitempty" tf:"notification_topic_arn,omitempty"` + + // – The initial number of cache nodes that the cache cluster will have. For Redis, this value must be 1. For Memcached, this value must be between 1 and 40. If this number is reduced on subsequent runs, the highest numbered nodes will be removed. + NumCacheNodes *float64 `json:"numCacheNodes,omitempty" tf:"num_cache_nodes,omitempty"` + + // Specify the outpost mode that will apply to the cache cluster creation. Valid values are "single-outpost" and "cross-outpost", however AWS currently only supports "single-outpost" mode. + OutpostMode *string `json:"outpostMode,omitempty" tf:"outpost_mode,omitempty"` + + // create the resource. + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // List of the Availability Zones in which cache nodes are created. If you are creating your cluster in an Amazon VPC you can only locate nodes in Availability Zones that are associated with the subnets in the selected subnet group. The number of Availability Zones listed must equal the value of num_cache_nodes. If you want all the nodes in the same Availability Zone, use availability_zone instead, or repeat the Availability Zone multiple times in the list. Default: System chosen Availability Zones. Detecting drift of existing node availability zone is not currently supported. Updating this argument by itself to migrate existing node availability zones is not currently supported and will show a perpetual difference. + PreferredAvailabilityZones []*string `json:"preferredAvailabilityZones,omitempty" tf:"preferred_availability_zones,omitempty"` + + // The outpost ARN in which the cache cluster will be created. + PreferredOutpostArn *string `json:"preferredOutpostArn,omitempty" tf:"preferred_outpost_arn,omitempty"` + + // element string list containing an Amazon Resource Name (ARN) of a Redis RDB snapshot file stored in Amazon S3. The object name cannot contain any commas. Changing snapshot_arns forces a new resource. + SnapshotArns []*string `json:"snapshotArns,omitempty" tf:"snapshot_arns,omitempty"` + + // Name of a snapshot from which to restore data into the new node group. Changing snapshot_name forces a new resource. + SnapshotName *string `json:"snapshotName,omitempty" tf:"snapshot_name,omitempty"` + + // Number of days for which ElastiCache will retain automatic cache cluster snapshots before deleting them. For example, if you set SnapshotRetentionLimit to 5, then a snapshot that was taken today will be retained for 5 days before being deleted. If the value of SnapshotRetentionLimit is set to zero (0), backups are turned off. Please note that setting a snapshot_retention_limit is not supported on cache.t1.micro cache nodes + SnapshotRetentionLimit *float64 `json:"snapshotRetentionLimit,omitempty" tf:"snapshot_retention_limit,omitempty"` + + // Daily time range (in UTC) during which ElastiCache will begin taking a daily snapshot of your cache cluster. Example: 05:00-09:00 + SnapshotWindow *string `json:"snapshotWindow,omitempty" tf:"snapshot_window,omitempty"` + + // Map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterObservation struct { // Whether any database modifications are applied immediately, or during the next maintenance window. Default is false. See Amazon ElastiCache Documentation for more information.. @@ -247,7 +338,7 @@ type ClusterParameters struct { // ID of the replication group to which this cluster should belong. If this parameter is specified, the cluster is added to the specified replication group as a read replica; otherwise, the cluster is a standalone primary that is not part of any replication group. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/elasticache/v1alpha1.ReplicationGroup - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional ReplicationGroupID *string `json:"replicationGroupId,omitempty" tf:"replication_group_id,omitempty"` @@ -312,6 +403,21 @@ type ClusterParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type LogDeliveryConfigurationInitParameters struct { + + // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. + Destination *string `json:"destination,omitempty" tf:"destination,omitempty"` + + // For CloudWatch Logs use cloudwatch-logs or for Kinesis Data Firehose use kinesis-firehose. + DestinationType *string `json:"destinationType,omitempty" tf:"destination_type,omitempty"` + + // Valid values are json or text + LogFormat *string `json:"logFormat,omitempty" tf:"log_format,omitempty"` + + // Valid values are slow-log or engine-log. Max 1 of each. + LogType *string `json:"logType,omitempty" tf:"log_type,omitempty"` +} + type LogDeliveryConfigurationObservation struct { // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. @@ -330,19 +436,19 @@ type LogDeliveryConfigurationObservation struct { type LogDeliveryConfigurationParameters struct { // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Destination *string `json:"destination" tf:"destination,omitempty"` // For CloudWatch Logs use cloudwatch-logs or for Kinesis Data Firehose use kinesis-firehose. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional DestinationType *string `json:"destinationType" tf:"destination_type,omitempty"` // Valid values are json or text - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional LogFormat *string `json:"logFormat" tf:"log_format,omitempty"` // Valid values are slow-log or engine-log. Max 1 of each. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional LogType *string `json:"logType" tf:"log_type,omitempty"` } @@ -350,6 +456,17 @@ type LogDeliveryConfigurationParameters struct { type ClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInitParameters `json:"initProvider,omitempty"` } // ClusterStatus defines the observed state of Cluster. @@ -370,7 +487,7 @@ type ClusterStatus struct { type Cluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSpec `json:"spec"` Status ClusterStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_generated.deepcopy.go b/apis/elasticache/v1alpha1/zz_generated.deepcopy.go index 04ae39e..a7e99fe 100644 --- a/apis/elasticache/v1alpha1/zz_generated.deepcopy.go +++ b/apis/elasticache/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,26 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AuthenticationModeInitParameters) DeepCopyInto(out *AuthenticationModeInitParameters) { + *out = *in + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AuthenticationModeInitParameters. +func (in *AuthenticationModeInitParameters) DeepCopy() *AuthenticationModeInitParameters { + if in == nil { + return nil + } + out := new(AuthenticationModeInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AuthenticationModeObservation) DeepCopyInto(out *AuthenticationModeObservation) { *out = *in @@ -68,6 +87,21 @@ func (in *AuthenticationModeParameters) DeepCopy() *AuthenticationModeParameters return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CacheNodesInitParameters) DeepCopyInto(out *CacheNodesInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CacheNodesInitParameters. +func (in *CacheNodesInitParameters) DeepCopy() *CacheNodesInitParameters { + if in == nil { + return nil + } + out := new(CacheNodesInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *CacheNodesObservation) DeepCopyInto(out *CacheNodesObservation) { *out = *in @@ -150,6 +184,177 @@ func (in *Cluster) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInitParameters) DeepCopyInto(out *ClusterInitParameters) { + *out = *in + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(string) + **out = **in + } + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) + **out = **in + } + if in.AzMode != nil { + in, out := &in.AzMode, &out.AzMode + *out = new(string) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.IPDiscovery != nil { + in, out := &in.IPDiscovery, &out.IPDiscovery + *out = new(string) + **out = **in + } + if in.LogDeliveryConfiguration != nil { + in, out := &in.LogDeliveryConfiguration, &out.LogDeliveryConfiguration + *out = make([]LogDeliveryConfigurationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.MaintenanceWindow != nil { + in, out := &in.MaintenanceWindow, &out.MaintenanceWindow + *out = new(string) + **out = **in + } + if in.NetworkType != nil { + in, out := &in.NetworkType, &out.NetworkType + *out = new(string) + **out = **in + } + if in.NodeType != nil { + in, out := &in.NodeType, &out.NodeType + *out = new(string) + **out = **in + } + if in.NotificationTopicArn != nil { + in, out := &in.NotificationTopicArn, &out.NotificationTopicArn + *out = new(string) + **out = **in + } + if in.NumCacheNodes != nil { + in, out := &in.NumCacheNodes, &out.NumCacheNodes + *out = new(float64) + **out = **in + } + if in.OutpostMode != nil { + in, out := &in.OutpostMode, &out.OutpostMode + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PreferredAvailabilityZones != nil { + in, out := &in.PreferredAvailabilityZones, &out.PreferredAvailabilityZones + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.PreferredOutpostArn != nil { + in, out := &in.PreferredOutpostArn, &out.PreferredOutpostArn + *out = new(string) + **out = **in + } + if in.SnapshotArns != nil { + in, out := &in.SnapshotArns, &out.SnapshotArns + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnapshotName != nil { + in, out := &in.SnapshotName, &out.SnapshotName + *out = new(string) + **out = **in + } + if in.SnapshotRetentionLimit != nil { + in, out := &in.SnapshotRetentionLimit, &out.SnapshotRetentionLimit + *out = new(float64) + **out = **in + } + if in.SnapshotWindow != nil { + in, out := &in.SnapshotWindow, &out.SnapshotWindow + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInitParameters. +func (in *ClusterInitParameters) DeepCopy() *ClusterInitParameters { + if in == nil { + return nil + } + out := new(ClusterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterList) DeepCopyInto(out *ClusterList) { *out = *in @@ -375,7 +580,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -390,7 +596,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -617,7 +824,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -632,7 +840,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -656,6 +865,7 @@ func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. @@ -685,6 +895,41 @@ func (in *ClusterStatus) DeepCopy() *ClusterStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *LogDeliveryConfigurationInitParameters) DeepCopyInto(out *LogDeliveryConfigurationInitParameters) { + *out = *in + if in.Destination != nil { + in, out := &in.Destination, &out.Destination + *out = new(string) + **out = **in + } + if in.DestinationType != nil { + in, out := &in.DestinationType, &out.DestinationType + *out = new(string) + **out = **in + } + if in.LogFormat != nil { + in, out := &in.LogFormat, &out.LogFormat + *out = new(string) + **out = **in + } + if in.LogType != nil { + in, out := &in.LogType, &out.LogType + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LogDeliveryConfigurationInitParameters. +func (in *LogDeliveryConfigurationInitParameters) DeepCopy() *LogDeliveryConfigurationInitParameters { + if in == nil { + return nil + } + out := new(LogDeliveryConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LogDeliveryConfigurationObservation) DeepCopyInto(out *LogDeliveryConfigurationObservation) { *out = *in @@ -783,30 +1028,99 @@ func (in *ParameterGroup) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ParameterGroupList) DeepCopyInto(out *ParameterGroupList) { +func (in *ParameterGroupInitParameters) DeepCopyInto(out *ParameterGroupInitParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]ParameterGroup, len(*in)) + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Family != nil { + in, out := &in.Family, &out.Family + *out = new(string) + **out = **in + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ParameterInitParameters, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupList. -func (in *ParameterGroupList) DeepCopy() *ParameterGroupList { - if in == nil { - return nil - } - out := new(ParameterGroupList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupInitParameters. +func (in *ParameterGroupInitParameters) DeepCopy() *ParameterGroupInitParameters { + if in == nil { + return nil + } + out := new(ParameterGroupInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterGroupList) DeepCopyInto(out *ParameterGroupList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ParameterGroup, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupList. +func (in *ParameterGroupList) DeepCopy() *ParameterGroupList { + if in == nil { + return nil + } + out := new(ParameterGroupList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. func (in *ParameterGroupList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c @@ -857,7 +1171,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -872,7 +1187,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -929,7 +1245,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -944,7 +1261,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -968,6 +1286,7 @@ func (in *ParameterGroupSpec) DeepCopyInto(out *ParameterGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupSpec. @@ -997,6 +1316,31 @@ func (in *ParameterGroupStatus) DeepCopy() *ParameterGroupStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterInitParameters) DeepCopyInto(out *ParameterInitParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterInitParameters. +func (in *ParameterInitParameters) DeepCopy() *ParameterInitParameters { + if in == nil { + return nil + } + out := new(ParameterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterObservation) DeepCopyInto(out *ParameterObservation) { *out = *in @@ -1017,63 +1361,276 @@ func (in *ParameterObservation) DeepCopy() *ParameterObservation { if in == nil { return nil } - out := new(ParameterObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ParameterParameters) DeepCopyInto(out *ParameterParameters) { - *out = *in - if in.Name != nil { - in, out := &in.Name, &out.Name - *out = new(string) - **out = **in + out := new(ParameterObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterParameters) DeepCopyInto(out *ParameterParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterParameters. +func (in *ParameterParameters) DeepCopy() *ParameterParameters { + if in == nil { + return nil + } + out := new(ParameterParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ReplicationGroup) DeepCopyInto(out *ReplicationGroup) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicationGroup. +func (in *ReplicationGroup) DeepCopy() *ReplicationGroup { + if in == nil { + return nil + } + out := new(ReplicationGroup) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ReplicationGroup) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ReplicationGroupInitParameters) DeepCopyInto(out *ReplicationGroupInitParameters) { + *out = *in + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } + if in.AtRestEncryptionEnabled != nil { + in, out := &in.AtRestEncryptionEnabled, &out.AtRestEncryptionEnabled + *out = new(bool) + **out = **in + } + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(string) + **out = **in + } + if in.AutomaticFailoverEnabled != nil { + in, out := &in.AutomaticFailoverEnabled, &out.AutomaticFailoverEnabled + *out = new(bool) + **out = **in + } + if in.DataTieringEnabled != nil { + in, out := &in.DataTieringEnabled, &out.DataTieringEnabled + *out = new(bool) + **out = **in + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.GlobalReplicationGroupID != nil { + in, out := &in.GlobalReplicationGroupID, &out.GlobalReplicationGroupID + *out = new(string) + **out = **in + } + if in.LogDeliveryConfiguration != nil { + in, out := &in.LogDeliveryConfiguration, &out.LogDeliveryConfiguration + *out = make([]ReplicationGroupLogDeliveryConfigurationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.MaintenanceWindow != nil { + in, out := &in.MaintenanceWindow, &out.MaintenanceWindow + *out = new(string) + **out = **in + } + if in.MultiAzEnabled != nil { + in, out := &in.MultiAzEnabled, &out.MultiAzEnabled + *out = new(bool) + **out = **in + } + if in.NodeType != nil { + in, out := &in.NodeType, &out.NodeType + *out = new(string) + **out = **in + } + if in.NotificationTopicArn != nil { + in, out := &in.NotificationTopicArn, &out.NotificationTopicArn + *out = new(string) + **out = **in + } + if in.NumCacheClusters != nil { + in, out := &in.NumCacheClusters, &out.NumCacheClusters + *out = new(float64) + **out = **in + } + if in.NumNodeGroups != nil { + in, out := &in.NumNodeGroups, &out.NumNodeGroups + *out = new(float64) + **out = **in + } + if in.ParameterGroupName != nil { + in, out := &in.ParameterGroupName, &out.ParameterGroupName + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PreferredCacheClusterAzs != nil { + in, out := &in.PreferredCacheClusterAzs, &out.PreferredCacheClusterAzs + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ReplicasPerNodeGroup != nil { + in, out := &in.ReplicasPerNodeGroup, &out.ReplicasPerNodeGroup + *out = new(float64) + **out = **in + } + if in.SecurityGroupNames != nil { + in, out := &in.SecurityGroupNames, &out.SecurityGroupNames + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnapshotArns != nil { + in, out := &in.SnapshotArns, &out.SnapshotArns + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnapshotName != nil { + in, out := &in.SnapshotName, &out.SnapshotName + *out = new(string) + **out = **in + } + if in.SnapshotRetentionLimit != nil { + in, out := &in.SnapshotRetentionLimit, &out.SnapshotRetentionLimit + *out = new(float64) + **out = **in + } + if in.SnapshotWindow != nil { + in, out := &in.SnapshotWindow, &out.SnapshotWindow + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } - if in.Value != nil { - in, out := &in.Value, &out.Value - *out = new(string) + if in.TransitEncryptionEnabled != nil { + in, out := &in.TransitEncryptionEnabled, &out.TransitEncryptionEnabled + *out = new(bool) **out = **in } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterParameters. -func (in *ParameterParameters) DeepCopy() *ParameterParameters { - if in == nil { - return nil + if in.UserGroupIds != nil { + in, out := &in.UserGroupIds, &out.UserGroupIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } } - out := new(ParameterParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ReplicationGroup) DeepCopyInto(out *ReplicationGroup) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicationGroup. -func (in *ReplicationGroup) DeepCopy() *ReplicationGroup { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicationGroupInitParameters. +func (in *ReplicationGroupInitParameters) DeepCopy() *ReplicationGroupInitParameters { if in == nil { return nil } - out := new(ReplicationGroup) + out := new(ReplicationGroupInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ReplicationGroup) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ReplicationGroupList) DeepCopyInto(out *ReplicationGroupList) { *out = *in @@ -1106,6 +1663,41 @@ func (in *ReplicationGroupList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ReplicationGroupLogDeliveryConfigurationInitParameters) DeepCopyInto(out *ReplicationGroupLogDeliveryConfigurationInitParameters) { + *out = *in + if in.Destination != nil { + in, out := &in.Destination, &out.Destination + *out = new(string) + **out = **in + } + if in.DestinationType != nil { + in, out := &in.DestinationType, &out.DestinationType + *out = new(string) + **out = **in + } + if in.LogFormat != nil { + in, out := &in.LogFormat, &out.LogFormat + *out = new(string) + **out = **in + } + if in.LogType != nil { + in, out := &in.LogType, &out.LogType + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicationGroupLogDeliveryConfigurationInitParameters. +func (in *ReplicationGroupLogDeliveryConfigurationInitParameters) DeepCopy() *ReplicationGroupLogDeliveryConfigurationInitParameters { + if in == nil { + return nil + } + out := new(ReplicationGroupLogDeliveryConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ReplicationGroupLogDeliveryConfigurationObservation) DeepCopyInto(out *ReplicationGroupLogDeliveryConfigurationObservation) { *out = *in @@ -1404,7 +1996,8 @@ func (in *ReplicationGroupObservation) DeepCopyInto(out *ReplicationGroupObserva if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1419,7 +2012,8 @@ func (in *ReplicationGroupObservation) DeepCopyInto(out *ReplicationGroupObserva if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1678,7 +2272,8 @@ func (in *ReplicationGroupParameters) DeepCopyInto(out *ReplicationGroupParamete if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1693,7 +2288,8 @@ func (in *ReplicationGroupParameters) DeepCopyInto(out *ReplicationGroupParamete if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1733,6 +2329,7 @@ func (in *ReplicationGroupSpec) DeepCopyInto(out *ReplicationGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicationGroupSpec. @@ -1789,6 +2386,58 @@ func (in *SubnetGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SubnetGroupInitParameters) DeepCopyInto(out *SubnetGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupInitParameters. +func (in *SubnetGroupInitParameters) DeepCopy() *SubnetGroupInitParameters { + if in == nil { + return nil + } + out := new(SubnetGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SubnetGroupList) DeepCopyInto(out *SubnetGroupList) { *out = *in @@ -1858,7 +2507,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1873,7 +2523,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1936,7 +2587,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1951,7 +2603,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1975,6 +2628,7 @@ func (in *SubnetGroupSpec) DeepCopyInto(out *SubnetGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupSpec. @@ -2058,6 +2712,58 @@ func (in *UserGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *UserGroupInitParameters) DeepCopyInto(out *UserGroupInitParameters) { + *out = *in + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UserGroupInitParameters. +func (in *UserGroupInitParameters) DeepCopy() *UserGroupInitParameters { + if in == nil { + return nil + } + out := new(UserGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *UserGroupList) DeepCopyInto(out *UserGroupList) { *out = *in @@ -2116,7 +2822,8 @@ func (in *UserGroupObservation) DeepCopyInto(out *UserGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2131,7 +2838,8 @@ func (in *UserGroupObservation) DeepCopyInto(out *UserGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2182,7 +2890,8 @@ func (in *UserGroupParameters) DeepCopyInto(out *UserGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2197,7 +2906,8 @@ func (in *UserGroupParameters) DeepCopyInto(out *UserGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2244,6 +2954,7 @@ func (in *UserGroupSpec) DeepCopyInto(out *UserGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UserGroupSpec. @@ -2273,6 +2984,80 @@ func (in *UserGroupStatus) DeepCopy() *UserGroupStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *UserInitParameters) DeepCopyInto(out *UserInitParameters) { + *out = *in + if in.AccessString != nil { + in, out := &in.AccessString, &out.AccessString + *out = new(string) + **out = **in + } + if in.AuthenticationMode != nil { + in, out := &in.AuthenticationMode, &out.AuthenticationMode + *out = make([]AuthenticationModeInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.NoPasswordRequired != nil { + in, out := &in.NoPasswordRequired, &out.NoPasswordRequired + *out = new(bool) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.UserName != nil { + in, out := &in.UserName, &out.UserName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UserInitParameters. +func (in *UserInitParameters) DeepCopy() *UserInitParameters { + if in == nil { + return nil + } + out := new(UserInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *UserList) DeepCopyInto(out *UserList) { *out = *in @@ -2348,7 +3133,8 @@ func (in *UserObservation) DeepCopyInto(out *UserObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2363,7 +3149,8 @@ func (in *UserObservation) DeepCopyInto(out *UserObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2434,7 +3221,8 @@ func (in *UserParameters) DeepCopyInto(out *UserParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2449,7 +3237,8 @@ func (in *UserParameters) DeepCopyInto(out *UserParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2478,6 +3267,7 @@ func (in *UserSpec) DeepCopyInto(out *UserSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new UserSpec. diff --git a/apis/elasticache/v1alpha1/zz_generated.managed.go b/apis/elasticache/v1alpha1/zz_generated.managed.go index 8003b9d..728824f 100644 --- a/apis/elasticache/v1alpha1/zz_generated.managed.go +++ b/apis/elasticache/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Cluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Cluster. -func (mg *Cluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Cluster. +func (mg *Cluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Cluster. @@ -27,14 +27,6 @@ func (mg *Cluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Cluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Cluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Cluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Cluster. -func (mg *Cluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Cluster. +func (mg *Cluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Cluster. @@ -65,14 +57,6 @@ func (mg *Cluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Cluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Cluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *ParameterGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ParameterGroup. @@ -103,14 +87,6 @@ func (mg *ParameterGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ParameterGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ParameterGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *ParameterGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ParameterGroup. @@ -141,14 +117,6 @@ func (mg *ParameterGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ParameterGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ParameterGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *ReplicationGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ReplicationGroup. -func (mg *ReplicationGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ReplicationGroup. +func (mg *ReplicationGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ReplicationGroup. @@ -179,14 +147,6 @@ func (mg *ReplicationGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ReplicationGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ReplicationGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ReplicationGroup. func (mg *ReplicationGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *ReplicationGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ReplicationGroup. -func (mg *ReplicationGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ReplicationGroup. +func (mg *ReplicationGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ReplicationGroup. @@ -217,14 +177,6 @@ func (mg *ReplicationGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ReplicationGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ReplicationGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ReplicationGroup. func (mg *ReplicationGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *SubnetGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SubnetGroup. @@ -255,14 +207,6 @@ func (mg *SubnetGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SubnetGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SubnetGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *SubnetGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SubnetGroup. @@ -293,14 +237,6 @@ func (mg *SubnetGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SubnetGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SubnetGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *User) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this User. -func (mg *User) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this User. +func (mg *User) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this User. @@ -331,14 +267,6 @@ func (mg *User) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this User. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *User) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this User. func (mg *User) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *User) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this User. -func (mg *User) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this User. +func (mg *User) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this User. @@ -369,14 +297,6 @@ func (mg *User) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this User. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *User) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this User. func (mg *User) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -397,9 +317,9 @@ func (mg *UserGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this UserGroup. -func (mg *UserGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this UserGroup. +func (mg *UserGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this UserGroup. @@ -407,14 +327,6 @@ func (mg *UserGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this UserGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *UserGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this UserGroup. func (mg *UserGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -435,9 +347,9 @@ func (mg *UserGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this UserGroup. -func (mg *UserGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this UserGroup. +func (mg *UserGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this UserGroup. @@ -445,14 +357,6 @@ func (mg *UserGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this UserGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *UserGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this UserGroup. func (mg *UserGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/elasticache/v1alpha1/zz_generated.resolvers.go b/apis/elasticache/v1alpha1/zz_generated.resolvers.go index 6ca8c32..067aad4 100644 --- a/apis/elasticache/v1alpha1/zz_generated.resolvers.go +++ b/apis/elasticache/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" v1alpha11 "kubedb.dev/provider-aws/apis/kms/v1alpha1" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/elasticache/v1alpha1/zz_generated_terraformed.go b/apis/elasticache/v1alpha1/zz_generated_terraformed.go index e96ddef..bb1222f 100755 --- a/apis/elasticache/v1alpha1/zz_generated_terraformed.go +++ b/apis/elasticache/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Cluster @@ -69,6 +74,46 @@ func (tr *Cluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Cluster +func (tr *Cluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Cluster +func (tr *Cluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Cluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Cluster) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *ParameterGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ParameterGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ParameterGroup) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *ReplicationGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ReplicationGroup +func (tr *ReplicationGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ReplicationGroup +func (tr *ReplicationGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ReplicationGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ReplicationGroup) LateInitialize(attrs []byte) (bool, error) { @@ -294,6 +419,46 @@ func (tr *SubnetGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SubnetGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SubnetGroup) LateInitialize(attrs []byte) (bool, error) { @@ -368,6 +533,46 @@ func (tr *User) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this User +func (tr *User) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this User +func (tr *User) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this User using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *User) LateInitialize(attrs []byte) (bool, error) { @@ -442,6 +647,46 @@ func (tr *UserGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this UserGroup +func (tr *UserGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this UserGroup +func (tr *UserGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this UserGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *UserGroup) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/elasticache/v1alpha1/zz_groupversion_info.go b/apis/elasticache/v1alpha1/zz_groupversion_info.go index fb5106e..9c30af5 100755 --- a/apis/elasticache/v1alpha1/zz_groupversion_info.go +++ b/apis/elasticache/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/elasticache/v1alpha1/zz_parametergroup_types.go b/apis/elasticache/v1alpha1/zz_parametergroup_types.go index 1cdbc9a..17a5545 100755 --- a/apis/elasticache/v1alpha1/zz_parametergroup_types.go +++ b/apis/elasticache/v1alpha1/zz_parametergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,27 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ParameterGroupInitParameters struct { + + // The description of the ElastiCache parameter group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // The family of the ElastiCache parameter group. + Family *string `json:"family,omitempty" tf:"family,omitempty"` + + // The name of the ElastiCache parameter group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // A list of ElastiCache parameters to apply. + Parameter []ParameterInitParameters `json:"parameter,omitempty" tf:"parameter,omitempty"` + + // Key-value mapping of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ParameterGroupObservation struct { // The AWS ARN associated with the parameter group. @@ -72,6 +97,15 @@ type ParameterGroupParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ParameterInitParameters struct { + + // The name of the ElastiCache parameter group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The value of the ElastiCache parameter. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type ParameterObservation struct { // The name of the ElastiCache parameter group. @@ -84,11 +118,11 @@ type ParameterObservation struct { type ParameterParameters struct { // The name of the ElastiCache parameter group. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The value of the ElastiCache parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -96,6 +130,17 @@ type ParameterParameters struct { type ParameterGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ParameterGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ParameterGroupInitParameters `json:"initProvider,omitempty"` } // ParameterGroupStatus defines the observed state of ParameterGroup. @@ -116,9 +161,9 @@ type ParameterGroupStatus struct { type ParameterGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family)",message="family is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.name)",message="name is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.family) || (has(self.initProvider) && has(self.initProvider.family))",message="spec.forProvider.family is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ParameterGroupSpec `json:"spec"` Status ParameterGroupStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_replicationgroup_types.go b/apis/elasticache/v1alpha1/zz_replicationgroup_types.go index 2926897..da27716 100755 --- a/apis/elasticache/v1alpha1/zz_replicationgroup_types.go +++ b/apis/elasticache/v1alpha1/zz_replicationgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,123 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ReplicationGroupInitParameters struct { + + // Specifies whether any modifications are applied immediately, or during the next maintenance window. Default is false. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // Whether to enable encryption at rest. + AtRestEncryptionEnabled *bool `json:"atRestEncryptionEnabled,omitempty" tf:"at_rest_encryption_enabled,omitempty"` + + // Specifies whether minor version engine upgrades will be applied automatically to the underlying Cache Cluster instances during the maintenance window. + // Only supported for engine type "redis" and if the engine version is 6 or higher. + // Defaults to true. + AutoMinorVersionUpgrade *string `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // Specifies whether a read-only replica will be automatically promoted to read/write primary if the existing primary fails. If enabled, num_cache_clusters must be greater than 1. Must be enabled for Redis (cluster mode enabled) replication groups. Defaults to false. + AutomaticFailoverEnabled *bool `json:"automaticFailoverEnabled,omitempty" tf:"automatic_failover_enabled,omitempty"` + + // Enables data tiering. Data tiering is only supported for replication groups using the r6gd node type. This parameter must be set to true when using r6gd nodes. + DataTieringEnabled *bool `json:"dataTieringEnabled,omitempty" tf:"data_tiering_enabled,omitempty"` + + // created description for the replication group. Must not be empty. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Name of the cache engine to be used for the clusters in this replication group. The only valid value is redis. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Version number of the cache engine to be used for the cache clusters in this replication group. + // If the version is 6 or higher, the major and minor version can be set, e.g., 6.2, + // or the minor version can be unspecified which will use the latest version at creation time, e.g., 6.x. + // Otherwise, specify the full version desired, e.g., 5.0.6. + // The actual engine version used is returned in the attribute engine_version_actual, see Attributes Reference below. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // The name of your final node group (shard) snapshot. ElastiCache creates the snapshot from the primary node in the cluster. If omitted, no final snapshot will be made. + FinalSnapshotIdentifier *string `json:"finalSnapshotIdentifier,omitempty" tf:"final_snapshot_identifier,omitempty"` + + // The ID of the global replication group to which this replication group should belong. If this parameter is specified, the replication group is added to the specified global replication group as a secondary replication group; otherwise, the replication group is not part of any global replication group. If global_replication_group_id is set, the num_node_groups parameter cannot be set. + GlobalReplicationGroupID *string `json:"globalReplicationGroupId,omitempty" tf:"global_replication_group_id,omitempty"` + + // Specifies the destination and format of Redis SLOWLOG or Redis Engine Log. See the documentation on Amazon ElastiCache. See Log Delivery Configuration below for more details. + LogDeliveryConfiguration []ReplicationGroupLogDeliveryConfigurationInitParameters `json:"logDeliveryConfiguration,omitempty" tf:"log_delivery_configuration,omitempty"` + + // ddd:hh24:mi (24H Clock UTC). The minimum maintenance window is a 60 minute period. Example: sun:05:00-sun:09:00 + MaintenanceWindow *string `json:"maintenanceWindow,omitempty" tf:"maintenance_window,omitempty"` + + // Specifies whether to enable Multi-AZ Support for the replication group. If true, automatic_failover_enabled must also be enabled. Defaults to false. + MultiAzEnabled *bool `json:"multiAzEnabled,omitempty" tf:"multi_az_enabled,omitempty"` + + // Instance class to be used. See AWS documentation for information on supported node types and guidance on selecting node types. Required unless global_replication_group_id is set. Cannot be set if global_replication_group_id is set. + NodeType *string `json:"nodeType,omitempty" tf:"node_type,omitempty"` + + // east-1:012345678999:my_sns_topic + NotificationTopicArn *string `json:"notificationTopicArn,omitempty" tf:"notification_topic_arn,omitempty"` + + // 00#. + NumCacheClusters *float64 `json:"numCacheClusters,omitempty" tf:"num_cache_clusters,omitempty"` + + // Number of node groups (shards) for this Redis replication group. + // Changing this number will trigger a resizing operation before other settings modifications. + NumNodeGroups *float64 `json:"numNodeGroups,omitempty" tf:"num_node_groups,omitempty"` + + // Name of the parameter group to associate with this replication group. If this argument is omitted, the default cache parameter group for the specified engine is used. To enable "cluster mode", i.e., data sharding, use a parameter group that has the parameter cluster-enabled set to true. + ParameterGroupName *string `json:"parameterGroupName,omitempty" tf:"parameter_group_name,omitempty"` + + // – Port number on which each of the cache nodes will accept connections. For Memcache the default is 11211, and for Redis the default port is 6379. + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // List of EC2 availability zones in which the replication group's cache clusters will be created. The order of the availability zones in the list is considered. The first item in the list will be the primary node. Ignored when updating. + PreferredCacheClusterAzs []*string `json:"preferredCacheClusterAzs,omitempty" tf:"preferred_cache_cluster_azs,omitempty"` + + // Number of replica nodes in each node group. + // Changing this number will trigger a resizing operation before other settings modifications. + // Valid values are 0 to 5. + ReplicasPerNodeGroup *float64 `json:"replicasPerNodeGroup,omitempty" tf:"replicas_per_node_group,omitempty"` + + // List of cache security group names to associate with this replication group. + SecurityGroupNames []*string `json:"securityGroupNames,omitempty" tf:"security_group_names,omitempty"` + + // – List of ARNs that identify Redis RDB snapshot files stored in Amazon S3. The names object names cannot contain any commas. + SnapshotArns []*string `json:"snapshotArns,omitempty" tf:"snapshot_arns,omitempty"` + + // Name of a snapshot from which to restore data into the new node group. Changing the snapshot_name forces a new resource. + SnapshotName *string `json:"snapshotName,omitempty" tf:"snapshot_name,omitempty"` + + // Number of days for which ElastiCache will retain automatic cache cluster snapshots before deleting them. For example, if you set SnapshotRetentionLimit to 5, then a snapshot that was taken today will be retained for 5 days before being deleted. If the value of snapshot_retention_limit is set to zero (0), backups are turned off. Please note that setting a snapshot_retention_limit is not supported on cache.t1.micro cache nodes + SnapshotRetentionLimit *float64 `json:"snapshotRetentionLimit,omitempty" tf:"snapshot_retention_limit,omitempty"` + + // Daily time range (in UTC) during which ElastiCache will begin taking a daily snapshot of your cache cluster. The minimum snapshot window is a 60 minute period. Example: 05:00-09:00 + SnapshotWindow *string `json:"snapshotWindow,omitempty" tf:"snapshot_window,omitempty"` + + // Map of tags to assign to the resource. Adding tags to this resource will add or overwrite any existing tags on the clusters in the replication group and not to the group itself. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Whether to enable encryption in transit. + TransitEncryptionEnabled *bool `json:"transitEncryptionEnabled,omitempty" tf:"transit_encryption_enabled,omitempty"` + + // User Group ID to associate with the replication group. Only a maximum of one (1) user group ID is valid. NOTE: This argument is a set because the AWS specification allows for multiple IDs. However, in practice, AWS only allows a maximum size of one. + UserGroupIds []*string `json:"userGroupIds,omitempty" tf:"user_group_ids,omitempty"` +} + +type ReplicationGroupLogDeliveryConfigurationInitParameters struct { + + // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. + Destination *string `json:"destination,omitempty" tf:"destination,omitempty"` + + // For CloudWatch Logs use cloudwatch-logs or for Kinesis Data Firehose use kinesis-firehose. + DestinationType *string `json:"destinationType,omitempty" tf:"destination_type,omitempty"` + + // Valid values are json or text + LogFormat *string `json:"logFormat,omitempty" tf:"log_format,omitempty"` + + // Valid values are slow-log or engine-log. Max 1 of each. + LogType *string `json:"logType,omitempty" tf:"log_type,omitempty"` +} + type ReplicationGroupLogDeliveryConfigurationObservation struct { // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. @@ -31,19 +152,19 @@ type ReplicationGroupLogDeliveryConfigurationObservation struct { type ReplicationGroupLogDeliveryConfigurationParameters struct { // Name of either the CloudWatch Logs LogGroup or Kinesis Data Firehose resource. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Destination *string `json:"destination" tf:"destination,omitempty"` // For CloudWatch Logs use cloudwatch-logs or for Kinesis Data Firehose use kinesis-firehose. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional DestinationType *string `json:"destinationType" tf:"destination_type,omitempty"` // Valid values are json or text - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional LogFormat *string `json:"logFormat" tf:"log_format,omitempty"` // Valid values are slow-log or engine-log. Max 1 of each. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional LogType *string `json:"logType" tf:"log_type,omitempty"` } @@ -368,6 +489,17 @@ type ReplicationGroupParameters struct { type ReplicationGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ReplicationGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ReplicationGroupInitParameters `json:"initProvider,omitempty"` } // ReplicationGroupStatus defines the observed state of ReplicationGroup. @@ -388,7 +520,7 @@ type ReplicationGroupStatus struct { type ReplicationGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ReplicationGroupSpec `json:"spec"` Status ReplicationGroupStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_subnetgroup_types.go b/apis/elasticache/v1alpha1/zz_subnetgroup_types.go index 6e01bf9..ea2d02e 100755 --- a/apis/elasticache/v1alpha1/zz_subnetgroup_types.go +++ b/apis/elasticache/v1alpha1/zz_subnetgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SubnetGroupInitParameters struct { + + // – Description for the cache subnet group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SubnetGroupObservation struct { Arn *string `json:"arn,omitempty" tf:"arn,omitempty"` @@ -70,6 +86,17 @@ type SubnetGroupParameters struct { type SubnetGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SubnetGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SubnetGroupInitParameters `json:"initProvider,omitempty"` } // SubnetGroupStatus defines the observed state of SubnetGroup. @@ -90,7 +117,7 @@ type SubnetGroupStatus struct { type SubnetGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SubnetGroupSpec `json:"spec"` Status SubnetGroupStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_user_types.go b/apis/elasticache/v1alpha1/zz_user_types.go index f6d6dfd..a1631d3 100755 --- a/apis/elasticache/v1alpha1/zz_user_types.go +++ b/apis/elasticache/v1alpha1/zz_user_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type AuthenticationModeInitParameters struct { + + // Specifies the authentication type. Possible options are: password, no-password-required or iam. + Type *string `json:"type,omitempty" tf:"type,omitempty"` +} + type AuthenticationModeObservation struct { PasswordCount *float64 `json:"passwordCount,omitempty" tf:"password_count,omitempty"` @@ -27,10 +37,33 @@ type AuthenticationModeParameters struct { PasswordsSecretRef *[]v1.SecretKeySelector `json:"passwordsSecretRef,omitempty" tf:"-"` // Specifies the authentication type. Possible options are: password, no-password-required or iam. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Type *string `json:"type" tf:"type,omitempty"` } +type UserInitParameters struct { + + // Access permissions string used for this user. See Specifying Permissions Using an Access String for more details. + AccessString *string `json:"accessString,omitempty" tf:"access_string,omitempty"` + + // Denotes the user's authentication properties. Detailed below. + AuthenticationMode []AuthenticationModeInitParameters `json:"authenticationMode,omitempty" tf:"authentication_mode,omitempty"` + + // The current supported value is REDIS. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Indicates a password is not required for this user. + NoPasswordRequired *bool `json:"noPasswordRequired,omitempty" tf:"no_password_required,omitempty"` + + // A list of tags to be added to this resource. A tag is a key-value pair. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // The username of the user. + UserName *string `json:"userName,omitempty" tf:"user_name,omitempty"` +} + type UserObservation struct { // Access permissions string used for this user. See Specifying Permissions Using an Access String for more details. @@ -102,6 +135,17 @@ type UserParameters struct { type UserSpec struct { v1.ResourceSpec `json:",inline"` ForProvider UserParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider UserInitParameters `json:"initProvider,omitempty"` } // UserStatus defines the observed state of User. @@ -122,10 +166,10 @@ type UserStatus struct { type User struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.accessString)",message="accessString is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine)",message="engine is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.userName)",message="userName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.accessString) || (has(self.initProvider) && has(self.initProvider.accessString))",message="spec.forProvider.accessString is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.userName) || (has(self.initProvider) && has(self.initProvider.userName))",message="spec.forProvider.userName is a required parameter" Spec UserSpec `json:"spec"` Status UserStatus `json:"status,omitempty"` } diff --git a/apis/elasticache/v1alpha1/zz_usergroup_types.go b/apis/elasticache/v1alpha1/zz_usergroup_types.go index c1f7900..5e0f9f4 100755 --- a/apis/elasticache/v1alpha1/zz_usergroup_types.go +++ b/apis/elasticache/v1alpha1/zz_usergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type UserGroupInitParameters struct { + + // The current supported value is REDIS. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type UserGroupObservation struct { // The ARN that identifies the user group. @@ -73,6 +89,17 @@ type UserGroupParameters struct { type UserGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider UserGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider UserGroupInitParameters `json:"initProvider,omitempty"` } // UserGroupStatus defines the observed state of UserGroup. @@ -93,8 +120,8 @@ type UserGroupStatus struct { type UserGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine)",message="engine is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec UserGroupSpec `json:"spec"` Status UserGroupStatus `json:"status,omitempty"` } diff --git a/apis/elasticsearch/v1alpha1/zz_domain_types.go b/apis/elasticsearch/v1alpha1/zz_domain_types.go index b5b6305..41eac60 100755 --- a/apis/elasticsearch/v1alpha1/zz_domain_types.go +++ b/apis/elasticsearch/v1alpha1/zz_domain_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type AdvancedSecurityOptionsInitParameters struct { + + // Whether advanced security is enabled. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Whether the internal user database is enabled. If not set, defaults to false by the AWS API. + InternalUserDatabaseEnabled *bool `json:"internalUserDatabaseEnabled,omitempty" tf:"internal_user_database_enabled,omitempty"` + + // Configuration block for the main user. Detailed below. + MasterUserOptions []MasterUserOptionsInitParameters `json:"masterUserOptions,omitempty" tf:"master_user_options,omitempty"` +} + type AdvancedSecurityOptionsObservation struct { // Whether advanced security is enabled. @@ -28,7 +44,7 @@ type AdvancedSecurityOptionsObservation struct { type AdvancedSecurityOptionsParameters struct { // Whether advanced security is enabled. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` // Whether the internal user database is enabled. If not set, defaults to false by the AWS API. @@ -40,6 +56,18 @@ type AdvancedSecurityOptionsParameters struct { MasterUserOptions []MasterUserOptionsParameters `json:"masterUserOptions,omitempty" tf:"master_user_options,omitempty"` } +type AutoTuneOptionsInitParameters struct { + + // The Auto-Tune desired state for the domain. Valid values: ENABLED or DISABLED. + DesiredState *string `json:"desiredState,omitempty" tf:"desired_state,omitempty"` + + // Configuration block for Auto-Tune maintenance windows. Can be specified multiple times for each maintenance window. Detailed below. + MaintenanceSchedule []MaintenanceScheduleInitParameters `json:"maintenanceSchedule,omitempty" tf:"maintenance_schedule,omitempty"` + + // Whether to roll back to default Auto-Tune settings when disabling Auto-Tune. Valid values: DEFAULT_ROLLBACK or NO_ROLLBACK. + RollbackOnDisable *string `json:"rollbackOnDisable,omitempty" tf:"rollback_on_disable,omitempty"` +} + type AutoTuneOptionsObservation struct { // The Auto-Tune desired state for the domain. Valid values: ENABLED or DISABLED. @@ -55,7 +83,7 @@ type AutoTuneOptionsObservation struct { type AutoTuneOptionsParameters struct { // The Auto-Tune desired state for the domain. Valid values: ENABLED or DISABLED. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional DesiredState *string `json:"desiredState" tf:"desired_state,omitempty"` // Configuration block for Auto-Tune maintenance windows. Can be specified multiple times for each maintenance window. Detailed below. @@ -67,6 +95,42 @@ type AutoTuneOptionsParameters struct { RollbackOnDisable *string `json:"rollbackOnDisable,omitempty" tf:"rollback_on_disable,omitempty"` } +type ClusterConfigInitParameters struct { + + // Configuration block containing cold storage configuration. Detailed below. + ColdStorageOptions []ColdStorageOptionsInitParameters `json:"coldStorageOptions,omitempty" tf:"cold_storage_options,omitempty"` + + // Number of dedicated main nodes in the cluster. + DedicatedMasterCount *float64 `json:"dedicatedMasterCount,omitempty" tf:"dedicated_master_count,omitempty"` + + // Whether dedicated main nodes are enabled for the cluster. + DedicatedMasterEnabled *bool `json:"dedicatedMasterEnabled,omitempty" tf:"dedicated_master_enabled,omitempty"` + + // Instance type of the dedicated main nodes in the cluster. + DedicatedMasterType *string `json:"dedicatedMasterType,omitempty" tf:"dedicated_master_type,omitempty"` + + // Number of instances in the cluster. + InstanceCount *float64 `json:"instanceCount,omitempty" tf:"instance_count,omitempty"` + + // Instance type of data nodes in the cluster. + InstanceType *string `json:"instanceType,omitempty" tf:"instance_type,omitempty"` + + // Number of warm nodes in the cluster. Valid values are between 2 and 150. warm_count can be only and must be set when warm_enabled is set to true. + WarmCount *float64 `json:"warmCount,omitempty" tf:"warm_count,omitempty"` + + // Whether to enable warm storage. + WarmEnabled *bool `json:"warmEnabled,omitempty" tf:"warm_enabled,omitempty"` + + // Instance type for the Elasticsearch cluster's warm nodes. Valid values are ultrawarm1.medium.elasticsearch, ultrawarm1.large.elasticsearch and ultrawarm1.xlarge.elasticsearch. warm_type can be only and must be set when warm_enabled is set to true. + WarmType *string `json:"warmType,omitempty" tf:"warm_type,omitempty"` + + // Configuration block containing zone awareness settings. Detailed below. + ZoneAwarenessConfig []ZoneAwarenessConfigInitParameters `json:"zoneAwarenessConfig,omitempty" tf:"zone_awareness_config,omitempty"` + + // Whether zone awareness is enabled, set to true for multi-az deployment. To enable awareness with three Availability Zones, the availability_zone_count within the zone_awareness_config must be set to 3. + ZoneAwarenessEnabled *bool `json:"zoneAwarenessEnabled,omitempty" tf:"zone_awareness_enabled,omitempty"` +} + type ClusterConfigObservation struct { // Configuration block containing cold storage configuration. Detailed below. @@ -150,6 +214,21 @@ type ClusterConfigParameters struct { ZoneAwarenessEnabled *bool `json:"zoneAwarenessEnabled,omitempty" tf:"zone_awareness_enabled,omitempty"` } +type CognitoOptionsInitParameters struct { + + // Whether Amazon Cognito authentication with Kibana is enabled or not. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // ID of the Cognito Identity Pool to use. + IdentityPoolID *string `json:"identityPoolId,omitempty" tf:"identity_pool_id,omitempty"` + + // ARN of the IAM role that has the AmazonESCognitoAccess policy attached. + RoleArn *string `json:"roleArn,omitempty" tf:"role_arn,omitempty"` + + // ID of the Cognito User Pool to use. + UserPoolID *string `json:"userPoolId,omitempty" tf:"user_pool_id,omitempty"` +} + type CognitoOptionsObservation struct { // Whether Amazon Cognito authentication with Kibana is enabled or not. @@ -172,18 +251,24 @@ type CognitoOptionsParameters struct { Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` // ID of the Cognito Identity Pool to use. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional IdentityPoolID *string `json:"identityPoolId" tf:"identity_pool_id,omitempty"` // ARN of the IAM role that has the AmazonESCognitoAccess policy attached. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional RoleArn *string `json:"roleArn" tf:"role_arn,omitempty"` // ID of the Cognito User Pool to use. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional UserPoolID *string `json:"userPoolId" tf:"user_pool_id,omitempty"` } +type ColdStorageOptionsInitParameters struct { + + // Boolean to enable cold storage for an Elasticsearch domain. Defaults to false. Master and ultrawarm nodes must be enabled for cold storage. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type ColdStorageOptionsObservation struct { // Boolean to enable cold storage for an Elasticsearch domain. Defaults to false. Master and ultrawarm nodes must be enabled for cold storage. @@ -197,6 +282,24 @@ type ColdStorageOptionsParameters struct { Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` } +type DomainEndpointOptionsInitParameters struct { + + // Fully qualified domain for your custom endpoint. + CustomEndpoint *string `json:"customEndpoint,omitempty" tf:"custom_endpoint,omitempty"` + + // ACM certificate ARN for your custom endpoint. + CustomEndpointCertificateArn *string `json:"customEndpointCertificateArn,omitempty" tf:"custom_endpoint_certificate_arn,omitempty"` + + // Whether to enable custom endpoint for the Elasticsearch domain. + CustomEndpointEnabled *bool `json:"customEndpointEnabled,omitempty" tf:"custom_endpoint_enabled,omitempty"` + + // Whether or not to require HTTPS. Defaults to true. + EnforceHTTPS *bool `json:"enforceHttps,omitempty" tf:"enforce_https,omitempty"` + + // Name of the TLS security policy that needs to be applied to the HTTPS endpoint. Valid values: Policy-Min-TLS-1-0-2019-07 and Policy-Min-TLS-1-2-2019-07. + TLSSecurityPolicy *string `json:"tlsSecurityPolicy,omitempty" tf:"tls_security_policy,omitempty"` +} + type DomainEndpointOptionsObservation struct { // Fully qualified domain for your custom endpoint. @@ -238,6 +341,57 @@ type DomainEndpointOptionsParameters struct { TLSSecurityPolicy *string `json:"tlsSecurityPolicy,omitempty" tf:"tls_security_policy,omitempty"` } +type DomainInitParameters struct { + + // IAM policy document specifying the access policies for the domain. + AccessPolicies *string `json:"accessPolicies,omitempty" tf:"access_policies,omitempty"` + + // Key-value string pairs to specify advanced configuration options. + AdvancedOptions map[string]*string `json:"advancedOptions,omitempty" tf:"advanced_options,omitempty"` + + // Configuration block for fine-grained access control. Detailed below. + AdvancedSecurityOptions []AdvancedSecurityOptionsInitParameters `json:"advancedSecurityOptions,omitempty" tf:"advanced_security_options,omitempty"` + + // Configuration block for the Auto-Tune options of the domain. Detailed below. + AutoTuneOptions []AutoTuneOptionsInitParameters `json:"autoTuneOptions,omitempty" tf:"auto_tune_options,omitempty"` + + // Configuration block for the cluster of the domain. Detailed below. + ClusterConfig []ClusterConfigInitParameters `json:"clusterConfig,omitempty" tf:"cluster_config,omitempty"` + + // Configuration block for authenticating Kibana with Cognito. Detailed below. + CognitoOptions []CognitoOptionsInitParameters `json:"cognitoOptions,omitempty" tf:"cognito_options,omitempty"` + + // Configuration block for domain endpoint HTTP(S) related options. Detailed below. + DomainEndpointOptions []DomainEndpointOptionsInitParameters `json:"domainEndpointOptions,omitempty" tf:"domain_endpoint_options,omitempty"` + + // Configuration block for EBS related options, may be required based on chosen instance size. Detailed below. + EBSOptions []EBSOptionsInitParameters `json:"ebsOptions,omitempty" tf:"ebs_options,omitempty"` + + // Version of Elasticsearch to deploy. Defaults to 1.5. + ElasticsearchVersion *string `json:"elasticsearchVersion,omitempty" tf:"elasticsearch_version,omitempty"` + + // Configuration block for encrypt at rest options. Only available for certain instance types. Detailed below. + EncryptAtRest []EncryptAtRestInitParameters `json:"encryptAtRest,omitempty" tf:"encrypt_at_rest,omitempty"` + + // Configuration block for publishing slow and application logs to CloudWatch Logs. This block can be declared multiple times, for each log_type, within the same resource. Detailed below. + LogPublishingOptions []LogPublishingOptionsInitParameters `json:"logPublishingOptions,omitempty" tf:"log_publishing_options,omitempty"` + + // Configuration block for node-to-node encryption options. Detailed below. + NodeToNodeEncryption []NodeToNodeEncryptionInitParameters `json:"nodeToNodeEncryption,omitempty" tf:"node_to_node_encryption,omitempty"` + + // Configuration block for snapshot related options. Detailed below. DEPRECATED. For domains running Elasticsearch 5.3 and later, Amazon ES takes hourly automated snapshots, making this setting irrelevant. For domains running earlier versions of Elasticsearch, Amazon ES takes daily automated snapshots. + SnapshotOptions []SnapshotOptionsInitParameters `json:"snapshotOptions,omitempty" tf:"snapshot_options,omitempty"` + + // Map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Configuration block for VPC related options. Adding or removing this configuration forces a new resource (documentation). Detailed below. + VPCOptions []VPCOptionsInitParameters `json:"vpcOptions,omitempty" tf:"vpc_options,omitempty"` +} + type DomainObservation struct { // IAM policy document specifying the access policies for the domain. @@ -375,6 +529,15 @@ type DomainParameters struct { VPCOptions []VPCOptionsParameters `json:"vpcOptions,omitempty" tf:"vpc_options,omitempty"` } +type DurationInitParameters struct { + + // The unit of time specifying the duration of an Auto-Tune maintenance window. Valid values: HOURS. + Unit *string `json:"unit,omitempty" tf:"unit,omitempty"` + + // An integer specifying the value of the duration of an Auto-Tune maintenance window. + Value *float64 `json:"value,omitempty" tf:"value,omitempty"` +} + type DurationObservation struct { // The unit of time specifying the duration of an Auto-Tune maintenance window. Valid values: HOURS. @@ -387,14 +550,32 @@ type DurationObservation struct { type DurationParameters struct { // The unit of time specifying the duration of an Auto-Tune maintenance window. Valid values: HOURS. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Unit *string `json:"unit" tf:"unit,omitempty"` // An integer specifying the value of the duration of an Auto-Tune maintenance window. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *float64 `json:"value" tf:"value,omitempty"` } +type EBSOptionsInitParameters struct { + + // Whether EBS volumes are attached to data nodes in the domain. + EBSEnabled *bool `json:"ebsEnabled,omitempty" tf:"ebs_enabled,omitempty"` + + // Baseline input/output (I/O) performance of EBS volumes attached to data nodes. Applicable only for the GP3 and Provisioned IOPS EBS volume types. + Iops *float64 `json:"iops,omitempty" tf:"iops,omitempty"` + + // Specifies the throughput (in MiB/s) of the EBS volumes attached to data nodes. Applicable only for the gp3 volume type. + Throughput *float64 `json:"throughput,omitempty" tf:"throughput,omitempty"` + + // Size of EBS volumes attached to data nodes (in GiB). + VolumeSize *float64 `json:"volumeSize,omitempty" tf:"volume_size,omitempty"` + + // Type of EBS volumes attached to data nodes. + VolumeType *string `json:"volumeType,omitempty" tf:"volume_type,omitempty"` +} + type EBSOptionsObservation struct { // Whether EBS volumes are attached to data nodes in the domain. @@ -416,7 +597,7 @@ type EBSOptionsObservation struct { type EBSOptionsParameters struct { // Whether EBS volumes are attached to data nodes in the domain. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional EBSEnabled *bool `json:"ebsEnabled" tf:"ebs_enabled,omitempty"` // Baseline input/output (I/O) performance of EBS volumes attached to data nodes. Applicable only for the GP3 and Provisioned IOPS EBS volume types. @@ -436,6 +617,15 @@ type EBSOptionsParameters struct { VolumeType *string `json:"volumeType,omitempty" tf:"volume_type,omitempty"` } +type EncryptAtRestInitParameters struct { + + // Whether to enable encryption at rest. If the encrypt_at_rest block is not provided then this defaults to false. Enabling encryption on new domains requires elasticsearch_version 5.1 or greater. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // KMS key ARN to encrypt the Elasticsearch domain with. If not specified then it defaults to using the aws/es service KMS key. Note that KMS will accept a KMS key ID but will return the key ARN. + KMSKeyID *string `json:"kmsKeyId,omitempty" tf:"kms_key_id,omitempty"` +} + type EncryptAtRestObservation struct { // Whether to enable encryption at rest. If the encrypt_at_rest block is not provided then this defaults to false. Enabling encryption on new domains requires elasticsearch_version 5.1 or greater. @@ -448,7 +638,7 @@ type EncryptAtRestObservation struct { type EncryptAtRestParameters struct { // Whether to enable encryption at rest. If the encrypt_at_rest block is not provided then this defaults to false. Enabling encryption on new domains requires elasticsearch_version 5.1 or greater. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` // KMS key ARN to encrypt the Elasticsearch domain with. If not specified then it defaults to using the aws/es service KMS key. Note that KMS will accept a KMS key ID but will return the key ARN. @@ -456,6 +646,18 @@ type EncryptAtRestParameters struct { KMSKeyID *string `json:"kmsKeyId,omitempty" tf:"kms_key_id,omitempty"` } +type LogPublishingOptionsInitParameters struct { + + // ARN of the Cloudwatch log group to which log needs to be published. + CloudwatchLogGroupArn *string `json:"cloudwatchLogGroupArn,omitempty" tf:"cloudwatch_log_group_arn,omitempty"` + + // Whether given log publishing option is enabled or not. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Type of Elasticsearch log. Valid values: INDEX_SLOW_LOGS, SEARCH_SLOW_LOGS, ES_APPLICATION_LOGS, AUDIT_LOGS. + LogType *string `json:"logType,omitempty" tf:"log_type,omitempty"` +} + type LogPublishingOptionsObservation struct { // ARN of the Cloudwatch log group to which log needs to be published. @@ -471,7 +673,7 @@ type LogPublishingOptionsObservation struct { type LogPublishingOptionsParameters struct { // ARN of the Cloudwatch log group to which log needs to be published. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional CloudwatchLogGroupArn *string `json:"cloudwatchLogGroupArn" tf:"cloudwatch_log_group_arn,omitempty"` // Whether given log publishing option is enabled or not. @@ -479,10 +681,22 @@ type LogPublishingOptionsParameters struct { Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` // Type of Elasticsearch log. Valid values: INDEX_SLOW_LOGS, SEARCH_SLOW_LOGS, ES_APPLICATION_LOGS, AUDIT_LOGS. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional LogType *string `json:"logType" tf:"log_type,omitempty"` } +type MaintenanceScheduleInitParameters struct { + + // A cron expression specifying the recurrence pattern for an Auto-Tune maintenance schedule. + CronExpressionForRecurrence *string `json:"cronExpressionForRecurrence,omitempty" tf:"cron_expression_for_recurrence,omitempty"` + + // Configuration block for the duration of the Auto-Tune maintenance window. Detailed below. + Duration []DurationInitParameters `json:"duration,omitempty" tf:"duration,omitempty"` + + // Date and time at which to start the Auto-Tune maintenance schedule in RFC3339 format. + StartAt *string `json:"startAt,omitempty" tf:"start_at,omitempty"` +} + type MaintenanceScheduleObservation struct { // A cron expression specifying the recurrence pattern for an Auto-Tune maintenance schedule. @@ -498,18 +712,27 @@ type MaintenanceScheduleObservation struct { type MaintenanceScheduleParameters struct { // A cron expression specifying the recurrence pattern for an Auto-Tune maintenance schedule. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional CronExpressionForRecurrence *string `json:"cronExpressionForRecurrence" tf:"cron_expression_for_recurrence,omitempty"` // Configuration block for the duration of the Auto-Tune maintenance window. Detailed below. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Duration []DurationParameters `json:"duration" tf:"duration,omitempty"` // Date and time at which to start the Auto-Tune maintenance schedule in RFC3339 format. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional StartAt *string `json:"startAt" tf:"start_at,omitempty"` } +type MasterUserOptionsInitParameters struct { + + // ARN for the main user. Only specify if internal_user_database_enabled is not set or set to false. + MasterUserArn *string `json:"masterUserArn,omitempty" tf:"master_user_arn,omitempty"` + + // Main user's username, which is stored in the Amazon Elasticsearch Service domain's internal database. Only specify if internal_user_database_enabled is set to true. + MasterUserName *string `json:"masterUserName,omitempty" tf:"master_user_name,omitempty"` +} + type MasterUserOptionsObservation struct { // ARN for the main user. Only specify if internal_user_database_enabled is not set or set to false. @@ -534,6 +757,12 @@ type MasterUserOptionsParameters struct { MasterUserPasswordSecretRef *v1.SecretKeySelector `json:"masterUserPasswordSecretRef,omitempty" tf:"-"` } +type NodeToNodeEncryptionInitParameters struct { + + // Whether to enable node-to-node encryption. If the node_to_node_encryption block is not provided then this defaults to false. Enabling node-to-node encryption of a new domain requires an elasticsearch_version of 6.0 or greater. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type NodeToNodeEncryptionObservation struct { // Whether to enable node-to-node encryption. If the node_to_node_encryption block is not provided then this defaults to false. Enabling node-to-node encryption of a new domain requires an elasticsearch_version of 6.0 or greater. @@ -543,10 +772,16 @@ type NodeToNodeEncryptionObservation struct { type NodeToNodeEncryptionParameters struct { // Whether to enable node-to-node encryption. If the node_to_node_encryption block is not provided then this defaults to false. Enabling node-to-node encryption of a new domain requires an elasticsearch_version of 6.0 or greater. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` } +type SnapshotOptionsInitParameters struct { + + // Hour during which the service takes an automated daily snapshot of the indices in the domain. + AutomatedSnapshotStartHour *float64 `json:"automatedSnapshotStartHour,omitempty" tf:"automated_snapshot_start_hour,omitempty"` +} + type SnapshotOptionsObservation struct { // Hour during which the service takes an automated daily snapshot of the indices in the domain. @@ -556,10 +791,19 @@ type SnapshotOptionsObservation struct { type SnapshotOptionsParameters struct { // Hour during which the service takes an automated daily snapshot of the indices in the domain. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional AutomatedSnapshotStartHour *float64 `json:"automatedSnapshotStartHour" tf:"automated_snapshot_start_hour,omitempty"` } +type VPCOptionsInitParameters struct { + + // List of VPC Security Group IDs to be applied to the Elasticsearch domain endpoints. If omitted, the default Security Group for the VPC will be used. + SecurityGroupIds []*string `json:"securityGroupIds,omitempty" tf:"security_group_ids,omitempty"` + + // List of VPC Subnet IDs for the Elasticsearch domain endpoints to be created in. + SubnetIds []*string `json:"subnetIds,omitempty" tf:"subnet_ids,omitempty"` +} + type VPCOptionsObservation struct { // If the domain was created inside a VPC, the names of the availability zones the configured subnet_ids were created inside. @@ -586,6 +830,12 @@ type VPCOptionsParameters struct { SubnetIds []*string `json:"subnetIds,omitempty" tf:"subnet_ids,omitempty"` } +type ZoneAwarenessConfigInitParameters struct { + + // Number of Availability Zones for the domain to use with zone_awareness_enabled. Defaults to 2. Valid values: 2 or 3. + AvailabilityZoneCount *float64 `json:"availabilityZoneCount,omitempty" tf:"availability_zone_count,omitempty"` +} + type ZoneAwarenessConfigObservation struct { // Number of Availability Zones for the domain to use with zone_awareness_enabled. Defaults to 2. Valid values: 2 or 3. @@ -603,6 +853,17 @@ type ZoneAwarenessConfigParameters struct { type DomainSpec struct { v1.ResourceSpec `json:",inline"` ForProvider DomainParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider DomainInitParameters `json:"initProvider,omitempty"` } // DomainStatus defines the observed state of Domain. @@ -623,7 +884,7 @@ type DomainStatus struct { type Domain struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec DomainSpec `json:"spec"` Status DomainStatus `json:"status,omitempty"` } diff --git a/apis/elasticsearch/v1alpha1/zz_domainpolicy_types.go b/apis/elasticsearch/v1alpha1/zz_domainpolicy_types.go index fc73485..a87c0b7 100755 --- a/apis/elasticsearch/v1alpha1/zz_domainpolicy_types.go +++ b/apis/elasticsearch/v1alpha1/zz_domainpolicy_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type DomainPolicyInitParameters struct { + + // IAM policy document specifying the access policies for the domain + AccessPolicies *string `json:"accessPolicies,omitempty" tf:"access_policies,omitempty"` +} + type DomainPolicyObservation struct { // IAM policy document specifying the access policies for the domain @@ -53,6 +63,17 @@ type DomainPolicyParameters struct { type DomainPolicySpec struct { v1.ResourceSpec `json:",inline"` ForProvider DomainPolicyParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider DomainPolicyInitParameters `json:"initProvider,omitempty"` } // DomainPolicyStatus defines the observed state of DomainPolicy. @@ -73,8 +94,8 @@ type DomainPolicyStatus struct { type DomainPolicy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.accessPolicies)",message="accessPolicies is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.accessPolicies) || (has(self.initProvider) && has(self.initProvider.accessPolicies))",message="spec.forProvider.accessPolicies is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec DomainPolicySpec `json:"spec"` Status DomainPolicyStatus `json:"status,omitempty"` } diff --git a/apis/elasticsearch/v1alpha1/zz_domainsamloptions_types.go b/apis/elasticsearch/v1alpha1/zz_domainsamloptions_types.go index e5361b6..7d43172 100755 --- a/apis/elasticsearch/v1alpha1/zz_domainsamloptions_types.go +++ b/apis/elasticsearch/v1alpha1/zz_domainsamloptions_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,12 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type DomainSAMLOptionsInitParameters struct { + + // The SAML authentication options for an AWS Elasticsearch Domain. + SAMLOptions []SAMLOptionsInitParameters `json:"samlOptions,omitempty" tf:"saml_options,omitempty"` +} + type DomainSAMLOptionsObservation struct { // The name of the domain the SAML options are associated with. @@ -34,6 +44,15 @@ type DomainSAMLOptionsParameters struct { SAMLOptions []SAMLOptionsParameters `json:"samlOptions,omitempty" tf:"saml_options,omitempty"` } +type IdpInitParameters struct { + + // The unique Entity ID of the application in SAML Identity Provider. + EntityID *string `json:"entityId,omitempty" tf:"entity_id,omitempty"` + + // The Metadata of the SAML application in xml format. + MetadataContent *string `json:"metadataContent,omitempty" tf:"metadata_content,omitempty"` +} + type IdpObservation struct { // The unique Entity ID of the application in SAML Identity Provider. @@ -46,14 +65,35 @@ type IdpObservation struct { type IdpParameters struct { // The unique Entity ID of the application in SAML Identity Provider. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional EntityID *string `json:"entityId" tf:"entity_id,omitempty"` // The Metadata of the SAML application in xml format. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional MetadataContent *string `json:"metadataContent" tf:"metadata_content,omitempty"` } +type SAMLOptionsInitParameters struct { + + // Whether SAML authentication is enabled. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Information from your identity provider. + Idp []IdpInitParameters `json:"idp,omitempty" tf:"idp,omitempty"` + + // This backend role from the SAML IdP receives full permissions to the cluster, equivalent to a new master user. + MasterBackendRole *string `json:"masterBackendRole,omitempty" tf:"master_backend_role,omitempty"` + + // Element of the SAML assertion to use for backend roles. Default is roles. + RolesKey *string `json:"rolesKey,omitempty" tf:"roles_key,omitempty"` + + // Duration of a session in minutes after a user logs in. Default is 60. Maximum value is 1,440. + SessionTimeoutMinutes *float64 `json:"sessionTimeoutMinutes,omitempty" tf:"session_timeout_minutes,omitempty"` + + // Custom SAML attribute to use for user names. Default is an empty string - "". This will cause Elasticsearch to use the NameID element of the Subject, which is the default location for name identifiers in the SAML specification. + SubjectKey *string `json:"subjectKey,omitempty" tf:"subject_key,omitempty"` +} + type SAMLOptionsObservation struct { // Whether SAML authentication is enabled. @@ -110,6 +150,17 @@ type SAMLOptionsParameters struct { type DomainSAMLOptionsSpec struct { v1.ResourceSpec `json:",inline"` ForProvider DomainSAMLOptionsParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider DomainSAMLOptionsInitParameters `json:"initProvider,omitempty"` } // DomainSAMLOptionsStatus defines the observed state of DomainSAMLOptions. @@ -130,7 +181,7 @@ type DomainSAMLOptionsStatus struct { type DomainSAMLOptions struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec DomainSAMLOptionsSpec `json:"spec"` Status DomainSAMLOptionsStatus `json:"status,omitempty"` } diff --git a/apis/elasticsearch/v1alpha1/zz_generated.deepcopy.go b/apis/elasticsearch/v1alpha1/zz_generated.deepcopy.go index 6fd67bd..ec0f4ee 100644 --- a/apis/elasticsearch/v1alpha1/zz_generated.deepcopy.go +++ b/apis/elasticsearch/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,38 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AdvancedSecurityOptionsInitParameters) DeepCopyInto(out *AdvancedSecurityOptionsInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.InternalUserDatabaseEnabled != nil { + in, out := &in.InternalUserDatabaseEnabled, &out.InternalUserDatabaseEnabled + *out = new(bool) + **out = **in + } + if in.MasterUserOptions != nil { + in, out := &in.MasterUserOptions, &out.MasterUserOptions + *out = make([]MasterUserOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AdvancedSecurityOptionsInitParameters. +func (in *AdvancedSecurityOptionsInitParameters) DeepCopy() *AdvancedSecurityOptionsInitParameters { + if in == nil { + return nil + } + out := new(AdvancedSecurityOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AdvancedSecurityOptionsObservation) DeepCopyInto(out *AdvancedSecurityOptionsObservation) { *out = *in @@ -78,6 +109,38 @@ func (in *AdvancedSecurityOptionsParameters) DeepCopy() *AdvancedSecurityOptions return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AutoTuneOptionsInitParameters) DeepCopyInto(out *AutoTuneOptionsInitParameters) { + *out = *in + if in.DesiredState != nil { + in, out := &in.DesiredState, &out.DesiredState + *out = new(string) + **out = **in + } + if in.MaintenanceSchedule != nil { + in, out := &in.MaintenanceSchedule, &out.MaintenanceSchedule + *out = make([]MaintenanceScheduleInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.RollbackOnDisable != nil { + in, out := &in.RollbackOnDisable, &out.RollbackOnDisable + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutoTuneOptionsInitParameters. +func (in *AutoTuneOptionsInitParameters) DeepCopy() *AutoTuneOptionsInitParameters { + if in == nil { + return nil + } + out := new(AutoTuneOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AutoTuneOptionsObservation) DeepCopyInto(out *AutoTuneOptionsObservation) { *out = *in @@ -142,6 +205,80 @@ func (in *AutoTuneOptionsParameters) DeepCopy() *AutoTuneOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterConfigInitParameters) DeepCopyInto(out *ClusterConfigInitParameters) { + *out = *in + if in.ColdStorageOptions != nil { + in, out := &in.ColdStorageOptions, &out.ColdStorageOptions + *out = make([]ColdStorageOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.DedicatedMasterCount != nil { + in, out := &in.DedicatedMasterCount, &out.DedicatedMasterCount + *out = new(float64) + **out = **in + } + if in.DedicatedMasterEnabled != nil { + in, out := &in.DedicatedMasterEnabled, &out.DedicatedMasterEnabled + *out = new(bool) + **out = **in + } + if in.DedicatedMasterType != nil { + in, out := &in.DedicatedMasterType, &out.DedicatedMasterType + *out = new(string) + **out = **in + } + if in.InstanceCount != nil { + in, out := &in.InstanceCount, &out.InstanceCount + *out = new(float64) + **out = **in + } + if in.InstanceType != nil { + in, out := &in.InstanceType, &out.InstanceType + *out = new(string) + **out = **in + } + if in.WarmCount != nil { + in, out := &in.WarmCount, &out.WarmCount + *out = new(float64) + **out = **in + } + if in.WarmEnabled != nil { + in, out := &in.WarmEnabled, &out.WarmEnabled + *out = new(bool) + **out = **in + } + if in.WarmType != nil { + in, out := &in.WarmType, &out.WarmType + *out = new(string) + **out = **in + } + if in.ZoneAwarenessConfig != nil { + in, out := &in.ZoneAwarenessConfig, &out.ZoneAwarenessConfig + *out = make([]ZoneAwarenessConfigInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ZoneAwarenessEnabled != nil { + in, out := &in.ZoneAwarenessEnabled, &out.ZoneAwarenessEnabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterConfigInitParameters. +func (in *ClusterConfigInitParameters) DeepCopy() *ClusterConfigInitParameters { + if in == nil { + return nil + } + out := new(ClusterConfigInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterConfigObservation) DeepCopyInto(out *ClusterConfigObservation) { *out = *in @@ -290,6 +427,41 @@ func (in *ClusterConfigParameters) DeepCopy() *ClusterConfigParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CognitoOptionsInitParameters) DeepCopyInto(out *CognitoOptionsInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.IdentityPoolID != nil { + in, out := &in.IdentityPoolID, &out.IdentityPoolID + *out = new(string) + **out = **in + } + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn + *out = new(string) + **out = **in + } + if in.UserPoolID != nil { + in, out := &in.UserPoolID, &out.UserPoolID + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CognitoOptionsInitParameters. +func (in *CognitoOptionsInitParameters) DeepCopy() *CognitoOptionsInitParameters { + if in == nil { + return nil + } + out := new(CognitoOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *CognitoOptionsObservation) DeepCopyInto(out *CognitoOptionsObservation) { *out = *in @@ -360,6 +532,26 @@ func (in *CognitoOptionsParameters) DeepCopy() *CognitoOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ColdStorageOptionsInitParameters) DeepCopyInto(out *ColdStorageOptionsInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ColdStorageOptionsInitParameters. +func (in *ColdStorageOptionsInitParameters) DeepCopy() *ColdStorageOptionsInitParameters { + if in == nil { + return nil + } + out := new(ColdStorageOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ColdStorageOptionsObservation) DeepCopyInto(out *ColdStorageOptionsObservation) { *out = *in @@ -427,6 +619,46 @@ func (in *Domain) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DomainEndpointOptionsInitParameters) DeepCopyInto(out *DomainEndpointOptionsInitParameters) { + *out = *in + if in.CustomEndpoint != nil { + in, out := &in.CustomEndpoint, &out.CustomEndpoint + *out = new(string) + **out = **in + } + if in.CustomEndpointCertificateArn != nil { + in, out := &in.CustomEndpointCertificateArn, &out.CustomEndpointCertificateArn + *out = new(string) + **out = **in + } + if in.CustomEndpointEnabled != nil { + in, out := &in.CustomEndpointEnabled, &out.CustomEndpointEnabled + *out = new(bool) + **out = **in + } + if in.EnforceHTTPS != nil { + in, out := &in.EnforceHTTPS, &out.EnforceHTTPS + *out = new(bool) + **out = **in + } + if in.TLSSecurityPolicy != nil { + in, out := &in.TLSSecurityPolicy, &out.TLSSecurityPolicy + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainEndpointOptionsInitParameters. +func (in *DomainEndpointOptionsInitParameters) DeepCopy() *DomainEndpointOptionsInitParameters { + if in == nil { + return nil + } + out := new(DomainEndpointOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DomainEndpointOptionsObservation) DeepCopyInto(out *DomainEndpointOptionsObservation) { *out = *in @@ -507,6 +739,156 @@ func (in *DomainEndpointOptionsParameters) DeepCopy() *DomainEndpointOptionsPara return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DomainInitParameters) DeepCopyInto(out *DomainInitParameters) { + *out = *in + if in.AccessPolicies != nil { + in, out := &in.AccessPolicies, &out.AccessPolicies + *out = new(string) + **out = **in + } + if in.AdvancedOptions != nil { + in, out := &in.AdvancedOptions, &out.AdvancedOptions + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.AdvancedSecurityOptions != nil { + in, out := &in.AdvancedSecurityOptions, &out.AdvancedSecurityOptions + *out = make([]AdvancedSecurityOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.AutoTuneOptions != nil { + in, out := &in.AutoTuneOptions, &out.AutoTuneOptions + *out = make([]AutoTuneOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ClusterConfig != nil { + in, out := &in.ClusterConfig, &out.ClusterConfig + *out = make([]ClusterConfigInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.CognitoOptions != nil { + in, out := &in.CognitoOptions, &out.CognitoOptions + *out = make([]CognitoOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.DomainEndpointOptions != nil { + in, out := &in.DomainEndpointOptions, &out.DomainEndpointOptions + *out = make([]DomainEndpointOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.EBSOptions != nil { + in, out := &in.EBSOptions, &out.EBSOptions + *out = make([]EBSOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ElasticsearchVersion != nil { + in, out := &in.ElasticsearchVersion, &out.ElasticsearchVersion + *out = new(string) + **out = **in + } + if in.EncryptAtRest != nil { + in, out := &in.EncryptAtRest, &out.EncryptAtRest + *out = make([]EncryptAtRestInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.LogPublishingOptions != nil { + in, out := &in.LogPublishingOptions, &out.LogPublishingOptions + *out = make([]LogPublishingOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.NodeToNodeEncryption != nil { + in, out := &in.NodeToNodeEncryption, &out.NodeToNodeEncryption + *out = make([]NodeToNodeEncryptionInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.SnapshotOptions != nil { + in, out := &in.SnapshotOptions, &out.SnapshotOptions + *out = make([]SnapshotOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.VPCOptions != nil { + in, out := &in.VPCOptions, &out.VPCOptions + *out = make([]VPCOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainInitParameters. +func (in *DomainInitParameters) DeepCopy() *DomainInitParameters { + if in == nil { + return nil + } + out := new(DomainInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DomainList) DeepCopyInto(out *DomainList) { *out = *in @@ -555,7 +937,8 @@ func (in *DomainObservation) DeepCopyInto(out *DomainObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -670,7 +1053,8 @@ func (in *DomainObservation) DeepCopyInto(out *DomainObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -685,7 +1069,8 @@ func (in *DomainObservation) DeepCopyInto(out *DomainObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -727,7 +1112,8 @@ func (in *DomainParameters) DeepCopyInto(out *DomainParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -822,7 +1208,8 @@ func (in *DomainParameters) DeepCopyInto(out *DomainParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -837,7 +1224,8 @@ func (in *DomainParameters) DeepCopyInto(out *DomainParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -890,6 +1278,26 @@ func (in *DomainPolicy) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DomainPolicyInitParameters) DeepCopyInto(out *DomainPolicyInitParameters) { + *out = *in + if in.AccessPolicies != nil { + in, out := &in.AccessPolicies, &out.AccessPolicies + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainPolicyInitParameters. +func (in *DomainPolicyInitParameters) DeepCopy() *DomainPolicyInitParameters { + if in == nil { + return nil + } + out := new(DomainPolicyInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DomainPolicyList) DeepCopyInto(out *DomainPolicyList) { *out = *in @@ -997,6 +1405,7 @@ func (in *DomainPolicySpec) DeepCopyInto(out *DomainPolicySpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainPolicySpec. @@ -1053,6 +1462,28 @@ func (in *DomainSAMLOptions) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DomainSAMLOptionsInitParameters) DeepCopyInto(out *DomainSAMLOptionsInitParameters) { + *out = *in + if in.SAMLOptions != nil { + in, out := &in.SAMLOptions, &out.SAMLOptions + *out = make([]SAMLOptionsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainSAMLOptionsInitParameters. +func (in *DomainSAMLOptionsInitParameters) DeepCopy() *DomainSAMLOptionsInitParameters { + if in == nil { + return nil + } + out := new(DomainSAMLOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DomainSAMLOptionsList) DeepCopyInto(out *DomainSAMLOptionsList) { *out = *in @@ -1144,6 +1575,7 @@ func (in *DomainSAMLOptionsSpec) DeepCopyInto(out *DomainSAMLOptionsSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainSAMLOptionsSpec. @@ -1178,6 +1610,7 @@ func (in *DomainSpec) DeepCopyInto(out *DomainSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DomainSpec. @@ -1207,6 +1640,31 @@ func (in *DomainStatus) DeepCopy() *DomainStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DurationInitParameters) DeepCopyInto(out *DurationInitParameters) { + *out = *in + if in.Unit != nil { + in, out := &in.Unit, &out.Unit + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DurationInitParameters. +func (in *DurationInitParameters) DeepCopy() *DurationInitParameters { + if in == nil { + return nil + } + out := new(DurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DurationObservation) DeepCopyInto(out *DurationObservation) { *out = *in @@ -1240,19 +1698,59 @@ func (in *DurationParameters) DeepCopyInto(out *DurationParameters) { *out = new(string) **out = **in } - if in.Value != nil { - in, out := &in.Value, &out.Value + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DurationParameters. +func (in *DurationParameters) DeepCopy() *DurationParameters { + if in == nil { + return nil + } + out := new(DurationParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EBSOptionsInitParameters) DeepCopyInto(out *EBSOptionsInitParameters) { + *out = *in + if in.EBSEnabled != nil { + in, out := &in.EBSEnabled, &out.EBSEnabled + *out = new(bool) + **out = **in + } + if in.Iops != nil { + in, out := &in.Iops, &out.Iops + *out = new(float64) + **out = **in + } + if in.Throughput != nil { + in, out := &in.Throughput, &out.Throughput + *out = new(float64) + **out = **in + } + if in.VolumeSize != nil { + in, out := &in.VolumeSize, &out.VolumeSize *out = new(float64) **out = **in } + if in.VolumeType != nil { + in, out := &in.VolumeType, &out.VolumeType + *out = new(string) + **out = **in + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DurationParameters. -func (in *DurationParameters) DeepCopy() *DurationParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EBSOptionsInitParameters. +func (in *EBSOptionsInitParameters) DeepCopy() *EBSOptionsInitParameters { if in == nil { return nil } - out := new(DurationParameters) + out := new(EBSOptionsInitParameters) in.DeepCopyInto(out) return out } @@ -1337,6 +1835,31 @@ func (in *EBSOptionsParameters) DeepCopy() *EBSOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EncryptAtRestInitParameters) DeepCopyInto(out *EncryptAtRestInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EncryptAtRestInitParameters. +func (in *EncryptAtRestInitParameters) DeepCopy() *EncryptAtRestInitParameters { + if in == nil { + return nil + } + out := new(EncryptAtRestInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EncryptAtRestObservation) DeepCopyInto(out *EncryptAtRestObservation) { *out = *in @@ -1387,6 +1910,31 @@ func (in *EncryptAtRestParameters) DeepCopy() *EncryptAtRestParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *IdpInitParameters) DeepCopyInto(out *IdpInitParameters) { + *out = *in + if in.EntityID != nil { + in, out := &in.EntityID, &out.EntityID + *out = new(string) + **out = **in + } + if in.MetadataContent != nil { + in, out := &in.MetadataContent, &out.MetadataContent + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IdpInitParameters. +func (in *IdpInitParameters) DeepCopy() *IdpInitParameters { + if in == nil { + return nil + } + out := new(IdpInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IdpObservation) DeepCopyInto(out *IdpObservation) { *out = *in @@ -1437,6 +1985,36 @@ func (in *IdpParameters) DeepCopy() *IdpParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *LogPublishingOptionsInitParameters) DeepCopyInto(out *LogPublishingOptionsInitParameters) { + *out = *in + if in.CloudwatchLogGroupArn != nil { + in, out := &in.CloudwatchLogGroupArn, &out.CloudwatchLogGroupArn + *out = new(string) + **out = **in + } + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.LogType != nil { + in, out := &in.LogType, &out.LogType + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LogPublishingOptionsInitParameters. +func (in *LogPublishingOptionsInitParameters) DeepCopy() *LogPublishingOptionsInitParameters { + if in == nil { + return nil + } + out := new(LogPublishingOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LogPublishingOptionsObservation) DeepCopyInto(out *LogPublishingOptionsObservation) { *out = *in @@ -1497,6 +2075,38 @@ func (in *LogPublishingOptionsParameters) DeepCopy() *LogPublishingOptionsParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MaintenanceScheduleInitParameters) DeepCopyInto(out *MaintenanceScheduleInitParameters) { + *out = *in + if in.CronExpressionForRecurrence != nil { + in, out := &in.CronExpressionForRecurrence, &out.CronExpressionForRecurrence + *out = new(string) + **out = **in + } + if in.Duration != nil { + in, out := &in.Duration, &out.Duration + *out = make([]DurationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.StartAt != nil { + in, out := &in.StartAt, &out.StartAt + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MaintenanceScheduleInitParameters. +func (in *MaintenanceScheduleInitParameters) DeepCopy() *MaintenanceScheduleInitParameters { + if in == nil { + return nil + } + out := new(MaintenanceScheduleInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MaintenanceScheduleObservation) DeepCopyInto(out *MaintenanceScheduleObservation) { *out = *in @@ -1561,6 +2171,31 @@ func (in *MaintenanceScheduleParameters) DeepCopy() *MaintenanceScheduleParamete return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MasterUserOptionsInitParameters) DeepCopyInto(out *MasterUserOptionsInitParameters) { + *out = *in + if in.MasterUserArn != nil { + in, out := &in.MasterUserArn, &out.MasterUserArn + *out = new(string) + **out = **in + } + if in.MasterUserName != nil { + in, out := &in.MasterUserName, &out.MasterUserName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MasterUserOptionsInitParameters. +func (in *MasterUserOptionsInitParameters) DeepCopy() *MasterUserOptionsInitParameters { + if in == nil { + return nil + } + out := new(MasterUserOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MasterUserOptionsObservation) DeepCopyInto(out *MasterUserOptionsObservation) { *out = *in @@ -1616,6 +2251,26 @@ func (in *MasterUserOptionsParameters) DeepCopy() *MasterUserOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *NodeToNodeEncryptionInitParameters) DeepCopyInto(out *NodeToNodeEncryptionInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeToNodeEncryptionInitParameters. +func (in *NodeToNodeEncryptionInitParameters) DeepCopy() *NodeToNodeEncryptionInitParameters { + if in == nil { + return nil + } + out := new(NodeToNodeEncryptionInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *NodeToNodeEncryptionObservation) DeepCopyInto(out *NodeToNodeEncryptionObservation) { *out = *in @@ -1656,6 +2311,53 @@ func (in *NodeToNodeEncryptionParameters) DeepCopy() *NodeToNodeEncryptionParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SAMLOptionsInitParameters) DeepCopyInto(out *SAMLOptionsInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.Idp != nil { + in, out := &in.Idp, &out.Idp + *out = make([]IdpInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.MasterBackendRole != nil { + in, out := &in.MasterBackendRole, &out.MasterBackendRole + *out = new(string) + **out = **in + } + if in.RolesKey != nil { + in, out := &in.RolesKey, &out.RolesKey + *out = new(string) + **out = **in + } + if in.SessionTimeoutMinutes != nil { + in, out := &in.SessionTimeoutMinutes, &out.SessionTimeoutMinutes + *out = new(float64) + **out = **in + } + if in.SubjectKey != nil { + in, out := &in.SubjectKey, &out.SubjectKey + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SAMLOptionsInitParameters. +func (in *SAMLOptionsInitParameters) DeepCopy() *SAMLOptionsInitParameters { + if in == nil { + return nil + } + out := new(SAMLOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SAMLOptionsObservation) DeepCopyInto(out *SAMLOptionsObservation) { *out = *in @@ -1755,6 +2457,26 @@ func (in *SAMLOptionsParameters) DeepCopy() *SAMLOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SnapshotOptionsInitParameters) DeepCopyInto(out *SnapshotOptionsInitParameters) { + *out = *in + if in.AutomatedSnapshotStartHour != nil { + in, out := &in.AutomatedSnapshotStartHour, &out.AutomatedSnapshotStartHour + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotOptionsInitParameters. +func (in *SnapshotOptionsInitParameters) DeepCopy() *SnapshotOptionsInitParameters { + if in == nil { + return nil + } + out := new(SnapshotOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SnapshotOptionsObservation) DeepCopyInto(out *SnapshotOptionsObservation) { *out = *in @@ -1795,6 +2517,43 @@ func (in *SnapshotOptionsParameters) DeepCopy() *SnapshotOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *VPCOptionsInitParameters) DeepCopyInto(out *VPCOptionsInitParameters) { + *out = *in + if in.SecurityGroupIds != nil { + in, out := &in.SecurityGroupIds, &out.SecurityGroupIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SubnetIds != nil { + in, out := &in.SubnetIds, &out.SubnetIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VPCOptionsInitParameters. +func (in *VPCOptionsInitParameters) DeepCopy() *VPCOptionsInitParameters { + if in == nil { + return nil + } + out := new(VPCOptionsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VPCOptionsObservation) DeepCopyInto(out *VPCOptionsObservation) { *out = *in @@ -1885,6 +2644,26 @@ func (in *VPCOptionsParameters) DeepCopy() *VPCOptionsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZoneAwarenessConfigInitParameters) DeepCopyInto(out *ZoneAwarenessConfigInitParameters) { + *out = *in + if in.AvailabilityZoneCount != nil { + in, out := &in.AvailabilityZoneCount, &out.AvailabilityZoneCount + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZoneAwarenessConfigInitParameters. +func (in *ZoneAwarenessConfigInitParameters) DeepCopy() *ZoneAwarenessConfigInitParameters { + if in == nil { + return nil + } + out := new(ZoneAwarenessConfigInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ZoneAwarenessConfigObservation) DeepCopyInto(out *ZoneAwarenessConfigObservation) { *out = *in diff --git a/apis/elasticsearch/v1alpha1/zz_generated.managed.go b/apis/elasticsearch/v1alpha1/zz_generated.managed.go index 4235d2f..1155c2b 100644 --- a/apis/elasticsearch/v1alpha1/zz_generated.managed.go +++ b/apis/elasticsearch/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Domain) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Domain. -func (mg *Domain) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Domain. +func (mg *Domain) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Domain. @@ -27,14 +27,6 @@ func (mg *Domain) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Domain. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Domain) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Domain. func (mg *Domain) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Domain) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Domain. -func (mg *Domain) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Domain. +func (mg *Domain) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Domain. @@ -65,14 +57,6 @@ func (mg *Domain) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Domain. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Domain) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Domain. func (mg *Domain) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *DomainPolicy) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this DomainPolicy. -func (mg *DomainPolicy) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this DomainPolicy. +func (mg *DomainPolicy) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this DomainPolicy. @@ -103,14 +87,6 @@ func (mg *DomainPolicy) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this DomainPolicy. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *DomainPolicy) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this DomainPolicy. func (mg *DomainPolicy) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *DomainPolicy) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this DomainPolicy. -func (mg *DomainPolicy) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this DomainPolicy. +func (mg *DomainPolicy) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this DomainPolicy. @@ -141,14 +117,6 @@ func (mg *DomainPolicy) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this DomainPolicy. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *DomainPolicy) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this DomainPolicy. func (mg *DomainPolicy) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *DomainSAMLOptions) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this DomainSAMLOptions. -func (mg *DomainSAMLOptions) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this DomainSAMLOptions. +func (mg *DomainSAMLOptions) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this DomainSAMLOptions. @@ -179,14 +147,6 @@ func (mg *DomainSAMLOptions) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this DomainSAMLOptions. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *DomainSAMLOptions) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this DomainSAMLOptions. func (mg *DomainSAMLOptions) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *DomainSAMLOptions) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this DomainSAMLOptions. -func (mg *DomainSAMLOptions) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this DomainSAMLOptions. +func (mg *DomainSAMLOptions) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this DomainSAMLOptions. @@ -217,14 +177,6 @@ func (mg *DomainSAMLOptions) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this DomainSAMLOptions. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *DomainSAMLOptions) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this DomainSAMLOptions. func (mg *DomainSAMLOptions) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/elasticsearch/v1alpha1/zz_generated_terraformed.go b/apis/elasticsearch/v1alpha1/zz_generated_terraformed.go index 8e58247..19fd6e3 100755 --- a/apis/elasticsearch/v1alpha1/zz_generated_terraformed.go +++ b/apis/elasticsearch/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Domain @@ -69,6 +74,46 @@ func (tr *Domain) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Domain +func (tr *Domain) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Domain +func (tr *Domain) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Domain using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Domain) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *DomainPolicy) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this DomainPolicy +func (tr *DomainPolicy) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this DomainPolicy +func (tr *DomainPolicy) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this DomainPolicy using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *DomainPolicy) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *DomainSAMLOptions) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this DomainSAMLOptions +func (tr *DomainSAMLOptions) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this DomainSAMLOptions +func (tr *DomainSAMLOptions) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this DomainSAMLOptions using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *DomainSAMLOptions) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/elasticsearch/v1alpha1/zz_groupversion_info.go b/apis/elasticsearch/v1alpha1/zz_groupversion_info.go index c38321d..f38eae5 100755 --- a/apis/elasticsearch/v1alpha1/zz_groupversion_info.go +++ b/apis/elasticsearch/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/generate.go b/apis/generate.go index 7dcd77d..233d170 100644 --- a/apis/generate.go +++ b/apis/generate.go @@ -19,7 +19,7 @@ Copyright 2021 Upbound Inc. //go:generate rm -rf ../examples-generated // Generate documentation from Terraform docs. -//go:generate go run github.com/upbound/upjet/cmd/scraper -n ${TERRAFORM_PROVIDER_SOURCE} -r ../.work/${TERRAFORM_PROVIDER_SOURCE}/${TERRAFORM_DOCS_PATH} -o ../config/provider-metadata.yaml +//go:generate go run github.com/crossplane/upjet/cmd/scraper -n ${TERRAFORM_PROVIDER_SOURCE} -r ../.work/${TERRAFORM_PROVIDER_SOURCE}/${TERRAFORM_DOCS_PATH} -o ../config/provider-metadata.yaml // Run Upjet generator //go:generate go run ../cmd/generator/main.go .. diff --git a/apis/kafka/v1alpha1/zz_cluster_types.go b/apis/kafka/v1alpha1/zz_cluster_types.go index 0603ee9..ae7d693 100755 --- a/apis/kafka/v1alpha1/zz_cluster_types.go +++ b/apis/kafka/v1alpha1/zz_cluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,14 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type BrokerLogsInitParameters struct { + CloudwatchLogs []CloudwatchLogsInitParameters `json:"cloudwatchLogs,omitempty" tf:"cloudwatch_logs,omitempty"` + + Firehose []FirehoseInitParameters `json:"firehose,omitempty" tf:"firehose,omitempty"` + + S3 []S3InitParameters `json:"s3,omitempty" tf:"s3,omitempty"` +} + type BrokerLogsObservation struct { CloudwatchLogs []CloudwatchLogsObservation `json:"cloudwatchLogs,omitempty" tf:"cloudwatch_logs,omitempty"` @@ -33,6 +45,21 @@ type BrokerLogsParameters struct { S3 []S3Parameters `json:"s3,omitempty" tf:"s3,omitempty"` } +type BrokerNodeGroupInfoInitParameters struct { + + // The distribution of broker nodes across availability zones (documentation). Currently the only valid value is DEFAULT. + AzDistribution *string `json:"azDistribution,omitempty" tf:"az_distribution,omitempty"` + + // Information about the cluster access configuration. See below. For security reasons, you can't turn on public access while creating an MSK cluster. However, you can update an existing cluster to make it publicly accessible. You can also create a new cluster and then update it to make it publicly accessible (documentation). + ConnectivityInfo []ConnectivityInfoInitParameters `json:"connectivityInfo,omitempty" tf:"connectivity_info,omitempty"` + + // Specify the instance type to use for the kafka brokersE.g., kafka.m5.large. (Pricing info) + InstanceType *string `json:"instanceType,omitempty" tf:"instance_type,omitempty"` + + // A block that contains information about storage volumes attached to MSK broker nodes. See below. + StorageInfo []StorageInfoInitParameters `json:"storageInfo,omitempty" tf:"storage_info,omitempty"` +} + type BrokerNodeGroupInfoObservation struct { // The distribution of broker nodes across availability zones (documentation). Currently the only valid value is DEFAULT. @@ -78,7 +105,7 @@ type BrokerNodeGroupInfoParameters struct { ConnectivityInfo []ConnectivityInfoParameters `json:"connectivityInfo,omitempty" tf:"connectivity_info,omitempty"` // Specify the instance type to use for the kafka brokersE.g., kafka.m5.large. (Pricing info) - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional InstanceType *string `json:"instanceType" tf:"instance_type,omitempty"` // A list of the security groups to associate with the elastic network interfaces to control who can communicate with the cluster. @@ -99,6 +126,18 @@ type BrokerNodeGroupInfoParameters struct { StorageInfo []StorageInfoParameters `json:"storageInfo,omitempty" tf:"storage_info,omitempty"` } +type ClientAuthenticationInitParameters struct { + + // Configuration block for specifying SASL client authentication. See below. + Sasl []SaslInitParameters `json:"sasl,omitempty" tf:"sasl,omitempty"` + + // Configuration block for specifying TLS client authentication. See below. + TLS []TLSInitParameters `json:"tls,omitempty" tf:"tls,omitempty"` + + // Enables unauthenticated access. + Unauthenticated *bool `json:"unauthenticated,omitempty" tf:"unauthenticated,omitempty"` +} + type ClientAuthenticationObservation struct { // Configuration block for specifying SASL client authentication. See below. @@ -126,6 +165,15 @@ type ClientAuthenticationParameters struct { Unauthenticated *bool `json:"unauthenticated,omitempty" tf:"unauthenticated,omitempty"` } +type CloudwatchLogsInitParameters struct { + + // Controls whether provisioned throughput is enabled or not. Default value: false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Name of the Cloudwatch Log Group to deliver logs to. + LogGroup *string `json:"logGroup,omitempty" tf:"log_group,omitempty"` +} + type CloudwatchLogsObservation struct { // Controls whether provisioned throughput is enabled or not. Default value: false. @@ -138,7 +186,7 @@ type CloudwatchLogsObservation struct { type CloudwatchLogsParameters struct { // Controls whether provisioned throughput is enabled or not. Default value: false. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` // Name of the Cloudwatch Log Group to deliver logs to. @@ -146,6 +194,48 @@ type CloudwatchLogsParameters struct { LogGroup *string `json:"logGroup,omitempty" tf:"log_group,omitempty"` } +type ClusterInitParameters struct { + + // Configuration block for the broker nodes of the Kafka cluster. + BrokerNodeGroupInfo []BrokerNodeGroupInfoInitParameters `json:"brokerNodeGroupInfo,omitempty" tf:"broker_node_group_info,omitempty"` + + // Configuration block for specifying a client authentication. See below. + ClientAuthentication []ClientAuthenticationInitParameters `json:"clientAuthentication,omitempty" tf:"client_authentication,omitempty"` + + // Name of the MSK cluster. + ClusterName *string `json:"clusterName,omitempty" tf:"cluster_name,omitempty"` + + // Configuration block for specifying a MSK Configuration to attach to Kafka brokers. See below. + ConfigurationInfo []ConfigurationInfoInitParameters `json:"configurationInfo,omitempty" tf:"configuration_info,omitempty"` + + // Configuration block for specifying encryption. See below. + EncryptionInfo []EncryptionInfoInitParameters `json:"encryptionInfo,omitempty" tf:"encryption_info,omitempty"` + + // Specify the desired enhanced MSK CloudWatch monitoring level. See Monitoring Amazon MSK with Amazon CloudWatch + EnhancedMonitoring *string `json:"enhancedMonitoring,omitempty" tf:"enhanced_monitoring,omitempty"` + + // Specify the desired Kafka software version. + KafkaVersion *string `json:"kafkaVersion,omitempty" tf:"kafka_version,omitempty"` + + // Configuration block for streaming broker logs to Cloudwatch/S3/Kinesis Firehose. See below. + LoggingInfo []LoggingInfoInitParameters `json:"loggingInfo,omitempty" tf:"logging_info,omitempty"` + + // The desired total number of broker nodes in the kafka cluster. It must be a multiple of the number of specified client subnets. + NumberOfBrokerNodes *float64 `json:"numberOfBrokerNodes,omitempty" tf:"number_of_broker_nodes,omitempty"` + + // Configuration block for JMX and Node monitoring for the MSK cluster. See below. + OpenMonitoring []OpenMonitoringInitParameters `json:"openMonitoring,omitempty" tf:"open_monitoring,omitempty"` + + // Controls storage mode for supported storage tiers. Valid values are: LOCAL or TIERED. + StorageMode *string `json:"storageMode,omitempty" tf:"storage_mode,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterObservation struct { // Amazon Resource Name (ARN) of the MSK Configuration to use in the cluster. @@ -283,6 +373,15 @@ type ClusterParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ConfigurationInfoInitParameters struct { + + // Amazon Resource Name (ARN) of the MSK Configuration to use in the cluster. + Arn *string `json:"arn,omitempty" tf:"arn,omitempty"` + + // Revision of the MSK Configuration to use in the cluster. + Revision *float64 `json:"revision,omitempty" tf:"revision,omitempty"` +} + type ConfigurationInfoObservation struct { // Amazon Resource Name (ARN) of the MSK Configuration to use in the cluster. @@ -295,14 +394,20 @@ type ConfigurationInfoObservation struct { type ConfigurationInfoParameters struct { // Amazon Resource Name (ARN) of the MSK Configuration to use in the cluster. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Arn *string `json:"arn" tf:"arn,omitempty"` // Revision of the MSK Configuration to use in the cluster. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Revision *float64 `json:"revision" tf:"revision,omitempty"` } +type ConnectivityInfoInitParameters struct { + + // Access control settings for brokers. See below. + PublicAccess []PublicAccessInitParameters `json:"publicAccess,omitempty" tf:"public_access,omitempty"` +} + type ConnectivityInfoObservation struct { // Access control settings for brokers. See below. @@ -316,6 +421,15 @@ type ConnectivityInfoParameters struct { PublicAccess []PublicAccessParameters `json:"publicAccess,omitempty" tf:"public_access,omitempty"` } +type EBSStorageInfoInitParameters struct { + + // A block that contains EBS volume provisioned throughput information. To provision storage throughput, you must choose broker type kafka.m5.4xlarge or larger. See below. + ProvisionedThroughput []ProvisionedThroughputInitParameters `json:"provisionedThroughput,omitempty" tf:"provisioned_throughput,omitempty"` + + // The size in GiB of the EBS volume for the data drive on each broker node. Minimum value of 1 and maximum value of 16384. + VolumeSize *float64 `json:"volumeSize,omitempty" tf:"volume_size,omitempty"` +} + type EBSStorageInfoObservation struct { // A block that contains EBS volume provisioned throughput information. To provision storage throughput, you must choose broker type kafka.m5.4xlarge or larger. See below. @@ -336,6 +450,15 @@ type EBSStorageInfoParameters struct { VolumeSize *float64 `json:"volumeSize,omitempty" tf:"volume_size,omitempty"` } +type EncryptionInTransitInitParameters struct { + + // Encryption setting for data in transit between clients and brokers. Valid values: TLS, TLS_PLAINTEXT, and PLAINTEXT. Default value is TLS. + ClientBroker *string `json:"clientBroker,omitempty" tf:"client_broker,omitempty"` + + // Whether data communication among broker nodes is encrypted. Default value: true. + InCluster *bool `json:"inCluster,omitempty" tf:"in_cluster,omitempty"` +} + type EncryptionInTransitObservation struct { // Encryption setting for data in transit between clients and brokers. Valid values: TLS, TLS_PLAINTEXT, and PLAINTEXT. Default value is TLS. @@ -356,6 +479,12 @@ type EncryptionInTransitParameters struct { InCluster *bool `json:"inCluster,omitempty" tf:"in_cluster,omitempty"` } +type EncryptionInfoInitParameters struct { + + // Configuration block to specify encryption in transit. See below. + EncryptionInTransit []EncryptionInTransitInitParameters `json:"encryptionInTransit,omitempty" tf:"encryption_in_transit,omitempty"` +} + type EncryptionInfoObservation struct { // The ARN of the KMS key used for encryption at rest of the broker data volumes. @@ -386,6 +515,15 @@ type EncryptionInfoParameters struct { EncryptionInTransit []EncryptionInTransitParameters `json:"encryptionInTransit,omitempty" tf:"encryption_in_transit,omitempty"` } +type FirehoseInitParameters struct { + + // Name of the Kinesis Data Firehose delivery stream to deliver logs to. + DeliveryStream *string `json:"deliveryStream,omitempty" tf:"delivery_stream,omitempty"` + + // Controls whether provisioned throughput is enabled or not. Default value: false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type FirehoseObservation struct { // Name of the Kinesis Data Firehose delivery stream to deliver logs to. @@ -402,10 +540,16 @@ type FirehoseParameters struct { DeliveryStream *string `json:"deliveryStream,omitempty" tf:"delivery_stream,omitempty"` // Controls whether provisioned throughput is enabled or not. Default value: false. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` } +type JmxExporterInitParameters struct { + + // Indicates whether you want to enable or disable the JMX Exporter. + EnabledInBroker *bool `json:"enabledInBroker,omitempty" tf:"enabled_in_broker,omitempty"` +} + type JmxExporterObservation struct { // Indicates whether you want to enable or disable the JMX Exporter. @@ -415,10 +559,16 @@ type JmxExporterObservation struct { type JmxExporterParameters struct { // Indicates whether you want to enable or disable the JMX Exporter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional EnabledInBroker *bool `json:"enabledInBroker" tf:"enabled_in_broker,omitempty"` } +type LoggingInfoInitParameters struct { + + // Configuration block for Broker Logs settings for logging info. See below. + BrokerLogs []BrokerLogsInitParameters `json:"brokerLogs,omitempty" tf:"broker_logs,omitempty"` +} + type LoggingInfoObservation struct { // Configuration block for Broker Logs settings for logging info. See below. @@ -428,10 +578,16 @@ type LoggingInfoObservation struct { type LoggingInfoParameters struct { // Configuration block for Broker Logs settings for logging info. See below. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional BrokerLogs []BrokerLogsParameters `json:"brokerLogs" tf:"broker_logs,omitempty"` } +type NodeExporterInitParameters struct { + + // Indicates whether you want to enable or disable the JMX Exporter. + EnabledInBroker *bool `json:"enabledInBroker,omitempty" tf:"enabled_in_broker,omitempty"` +} + type NodeExporterObservation struct { // Indicates whether you want to enable or disable the JMX Exporter. @@ -441,10 +597,16 @@ type NodeExporterObservation struct { type NodeExporterParameters struct { // Indicates whether you want to enable or disable the JMX Exporter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional EnabledInBroker *bool `json:"enabledInBroker" tf:"enabled_in_broker,omitempty"` } +type OpenMonitoringInitParameters struct { + + // Configuration block for Prometheus settings for open monitoring. See below. + Prometheus []PrometheusInitParameters `json:"prometheus,omitempty" tf:"prometheus,omitempty"` +} + type OpenMonitoringObservation struct { // Configuration block for Prometheus settings for open monitoring. See below. @@ -454,10 +616,19 @@ type OpenMonitoringObservation struct { type OpenMonitoringParameters struct { // Configuration block for Prometheus settings for open monitoring. See below. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Prometheus []PrometheusParameters `json:"prometheus" tf:"prometheus,omitempty"` } +type PrometheusInitParameters struct { + + // Configuration block for JMX Exporter. See below. + JmxExporter []JmxExporterInitParameters `json:"jmxExporter,omitempty" tf:"jmx_exporter,omitempty"` + + // Configuration block for Node Exporter. See below. + NodeExporter []NodeExporterInitParameters `json:"nodeExporter,omitempty" tf:"node_exporter,omitempty"` +} + type PrometheusObservation struct { // Configuration block for JMX Exporter. See below. @@ -478,6 +649,15 @@ type PrometheusParameters struct { NodeExporter []NodeExporterParameters `json:"nodeExporter,omitempty" tf:"node_exporter,omitempty"` } +type ProvisionedThroughputInitParameters struct { + + // Controls whether provisioned throughput is enabled or not. Default value: false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Throughput value of the EBS volumes for the data drive on each kafka broker node in MiB per second. The minimum value is 250. The maximum value varies between broker type. You can refer to the valid values for the maximum volume throughput at the following documentation on throughput bottlenecks + VolumeThroughput *float64 `json:"volumeThroughput,omitempty" tf:"volume_throughput,omitempty"` +} + type ProvisionedThroughputObservation struct { // Controls whether provisioned throughput is enabled or not. Default value: false. @@ -498,6 +678,12 @@ type ProvisionedThroughputParameters struct { VolumeThroughput *float64 `json:"volumeThroughput,omitempty" tf:"volume_throughput,omitempty"` } +type PublicAccessInitParameters struct { + + // Public access type. Valida values: DISABLED, SERVICE_PROVIDED_EIPS. + Type *string `json:"type,omitempty" tf:"type,omitempty"` +} + type PublicAccessObservation struct { // Public access type. Valida values: DISABLED, SERVICE_PROVIDED_EIPS. @@ -511,6 +697,18 @@ type PublicAccessParameters struct { Type *string `json:"type,omitempty" tf:"type,omitempty"` } +type S3InitParameters struct { + + // Name of the S3 bucket to deliver logs to. + Bucket *string `json:"bucket,omitempty" tf:"bucket,omitempty"` + + // Controls whether provisioned throughput is enabled or not. Default value: false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // Prefix to append to the folder name. + Prefix *string `json:"prefix,omitempty" tf:"prefix,omitempty"` +} + type S3Observation struct { // Name of the S3 bucket to deliver logs to. @@ -530,7 +728,7 @@ type S3Parameters struct { Bucket *string `json:"bucket,omitempty" tf:"bucket,omitempty"` // Controls whether provisioned throughput is enabled or not. Default value: false. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Enabled *bool `json:"enabled" tf:"enabled,omitempty"` // Prefix to append to the folder name. @@ -538,6 +736,15 @@ type S3Parameters struct { Prefix *string `json:"prefix,omitempty" tf:"prefix,omitempty"` } +type SaslInitParameters struct { + + // Enables IAM client authentication. Defaults to false. + IAM *bool `json:"iam,omitempty" tf:"iam,omitempty"` + + // Enables SCRAM client authentication via AWS Secrets Manager. Defaults to false. + Scram *bool `json:"scram,omitempty" tf:"scram,omitempty"` +} + type SaslObservation struct { // Enables IAM client authentication. Defaults to false. @@ -558,6 +765,12 @@ type SaslParameters struct { Scram *bool `json:"scram,omitempty" tf:"scram,omitempty"` } +type StorageInfoInitParameters struct { + + // A block that contains EBS volume information. See below. + EBSStorageInfo []EBSStorageInfoInitParameters `json:"ebsStorageInfo,omitempty" tf:"ebs_storage_info,omitempty"` +} + type StorageInfoObservation struct { // A block that contains EBS volume information. See below. @@ -571,6 +784,12 @@ type StorageInfoParameters struct { EBSStorageInfo []EBSStorageInfoParameters `json:"ebsStorageInfo,omitempty" tf:"ebs_storage_info,omitempty"` } +type TLSInitParameters struct { + + // List of ACM Certificate Authority Amazon Resource Names (ARNs). + CertificateAuthorityArns []*string `json:"certificateAuthorityArns,omitempty" tf:"certificate_authority_arns,omitempty"` +} + type TLSObservation struct { // List of ACM Certificate Authority Amazon Resource Names (ARNs). @@ -588,6 +807,17 @@ type TLSParameters struct { type ClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInitParameters `json:"initProvider,omitempty"` } // ClusterStatus defines the observed state of Cluster. @@ -608,11 +838,11 @@ type ClusterStatus struct { type Cluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.brokerNodeGroupInfo)",message="brokerNodeGroupInfo is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.clusterName)",message="clusterName is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.kafkaVersion)",message="kafkaVersion is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.numberOfBrokerNodes)",message="numberOfBrokerNodes is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.brokerNodeGroupInfo) || (has(self.initProvider) && has(self.initProvider.brokerNodeGroupInfo))",message="spec.forProvider.brokerNodeGroupInfo is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterName) || (has(self.initProvider) && has(self.initProvider.clusterName))",message="spec.forProvider.clusterName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.kafkaVersion) || (has(self.initProvider) && has(self.initProvider.kafkaVersion))",message="spec.forProvider.kafkaVersion is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.numberOfBrokerNodes) || (has(self.initProvider) && has(self.initProvider.numberOfBrokerNodes))",message="spec.forProvider.numberOfBrokerNodes is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSpec `json:"spec"` Status ClusterStatus `json:"status,omitempty"` } diff --git a/apis/kafka/v1alpha1/zz_configuration_types.go b/apis/kafka/v1alpha1/zz_configuration_types.go index 9e80a33..cad06cb 100755 --- a/apis/kafka/v1alpha1/zz_configuration_types.go +++ b/apis/kafka/v1alpha1/zz_configuration_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,21 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ConfigurationInitParameters struct { + + // Description of the configuration. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // List of Apache Kafka versions which can use this configuration. + KafkaVersions []*string `json:"kafkaVersions,omitempty" tf:"kafka_versions,omitempty"` + + // Name of the configuration. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // Contents of the server.properties file. Supported properties are documented in the MSK Developer Guide. + ServerProperties *string `json:"serverProperties,omitempty" tf:"server_properties,omitempty"` +} + type ConfigurationObservation struct { // Amazon Resource Name (ARN) of the configuration. @@ -64,6 +83,17 @@ type ConfigurationParameters struct { type ConfigurationSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ConfigurationParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ConfigurationInitParameters `json:"initProvider,omitempty"` } // ConfigurationStatus defines the observed state of Configuration. @@ -74,7 +104,7 @@ type ConfigurationStatus struct { // +kubebuilder:object:root=true -// Configuration is the Schema for the Configurations API. Upbound official provider resource for managing an amazon managed streaming for kafka configuration +// Configuration is the Schema for the Configurations API. provider resource for managing an amazon managed streaming for kafka configuration // +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" // +kubebuilder:printcolumn:name="SYNCED",type="string",JSONPath=".status.conditions[?(@.type=='Synced')].status" // +kubebuilder:printcolumn:name="EXTERNAL-NAME",type="string",JSONPath=".metadata.annotations.crossplane\\.io/external-name" @@ -84,9 +114,9 @@ type ConfigurationStatus struct { type Configuration struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.name)",message="name is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.serverProperties)",message="serverProperties is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serverProperties) || (has(self.initProvider) && has(self.initProvider.serverProperties))",message="spec.forProvider.serverProperties is a required parameter" Spec ConfigurationSpec `json:"spec"` Status ConfigurationStatus `json:"status,omitempty"` } diff --git a/apis/kafka/v1alpha1/zz_generated.deepcopy.go b/apis/kafka/v1alpha1/zz_generated.deepcopy.go index 3da563d..7755d89 100644 --- a/apis/kafka/v1alpha1/zz_generated.deepcopy.go +++ b/apis/kafka/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,42 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *BrokerLogsInitParameters) DeepCopyInto(out *BrokerLogsInitParameters) { + *out = *in + if in.CloudwatchLogs != nil { + in, out := &in.CloudwatchLogs, &out.CloudwatchLogs + *out = make([]CloudwatchLogsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Firehose != nil { + in, out := &in.Firehose, &out.Firehose + *out = make([]FirehoseInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.S3 != nil { + in, out := &in.S3, &out.S3 + *out = make([]S3InitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BrokerLogsInitParameters. +func (in *BrokerLogsInitParameters) DeepCopy() *BrokerLogsInitParameters { + if in == nil { + return nil + } + out := new(BrokerLogsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *BrokerLogsObservation) DeepCopyInto(out *BrokerLogsObservation) { *out = *in @@ -86,6 +121,45 @@ func (in *BrokerLogsParameters) DeepCopy() *BrokerLogsParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *BrokerNodeGroupInfoInitParameters) DeepCopyInto(out *BrokerNodeGroupInfoInitParameters) { + *out = *in + if in.AzDistribution != nil { + in, out := &in.AzDistribution, &out.AzDistribution + *out = new(string) + **out = **in + } + if in.ConnectivityInfo != nil { + in, out := &in.ConnectivityInfo, &out.ConnectivityInfo + *out = make([]ConnectivityInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.InstanceType != nil { + in, out := &in.InstanceType, &out.InstanceType + *out = new(string) + **out = **in + } + if in.StorageInfo != nil { + in, out := &in.StorageInfo, &out.StorageInfo + *out = make([]StorageInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BrokerNodeGroupInfoInitParameters. +func (in *BrokerNodeGroupInfoInitParameters) DeepCopy() *BrokerNodeGroupInfoInitParameters { + if in == nil { + return nil + } + out := new(BrokerNodeGroupInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *BrokerNodeGroupInfoObservation) DeepCopyInto(out *BrokerNodeGroupInfoObservation) { *out = *in @@ -232,6 +306,40 @@ func (in *BrokerNodeGroupInfoParameters) DeepCopy() *BrokerNodeGroupInfoParamete return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClientAuthenticationInitParameters) DeepCopyInto(out *ClientAuthenticationInitParameters) { + *out = *in + if in.Sasl != nil { + in, out := &in.Sasl, &out.Sasl + *out = make([]SaslInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.TLS != nil { + in, out := &in.TLS, &out.TLS + *out = make([]TLSInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Unauthenticated != nil { + in, out := &in.Unauthenticated, &out.Unauthenticated + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClientAuthenticationInitParameters. +func (in *ClientAuthenticationInitParameters) DeepCopy() *ClientAuthenticationInitParameters { + if in == nil { + return nil + } + out := new(ClientAuthenticationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClientAuthenticationObservation) DeepCopyInto(out *ClientAuthenticationObservation) { *out = *in @@ -300,6 +408,31 @@ func (in *ClientAuthenticationParameters) DeepCopy() *ClientAuthenticationParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CloudwatchLogsInitParameters) DeepCopyInto(out *CloudwatchLogsInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.LogGroup != nil { + in, out := &in.LogGroup, &out.LogGroup + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CloudwatchLogsInitParameters. +func (in *CloudwatchLogsInitParameters) DeepCopy() *CloudwatchLogsInitParameters { + if in == nil { + return nil + } + out := new(CloudwatchLogsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *CloudwatchLogsObservation) DeepCopyInto(out *CloudwatchLogsObservation) { *out = *in @@ -377,6 +510,120 @@ func (in *Cluster) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInitParameters) DeepCopyInto(out *ClusterInitParameters) { + *out = *in + if in.BrokerNodeGroupInfo != nil { + in, out := &in.BrokerNodeGroupInfo, &out.BrokerNodeGroupInfo + *out = make([]BrokerNodeGroupInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ClientAuthentication != nil { + in, out := &in.ClientAuthentication, &out.ClientAuthentication + *out = make([]ClientAuthenticationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ClusterName != nil { + in, out := &in.ClusterName, &out.ClusterName + *out = new(string) + **out = **in + } + if in.ConfigurationInfo != nil { + in, out := &in.ConfigurationInfo, &out.ConfigurationInfo + *out = make([]ConfigurationInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.EncryptionInfo != nil { + in, out := &in.EncryptionInfo, &out.EncryptionInfo + *out = make([]EncryptionInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.EnhancedMonitoring != nil { + in, out := &in.EnhancedMonitoring, &out.EnhancedMonitoring + *out = new(string) + **out = **in + } + if in.KafkaVersion != nil { + in, out := &in.KafkaVersion, &out.KafkaVersion + *out = new(string) + **out = **in + } + if in.LoggingInfo != nil { + in, out := &in.LoggingInfo, &out.LoggingInfo + *out = make([]LoggingInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.NumberOfBrokerNodes != nil { + in, out := &in.NumberOfBrokerNodes, &out.NumberOfBrokerNodes + *out = new(float64) + **out = **in + } + if in.OpenMonitoring != nil { + in, out := &in.OpenMonitoring, &out.OpenMonitoring + *out = make([]OpenMonitoringInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.StorageMode != nil { + in, out := &in.StorageMode, &out.StorageMode + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInitParameters. +func (in *ClusterInitParameters) DeepCopy() *ClusterInitParameters { + if in == nil { + return nil + } + out := new(ClusterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterList) DeepCopyInto(out *ClusterList) { *out = *in @@ -537,7 +784,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -552,7 +800,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -664,7 +913,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -679,7 +929,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -703,6 +954,7 @@ func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. @@ -760,7 +1012,7 @@ func (in *Configuration) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ConfigurationInfoObservation) DeepCopyInto(out *ConfigurationInfoObservation) { +func (in *ConfigurationInfoInitParameters) DeepCopyInto(out *ConfigurationInfoInitParameters) { *out = *in if in.Arn != nil { in, out := &in.Arn, &out.Arn @@ -774,18 +1026,18 @@ func (in *ConfigurationInfoObservation) DeepCopyInto(out *ConfigurationInfoObser } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInfoObservation. -func (in *ConfigurationInfoObservation) DeepCopy() *ConfigurationInfoObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInfoInitParameters. +func (in *ConfigurationInfoInitParameters) DeepCopy() *ConfigurationInfoInitParameters { if in == nil { return nil } - out := new(ConfigurationInfoObservation) + out := new(ConfigurationInfoInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ConfigurationInfoParameters) DeepCopyInto(out *ConfigurationInfoParameters) { +func (in *ConfigurationInfoObservation) DeepCopyInto(out *ConfigurationInfoObservation) { *out = *in if in.Arn != nil { in, out := &in.Arn, &out.Arn @@ -799,48 +1051,114 @@ func (in *ConfigurationInfoParameters) DeepCopyInto(out *ConfigurationInfoParame } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInfoParameters. -func (in *ConfigurationInfoParameters) DeepCopy() *ConfigurationInfoParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInfoObservation. +func (in *ConfigurationInfoObservation) DeepCopy() *ConfigurationInfoObservation { if in == nil { return nil } - out := new(ConfigurationInfoParameters) + out := new(ConfigurationInfoObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ConfigurationList) DeepCopyInto(out *ConfigurationList) { +func (in *ConfigurationInfoParameters) DeepCopyInto(out *ConfigurationInfoParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Configuration, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.Arn != nil { + in, out := &in.Arn, &out.Arn + *out = new(string) + **out = **in + } + if in.Revision != nil { + in, out := &in.Revision, &out.Revision + *out = new(float64) + **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationList. -func (in *ConfigurationList) DeepCopy() *ConfigurationList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInfoParameters. +func (in *ConfigurationInfoParameters) DeepCopy() *ConfigurationInfoParameters { if in == nil { return nil } - out := new(ConfigurationList) + out := new(ConfigurationInfoParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ConfigurationList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigurationInitParameters) DeepCopyInto(out *ConfigurationInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.KafkaVersions != nil { + in, out := &in.KafkaVersions, &out.KafkaVersions + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.ServerProperties != nil { + in, out := &in.ServerProperties, &out.ServerProperties + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationInitParameters. +func (in *ConfigurationInitParameters) DeepCopy() *ConfigurationInitParameters { + if in == nil { + return nil + } + out := new(ConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigurationList) DeepCopyInto(out *ConfigurationList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Configuration, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationList. +func (in *ConfigurationList) DeepCopy() *ConfigurationList { + if in == nil { + return nil + } + out := new(ConfigurationList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ConfigurationList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ConfigurationObservation) DeepCopyInto(out *ConfigurationObservation) { *out = *in @@ -948,6 +1266,7 @@ func (in *ConfigurationSpec) DeepCopyInto(out *ConfigurationSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationSpec. @@ -977,6 +1296,28 @@ func (in *ConfigurationStatus) DeepCopy() *ConfigurationStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConnectivityInfoInitParameters) DeepCopyInto(out *ConnectivityInfoInitParameters) { + *out = *in + if in.PublicAccess != nil { + in, out := &in.PublicAccess, &out.PublicAccess + *out = make([]PublicAccessInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectivityInfoInitParameters. +func (in *ConnectivityInfoInitParameters) DeepCopy() *ConnectivityInfoInitParameters { + if in == nil { + return nil + } + out := new(ConnectivityInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ConnectivityInfoObservation) DeepCopyInto(out *ConnectivityInfoObservation) { *out = *in @@ -1021,6 +1362,33 @@ func (in *ConnectivityInfoParameters) DeepCopy() *ConnectivityInfoParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EBSStorageInfoInitParameters) DeepCopyInto(out *EBSStorageInfoInitParameters) { + *out = *in + if in.ProvisionedThroughput != nil { + in, out := &in.ProvisionedThroughput, &out.ProvisionedThroughput + *out = make([]ProvisionedThroughputInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.VolumeSize != nil { + in, out := &in.VolumeSize, &out.VolumeSize + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EBSStorageInfoInitParameters. +func (in *EBSStorageInfoInitParameters) DeepCopy() *EBSStorageInfoInitParameters { + if in == nil { + return nil + } + out := new(EBSStorageInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EBSStorageInfoObservation) DeepCopyInto(out *EBSStorageInfoObservation) { *out = *in @@ -1075,6 +1443,31 @@ func (in *EBSStorageInfoParameters) DeepCopy() *EBSStorageInfoParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EncryptionInTransitInitParameters) DeepCopyInto(out *EncryptionInTransitInitParameters) { + *out = *in + if in.ClientBroker != nil { + in, out := &in.ClientBroker, &out.ClientBroker + *out = new(string) + **out = **in + } + if in.InCluster != nil { + in, out := &in.InCluster, &out.InCluster + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EncryptionInTransitInitParameters. +func (in *EncryptionInTransitInitParameters) DeepCopy() *EncryptionInTransitInitParameters { + if in == nil { + return nil + } + out := new(EncryptionInTransitInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EncryptionInTransitObservation) DeepCopyInto(out *EncryptionInTransitObservation) { *out = *in @@ -1125,6 +1518,28 @@ func (in *EncryptionInTransitParameters) DeepCopy() *EncryptionInTransitParamete return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EncryptionInfoInitParameters) DeepCopyInto(out *EncryptionInfoInitParameters) { + *out = *in + if in.EncryptionInTransit != nil { + in, out := &in.EncryptionInTransit, &out.EncryptionInTransit + *out = make([]EncryptionInTransitInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EncryptionInfoInitParameters. +func (in *EncryptionInfoInitParameters) DeepCopy() *EncryptionInfoInitParameters { + if in == nil { + return nil + } + out := new(EncryptionInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EncryptionInfoObservation) DeepCopyInto(out *EncryptionInfoObservation) { *out = *in @@ -1189,6 +1604,31 @@ func (in *EncryptionInfoParameters) DeepCopy() *EncryptionInfoParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FirehoseInitParameters) DeepCopyInto(out *FirehoseInitParameters) { + *out = *in + if in.DeliveryStream != nil { + in, out := &in.DeliveryStream, &out.DeliveryStream + *out = new(string) + **out = **in + } + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FirehoseInitParameters. +func (in *FirehoseInitParameters) DeepCopy() *FirehoseInitParameters { + if in == nil { + return nil + } + out := new(FirehoseInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *FirehoseObservation) DeepCopyInto(out *FirehoseObservation) { *out = *in @@ -1239,6 +1679,26 @@ func (in *FirehoseParameters) DeepCopy() *FirehoseParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *JmxExporterInitParameters) DeepCopyInto(out *JmxExporterInitParameters) { + *out = *in + if in.EnabledInBroker != nil { + in, out := &in.EnabledInBroker, &out.EnabledInBroker + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new JmxExporterInitParameters. +func (in *JmxExporterInitParameters) DeepCopy() *JmxExporterInitParameters { + if in == nil { + return nil + } + out := new(JmxExporterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *JmxExporterObservation) DeepCopyInto(out *JmxExporterObservation) { *out = *in @@ -1279,6 +1739,28 @@ func (in *JmxExporterParameters) DeepCopy() *JmxExporterParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *LoggingInfoInitParameters) DeepCopyInto(out *LoggingInfoInitParameters) { + *out = *in + if in.BrokerLogs != nil { + in, out := &in.BrokerLogs, &out.BrokerLogs + *out = make([]BrokerLogsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LoggingInfoInitParameters. +func (in *LoggingInfoInitParameters) DeepCopy() *LoggingInfoInitParameters { + if in == nil { + return nil + } + out := new(LoggingInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LoggingInfoObservation) DeepCopyInto(out *LoggingInfoObservation) { *out = *in @@ -1323,6 +1805,26 @@ func (in *LoggingInfoParameters) DeepCopy() *LoggingInfoParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *NodeExporterInitParameters) DeepCopyInto(out *NodeExporterInitParameters) { + *out = *in + if in.EnabledInBroker != nil { + in, out := &in.EnabledInBroker, &out.EnabledInBroker + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeExporterInitParameters. +func (in *NodeExporterInitParameters) DeepCopy() *NodeExporterInitParameters { + if in == nil { + return nil + } + out := new(NodeExporterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *NodeExporterObservation) DeepCopyInto(out *NodeExporterObservation) { *out = *in @@ -1363,6 +1865,28 @@ func (in *NodeExporterParameters) DeepCopy() *NodeExporterParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *OpenMonitoringInitParameters) DeepCopyInto(out *OpenMonitoringInitParameters) { + *out = *in + if in.Prometheus != nil { + in, out := &in.Prometheus, &out.Prometheus + *out = make([]PrometheusInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenMonitoringInitParameters. +func (in *OpenMonitoringInitParameters) DeepCopy() *OpenMonitoringInitParameters { + if in == nil { + return nil + } + out := new(OpenMonitoringInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *OpenMonitoringObservation) DeepCopyInto(out *OpenMonitoringObservation) { *out = *in @@ -1407,6 +1931,35 @@ func (in *OpenMonitoringParameters) DeepCopy() *OpenMonitoringParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *PrometheusInitParameters) DeepCopyInto(out *PrometheusInitParameters) { + *out = *in + if in.JmxExporter != nil { + in, out := &in.JmxExporter, &out.JmxExporter + *out = make([]JmxExporterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.NodeExporter != nil { + in, out := &in.NodeExporter, &out.NodeExporter + *out = make([]NodeExporterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PrometheusInitParameters. +func (in *PrometheusInitParameters) DeepCopy() *PrometheusInitParameters { + if in == nil { + return nil + } + out := new(PrometheusInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *PrometheusObservation) DeepCopyInto(out *PrometheusObservation) { *out = *in @@ -1465,6 +2018,31 @@ func (in *PrometheusParameters) DeepCopy() *PrometheusParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ProvisionedThroughputInitParameters) DeepCopyInto(out *ProvisionedThroughputInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.VolumeThroughput != nil { + in, out := &in.VolumeThroughput, &out.VolumeThroughput + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProvisionedThroughputInitParameters. +func (in *ProvisionedThroughputInitParameters) DeepCopy() *ProvisionedThroughputInitParameters { + if in == nil { + return nil + } + out := new(ProvisionedThroughputInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ProvisionedThroughputObservation) DeepCopyInto(out *ProvisionedThroughputObservation) { *out = *in @@ -1515,6 +2093,26 @@ func (in *ProvisionedThroughputParameters) DeepCopy() *ProvisionedThroughputPara return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *PublicAccessInitParameters) DeepCopyInto(out *PublicAccessInitParameters) { + *out = *in + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PublicAccessInitParameters. +func (in *PublicAccessInitParameters) DeepCopy() *PublicAccessInitParameters { + if in == nil { + return nil + } + out := new(PublicAccessInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *PublicAccessObservation) DeepCopyInto(out *PublicAccessObservation) { *out = *in @@ -1555,6 +2153,36 @@ func (in *PublicAccessParameters) DeepCopy() *PublicAccessParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *S3InitParameters) DeepCopyInto(out *S3InitParameters) { + *out = *in + if in.Bucket != nil { + in, out := &in.Bucket, &out.Bucket + *out = new(string) + **out = **in + } + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.Prefix != nil { + in, out := &in.Prefix, &out.Prefix + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new S3InitParameters. +func (in *S3InitParameters) DeepCopy() *S3InitParameters { + if in == nil { + return nil + } + out := new(S3InitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *S3Observation) DeepCopyInto(out *S3Observation) { *out = *in @@ -1615,6 +2243,31 @@ func (in *S3Parameters) DeepCopy() *S3Parameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SaslInitParameters) DeepCopyInto(out *SaslInitParameters) { + *out = *in + if in.IAM != nil { + in, out := &in.IAM, &out.IAM + *out = new(bool) + **out = **in + } + if in.Scram != nil { + in, out := &in.Scram, &out.Scram + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SaslInitParameters. +func (in *SaslInitParameters) DeepCopy() *SaslInitParameters { + if in == nil { + return nil + } + out := new(SaslInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SaslObservation) DeepCopyInto(out *SaslObservation) { *out = *in @@ -1665,6 +2318,28 @@ func (in *SaslParameters) DeepCopy() *SaslParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *StorageInfoInitParameters) DeepCopyInto(out *StorageInfoInitParameters) { + *out = *in + if in.EBSStorageInfo != nil { + in, out := &in.EBSStorageInfo, &out.EBSStorageInfo + *out = make([]EBSStorageInfoInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageInfoInitParameters. +func (in *StorageInfoInitParameters) DeepCopy() *StorageInfoInitParameters { + if in == nil { + return nil + } + out := new(StorageInfoInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *StorageInfoObservation) DeepCopyInto(out *StorageInfoObservation) { *out = *in @@ -1709,6 +2384,32 @@ func (in *StorageInfoParameters) DeepCopy() *StorageInfoParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TLSInitParameters) DeepCopyInto(out *TLSInitParameters) { + *out = *in + if in.CertificateAuthorityArns != nil { + in, out := &in.CertificateAuthorityArns, &out.CertificateAuthorityArns + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TLSInitParameters. +func (in *TLSInitParameters) DeepCopy() *TLSInitParameters { + if in == nil { + return nil + } + out := new(TLSInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TLSObservation) DeepCopyInto(out *TLSObservation) { *out = *in diff --git a/apis/kafka/v1alpha1/zz_generated.managed.go b/apis/kafka/v1alpha1/zz_generated.managed.go index 6976bcc..9a18d8a 100644 --- a/apis/kafka/v1alpha1/zz_generated.managed.go +++ b/apis/kafka/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Cluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Cluster. -func (mg *Cluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Cluster. +func (mg *Cluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Cluster. @@ -27,14 +27,6 @@ func (mg *Cluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Cluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Cluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Cluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Cluster. -func (mg *Cluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Cluster. +func (mg *Cluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Cluster. @@ -65,14 +57,6 @@ func (mg *Cluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Cluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Cluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *Configuration) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Configuration. -func (mg *Configuration) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Configuration. +func (mg *Configuration) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Configuration. @@ -103,14 +87,6 @@ func (mg *Configuration) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Configuration. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Configuration) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Configuration. func (mg *Configuration) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *Configuration) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Configuration. -func (mg *Configuration) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Configuration. +func (mg *Configuration) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Configuration. @@ -141,14 +117,6 @@ func (mg *Configuration) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Configuration. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Configuration) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Configuration. func (mg *Configuration) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/kafka/v1alpha1/zz_generated_terraformed.go b/apis/kafka/v1alpha1/zz_generated_terraformed.go index 0caa581..841530e 100755 --- a/apis/kafka/v1alpha1/zz_generated_terraformed.go +++ b/apis/kafka/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Cluster @@ -69,6 +74,46 @@ func (tr *Cluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Cluster +func (tr *Cluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Cluster +func (tr *Cluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Cluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Cluster) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *Configuration) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Configuration +func (tr *Configuration) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Configuration +func (tr *Configuration) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Configuration using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Configuration) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/kafka/v1alpha1/zz_groupversion_info.go b/apis/kafka/v1alpha1/zz_groupversion_info.go index 57abf00..8f97225 100755 --- a/apis/kafka/v1alpha1/zz_groupversion_info.go +++ b/apis/kafka/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/kinesis/v1alpha1/zz_generated.deepcopy.go b/apis/kinesis/v1alpha1/zz_generated.deepcopy.go index 7403a87..a84cdea 100644 --- a/apis/kinesis/v1alpha1/zz_generated.deepcopy.go +++ b/apis/kinesis/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -41,6 +40,91 @@ func (in *Stream) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *StreamInitParameters) DeepCopyInto(out *StreamInitParameters) { + *out = *in + if in.EncryptionType != nil { + in, out := &in.EncryptionType, &out.EncryptionType + *out = new(string) + **out = **in + } + if in.EnforceConsumerDeletion != nil { + in, out := &in.EnforceConsumerDeletion, &out.EnforceConsumerDeletion + *out = new(bool) + **out = **in + } + if in.RetentionPeriod != nil { + in, out := &in.RetentionPeriod, &out.RetentionPeriod + *out = new(float64) + **out = **in + } + if in.ShardCount != nil { + in, out := &in.ShardCount, &out.ShardCount + *out = new(float64) + **out = **in + } + if in.ShardLevelMetrics != nil { + in, out := &in.ShardLevelMetrics, &out.ShardLevelMetrics + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.StreamModeDetails != nil { + in, out := &in.StreamModeDetails, &out.StreamModeDetails + *out = make([]StreamModeDetailsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StreamInitParameters. +func (in *StreamInitParameters) DeepCopy() *StreamInitParameters { + if in == nil { + return nil + } + out := new(StreamInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *StreamList) DeepCopyInto(out *StreamList) { *out = *in @@ -73,6 +157,26 @@ func (in *StreamList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *StreamModeDetailsInitParameters) DeepCopyInto(out *StreamModeDetailsInitParameters) { + *out = *in + if in.StreamMode != nil { + in, out := &in.StreamMode, &out.StreamMode + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StreamModeDetailsInitParameters. +func (in *StreamModeDetailsInitParameters) DeepCopy() *StreamModeDetailsInitParameters { + if in == nil { + return nil + } + out := new(StreamModeDetailsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *StreamModeDetailsObservation) DeepCopyInto(out *StreamModeDetailsObservation) { *out = *in @@ -177,7 +281,8 @@ func (in *StreamObservation) DeepCopyInto(out *StreamObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -192,7 +297,8 @@ func (in *StreamObservation) DeepCopyInto(out *StreamObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -280,7 +386,8 @@ func (in *StreamParameters) DeepCopyInto(out *StreamParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -295,7 +402,8 @@ func (in *StreamParameters) DeepCopyInto(out *StreamParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -319,6 +427,7 @@ func (in *StreamSpec) DeepCopyInto(out *StreamSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StreamSpec. diff --git a/apis/kinesis/v1alpha1/zz_generated.managed.go b/apis/kinesis/v1alpha1/zz_generated.managed.go index d7d7716..e7fad97 100644 --- a/apis/kinesis/v1alpha1/zz_generated.managed.go +++ b/apis/kinesis/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Stream) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Stream. -func (mg *Stream) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Stream. +func (mg *Stream) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Stream. @@ -27,14 +27,6 @@ func (mg *Stream) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Stream. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Stream) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Stream. func (mg *Stream) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Stream) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Stream. -func (mg *Stream) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Stream. +func (mg *Stream) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Stream. @@ -65,14 +57,6 @@ func (mg *Stream) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Stream. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Stream) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Stream. func (mg *Stream) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/kinesis/v1alpha1/zz_generated_terraformed.go b/apis/kinesis/v1alpha1/zz_generated_terraformed.go index dcd7948..c42d99c 100755 --- a/apis/kinesis/v1alpha1/zz_generated_terraformed.go +++ b/apis/kinesis/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Stream @@ -69,6 +74,46 @@ func (tr *Stream) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Stream +func (tr *Stream) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Stream +func (tr *Stream) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Stream using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Stream) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/kinesis/v1alpha1/zz_groupversion_info.go b/apis/kinesis/v1alpha1/zz_groupversion_info.go index 12922b3..feba4d4 100755 --- a/apis/kinesis/v1alpha1/zz_groupversion_info.go +++ b/apis/kinesis/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/kinesis/v1alpha1/zz_stream_types.go b/apis/kinesis/v1alpha1/zz_stream_types.go index 4f45f0d..41dd0b7 100755 --- a/apis/kinesis/v1alpha1/zz_stream_types.go +++ b/apis/kinesis/v1alpha1/zz_stream_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,40 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type StreamInitParameters struct { + + // The encryption type to use. The only acceptable values are NONE or KMS. The default value is NONE. + EncryptionType *string `json:"encryptionType,omitempty" tf:"encryption_type,omitempty"` + + // A boolean that indicates all registered consumers should be deregistered from the stream so that the stream can be destroyed without error. The default value is false. + EnforceConsumerDeletion *bool `json:"enforceConsumerDeletion,omitempty" tf:"enforce_consumer_deletion,omitempty"` + + // Length of time data records are accessible after they are added to the stream. The maximum value of a stream's retention period is 8760 hours. Minimum value is 24. Default is 24. + RetentionPeriod *float64 `json:"retentionPeriod,omitempty" tf:"retention_period,omitempty"` + + // – The number of shards that the stream will use. If the stream_mode is PROVISIONED, this field is required. + // Amazon has guidelines for specifying the Stream size that should be referenced when creating a Kinesis stream. See Amazon Kinesis Streams for more. + ShardCount *float64 `json:"shardCount,omitempty" tf:"shard_count,omitempty"` + + // A list of shard-level CloudWatch metrics which can be enabled for the stream. See Monitoring with CloudWatch for more. Note that the value ALL should not be used; instead you should provide an explicit list of metrics you wish to enable. + ShardLevelMetrics []*string `json:"shardLevelMetrics,omitempty" tf:"shard_level_metrics,omitempty"` + + // Indicates the capacity mode of the data stream. Detailed below. + StreamModeDetails []StreamModeDetailsInitParameters `json:"streamModeDetails,omitempty" tf:"stream_mode_details,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + +type StreamModeDetailsInitParameters struct { + + // Specifies the capacity mode of the stream. Must be either PROVISIONED or ON_DEMAND. + StreamMode *string `json:"streamMode,omitempty" tf:"stream_mode,omitempty"` +} + type StreamModeDetailsObservation struct { // Specifies the capacity mode of the stream. Must be either PROVISIONED or ON_DEMAND. @@ -22,7 +60,7 @@ type StreamModeDetailsObservation struct { type StreamModeDetailsParameters struct { // Specifies the capacity mode of the stream. Must be either PROVISIONED or ON_DEMAND. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional StreamMode *string `json:"streamMode" tf:"stream_mode,omitempty"` } @@ -121,6 +159,17 @@ type StreamParameters struct { type StreamSpec struct { v1.ResourceSpec `json:",inline"` ForProvider StreamParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider StreamInitParameters `json:"initProvider,omitempty"` } // StreamStatus defines the observed state of Stream. @@ -141,7 +190,7 @@ type StreamStatus struct { type Stream struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec StreamSpec `json:"spec"` Status StreamStatus `json:"status,omitempty"` } diff --git a/apis/kms/v1alpha1/zz_generated.deepcopy.go b/apis/kms/v1alpha1/zz_generated.deepcopy.go index d11cd0f..ff37082 100644 --- a/apis/kms/v1alpha1/zz_generated.deepcopy.go +++ b/apis/kms/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -40,6 +39,103 @@ func (in *Key) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *KeyInitParameters) DeepCopyInto(out *KeyInitParameters) { + *out = *in + if in.BypassPolicyLockoutSafetyCheck != nil { + in, out := &in.BypassPolicyLockoutSafetyCheck, &out.BypassPolicyLockoutSafetyCheck + *out = new(bool) + **out = **in + } + if in.CustomKeyStoreID != nil { + in, out := &in.CustomKeyStoreID, &out.CustomKeyStoreID + *out = new(string) + **out = **in + } + if in.CustomerMasterKeySpec != nil { + in, out := &in.CustomerMasterKeySpec, &out.CustomerMasterKeySpec + *out = new(string) + **out = **in + } + if in.DeletionWindowInDays != nil { + in, out := &in.DeletionWindowInDays, &out.DeletionWindowInDays + *out = new(float64) + **out = **in + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.EnableKeyRotation != nil { + in, out := &in.EnableKeyRotation, &out.EnableKeyRotation + *out = new(bool) + **out = **in + } + if in.IsEnabled != nil { + in, out := &in.IsEnabled, &out.IsEnabled + *out = new(bool) + **out = **in + } + if in.KeyUsage != nil { + in, out := &in.KeyUsage, &out.KeyUsage + *out = new(string) + **out = **in + } + if in.MultiRegion != nil { + in, out := &in.MultiRegion, &out.MultiRegion + *out = new(bool) + **out = **in + } + if in.Policy != nil { + in, out := &in.Policy, &out.Policy + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeyInitParameters. +func (in *KeyInitParameters) DeepCopy() *KeyInitParameters { + if in == nil { + return nil + } + out := new(KeyInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *KeyList) DeepCopyInto(out *KeyList) { *out = *in @@ -148,7 +244,8 @@ func (in *KeyObservation) DeepCopyInto(out *KeyObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -163,7 +260,8 @@ func (in *KeyObservation) DeepCopyInto(out *KeyObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -248,7 +346,8 @@ func (in *KeyParameters) DeepCopyInto(out *KeyParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -263,7 +362,8 @@ func (in *KeyParameters) DeepCopyInto(out *KeyParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -287,6 +387,7 @@ func (in *KeySpec) DeepCopyInto(out *KeySpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KeySpec. diff --git a/apis/kms/v1alpha1/zz_generated.managed.go b/apis/kms/v1alpha1/zz_generated.managed.go index 04e4eeb..e487c1f 100644 --- a/apis/kms/v1alpha1/zz_generated.managed.go +++ b/apis/kms/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Key) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Key. -func (mg *Key) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Key. +func (mg *Key) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Key. @@ -27,14 +27,6 @@ func (mg *Key) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Key. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Key) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Key. func (mg *Key) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Key) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Key. -func (mg *Key) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Key. +func (mg *Key) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Key. @@ -65,14 +57,6 @@ func (mg *Key) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Key. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Key) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Key. func (mg *Key) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/kms/v1alpha1/zz_generated_terraformed.go b/apis/kms/v1alpha1/zz_generated_terraformed.go index 357ddfb..b4a54fa 100755 --- a/apis/kms/v1alpha1/zz_generated_terraformed.go +++ b/apis/kms/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this Key @@ -69,6 +74,46 @@ func (tr *Key) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Key +func (tr *Key) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Key +func (tr *Key) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Key using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Key) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/kms/v1alpha1/zz_groupversion_info.go b/apis/kms/v1alpha1/zz_groupversion_info.go index 1cb8cbc..1f2abcb 100755 --- a/apis/kms/v1alpha1/zz_groupversion_info.go +++ b/apis/kms/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/kms/v1alpha1/zz_key_types.go b/apis/kms/v1alpha1/zz_key_types.go index cf4a76f..3d5d039 100755 --- a/apis/kms/v1alpha1/zz_key_types.go +++ b/apis/kms/v1alpha1/zz_key_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,52 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type KeyInitParameters struct { + + // A flag to indicate whether to bypass the key policy lockout safety check. + // Setting this value to true increases the risk that the KMS key becomes unmanageable. Do not set this value to true indiscriminately. + // For more information, refer to the scenario in the Default Key Policy section in the AWS Key Management Service Developer Guide. + // The default value is false. + BypassPolicyLockoutSafetyCheck *bool `json:"bypassPolicyLockoutSafetyCheck,omitempty" tf:"bypass_policy_lockout_safety_check,omitempty"` + + // ID of the KMS Custom Key Store where the key will be stored instead of KMS (eg CloudHSM). + CustomKeyStoreID *string `json:"customKeyStoreId,omitempty" tf:"custom_key_store_id,omitempty"` + + // Specifies whether the key contains a symmetric key or an asymmetric key pair and the encryption algorithms or signing algorithms that the key supports. + // Valid values: SYMMETRIC_DEFAULT, RSA_2048, RSA_3072, RSA_4096, HMAC_256, ECC_NIST_P256, ECC_NIST_P384, ECC_NIST_P521, or ECC_SECG_P256K1. Defaults to SYMMETRIC_DEFAULT. For help with choosing a key spec, see the AWS KMS Developer Guide. + CustomerMasterKeySpec *string `json:"customerMasterKeySpec,omitempty" tf:"customer_master_key_spec,omitempty"` + + // The waiting period, specified in number of days. After the waiting period ends, AWS KMS deletes the KMS key. + // If you specify a value, it must be between 7 and 30, inclusive. If you do not specify a value, it defaults to 30. + // If the KMS key is a multi-Region primary key with replicas, the waiting period begins when the last of its replica keys is deleted. Otherwise, the waiting period begins immediately. + DeletionWindowInDays *float64 `json:"deletionWindowInDays,omitempty" tf:"deletion_window_in_days,omitempty"` + + // The description of the key as viewed in AWS console. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Specifies whether key rotation is enabled. Defaults to false. + EnableKeyRotation *bool `json:"enableKeyRotation,omitempty" tf:"enable_key_rotation,omitempty"` + + // Specifies whether the key is enabled. Defaults to true. + IsEnabled *bool `json:"isEnabled,omitempty" tf:"is_enabled,omitempty"` + + // Specifies the intended use of the key. Valid values: ENCRYPT_DECRYPT, SIGN_VERIFY, or GENERATE_VERIFY_MAC. + // Defaults to ENCRYPT_DECRYPT. + KeyUsage *string `json:"keyUsage,omitempty" tf:"key_usage,omitempty"` + + // Indicates whether the KMS key is a multi-Region (true) or regional (false) key. Defaults to false. + MultiRegion *bool `json:"multiRegion,omitempty" tf:"multi_region,omitempty"` + + // A valid policy JSON document. Although this is a key policy, not an IAM policy, an aws_iam_policy_document, in the form that designates a principal, can be used. + Policy *string `json:"policy,omitempty" tf:"policy,omitempty"` + + // A map of tags to assign to the object. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type KeyObservation struct { // The Amazon Resource Name (ARN) of the key. @@ -134,6 +184,17 @@ type KeyParameters struct { type KeySpec struct { v1.ResourceSpec `json:",inline"` ForProvider KeyParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider KeyInitParameters `json:"initProvider,omitempty"` } // KeyStatus defines the observed state of Key. @@ -154,7 +215,7 @@ type KeyStatus struct { type Key struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec KeySpec `json:"spec"` Status KeyStatus `json:"status,omitempty"` } diff --git a/apis/memorydb/v1alpha1/zz_acl_types.go b/apis/memorydb/v1alpha1/zz_acl_types.go index f54443c..9e8bcb8 100755 --- a/apis/memorydb/v1alpha1/zz_acl_types.go +++ b/apis/memorydb/v1alpha1/zz_acl_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ACLInitParameters struct { + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Set of MemoryDB user names to be included in this ACL. + UserNames []*string `json:"userNames,omitempty" tf:"user_names,omitempty"` +} + type ACLObservation struct { // The ARN of the ACL. @@ -58,6 +74,17 @@ type ACLParameters struct { type ACLSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ACLParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ACLInitParameters `json:"initProvider,omitempty"` } // ACLStatus defines the observed state of ACL. @@ -78,7 +105,7 @@ type ACLStatus struct { type ACL struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ACLSpec `json:"spec"` Status ACLStatus `json:"status,omitempty"` } diff --git a/apis/memorydb/v1alpha1/zz_cluster_types.go b/apis/memorydb/v1alpha1/zz_cluster_types.go index 8fb3553..e113015 100755 --- a/apis/memorydb/v1alpha1/zz_cluster_types.go +++ b/apis/memorydb/v1alpha1/zz_cluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterEndpointInitParameters struct { +} + type ClusterEndpointObservation struct { // DNS hostname of the cluster configuration endpoint. @@ -25,6 +32,69 @@ type ClusterEndpointObservation struct { type ClusterEndpointParameters struct { } +type ClusterInitParameters struct { + + // The name of the Access Control List to associate with the cluster. + ACLName *string `json:"aclName,omitempty" tf:"acl_name,omitempty"` + + // When set to true, the cluster will automatically receive minor engine version upgrades after launch. Defaults to true. + AutoMinorVersionUpgrade *bool `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // Enables data tiering. This option is not supported by all instance types. For more information, see Data tiering. + DataTiering *bool `json:"dataTiering,omitempty" tf:"data_tiering,omitempty"` + + // Description for the cluster. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Version number of the Redis engine to be used for the cluster. Downgrades are not supported. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // Name of the final cluster snapshot to be created when this resource is deleted. If omitted, no final snapshot will be made. + FinalSnapshotName *string `json:"finalSnapshotName,omitempty" tf:"final_snapshot_name,omitempty"` + + // Specifies the weekly time range during which maintenance on the cluster is performed. Specify as a range in the format ddd:hh24:mi-ddd:hh24:mi (24H Clock UTC). The minimum maintenance window is a 60 minute period. Example: sun:23:00-mon:01:30. + MaintenanceWindow *string `json:"maintenanceWindow,omitempty" tf:"maintenance_window,omitempty"` + + // The compute and memory capacity of the nodes in the cluster. See AWS documentation on supported node types as well as vertical scaling. + NodeType *string `json:"nodeType,omitempty" tf:"node_type,omitempty"` + + // The number of replicas to apply to each shard, up to a maximum of 5. Defaults to 1 (i.e. 2 nodes per shard). + NumReplicasPerShard *float64 `json:"numReplicasPerShard,omitempty" tf:"num_replicas_per_shard,omitempty"` + + // The number of shards in the cluster. Defaults to 1. + NumShards *float64 `json:"numShards,omitempty" tf:"num_shards,omitempty"` + + // The name of the parameter group associated with the cluster. + ParameterGroupName *string `json:"parameterGroupName,omitempty" tf:"parameter_group_name,omitempty"` + + // The port number on which each of the nodes accepts connections. Defaults to 6379. + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // List of ARN-s that uniquely identify RDB snapshot files stored in S3. The snapshot files will be used to populate the new cluster. Object names in the ARN-s cannot contain any commas. + SnapshotArns []*string `json:"snapshotArns,omitempty" tf:"snapshot_arns,omitempty"` + + // The name of a snapshot from which to restore data into the new cluster. + SnapshotName *string `json:"snapshotName,omitempty" tf:"snapshot_name,omitempty"` + + // The number of days for which MemoryDB retains automatic snapshots before deleting them. When set to 0, automatic backups are disabled. Defaults to 0. + SnapshotRetentionLimit *float64 `json:"snapshotRetentionLimit,omitempty" tf:"snapshot_retention_limit,omitempty"` + + // The daily time range (in UTC) during which MemoryDB begins taking a daily snapshot of your shard. Example: 05:00-09:00. + SnapshotWindow *string `json:"snapshotWindow,omitempty" tf:"snapshot_window,omitempty"` + + // ARN of the SNS topic to which cluster notifications are sent. + SnsTopicArn *string `json:"snsTopicArn,omitempty" tf:"sns_topic_arn,omitempty"` + + // A flag to enable in-transit encryption on the cluster. When set to false, the acl_name must be open-access. Defaults to true. + TLSEnabled *bool `json:"tlsEnabled,omitempty" tf:"tls_enabled,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterObservation struct { // The name of the Access Control List to associate with the cluster. @@ -216,7 +286,7 @@ type ClusterParameters struct { // The name of the subnet group to be used for the cluster. Defaults to a subnet group consisting of default VPC subnets. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/memorydb/v1alpha1.SubnetGroup - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional SubnetGroupName *string `json:"subnetGroupName,omitempty" tf:"subnet_group_name,omitempty"` @@ -241,6 +311,9 @@ type ClusterParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type EndpointInitParameters struct { +} + type EndpointObservation struct { // DNS hostname of the cluster configuration endpoint. @@ -253,6 +326,9 @@ type EndpointObservation struct { type EndpointParameters struct { } +type NodesInitParameters struct { +} + type NodesObservation struct { // The Availability Zone in which the node resides. @@ -270,6 +346,9 @@ type NodesObservation struct { type NodesParameters struct { } +type ShardsInitParameters struct { +} + type ShardsObservation struct { // Name of the cluster. Conflicts with name_prefix. @@ -292,6 +371,17 @@ type ShardsParameters struct { type ClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInitParameters `json:"initProvider,omitempty"` } // ClusterStatus defines the observed state of Cluster. @@ -312,9 +402,9 @@ type ClusterStatus struct { type Cluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.aclName)",message="aclName is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.nodeType)",message="nodeType is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.aclName) || (has(self.initProvider) && has(self.initProvider.aclName))",message="spec.forProvider.aclName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.nodeType) || (has(self.initProvider) && has(self.initProvider.nodeType))",message="spec.forProvider.nodeType is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSpec `json:"spec"` Status ClusterStatus `json:"status,omitempty"` } diff --git a/apis/memorydb/v1alpha1/zz_generated.deepcopy.go b/apis/memorydb/v1alpha1/zz_generated.deepcopy.go index 7c9199f..21027b6 100644 --- a/apis/memorydb/v1alpha1/zz_generated.deepcopy.go +++ b/apis/memorydb/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -41,6 +40,64 @@ func (in *ACL) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ACLInitParameters) DeepCopyInto(out *ACLInitParameters) { + *out = *in + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.UserNames != nil { + in, out := &in.UserNames, &out.UserNames + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ACLInitParameters. +func (in *ACLInitParameters) DeepCopy() *ACLInitParameters { + if in == nil { + return nil + } + out := new(ACLInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ACLList) DeepCopyInto(out *ACLList) { *out = *in @@ -99,7 +156,8 @@ func (in *ACLObservation) DeepCopyInto(out *ACLObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -114,7 +172,8 @@ func (in *ACLObservation) DeepCopyInto(out *ACLObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -160,7 +219,8 @@ func (in *ACLParameters) DeepCopyInto(out *ACLParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -175,7 +235,8 @@ func (in *ACLParameters) DeepCopyInto(out *ACLParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -210,6 +271,7 @@ func (in *ACLSpec) DeepCopyInto(out *ACLSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ACLSpec. @@ -266,6 +328,21 @@ func (in *Cluster) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterConfigurationInitParameters) DeepCopyInto(out *ClusterConfigurationInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterConfigurationInitParameters. +func (in *ClusterConfigurationInitParameters) DeepCopy() *ClusterConfigurationInitParameters { + if in == nil { + return nil + } + out := new(ClusterConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterConfigurationObservation) DeepCopyInto(out *ClusterConfigurationObservation) { *out = *in @@ -361,6 +438,21 @@ func (in *ClusterConfigurationParameters) DeepCopy() *ClusterConfigurationParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterEndpointInitParameters) DeepCopyInto(out *ClusterEndpointInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterEndpointInitParameters. +func (in *ClusterEndpointInitParameters) DeepCopy() *ClusterEndpointInitParameters { + if in == nil { + return nil + } + out := new(ClusterEndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterEndpointObservation) DeepCopyInto(out *ClusterEndpointObservation) { *out = *in @@ -401,6 +493,149 @@ func (in *ClusterEndpointParameters) DeepCopy() *ClusterEndpointParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInitParameters) DeepCopyInto(out *ClusterInitParameters) { + *out = *in + if in.ACLName != nil { + in, out := &in.ACLName, &out.ACLName + *out = new(string) + **out = **in + } + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(bool) + **out = **in + } + if in.DataTiering != nil { + in, out := &in.DataTiering, &out.DataTiering + *out = new(bool) + **out = **in + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.FinalSnapshotName != nil { + in, out := &in.FinalSnapshotName, &out.FinalSnapshotName + *out = new(string) + **out = **in + } + if in.MaintenanceWindow != nil { + in, out := &in.MaintenanceWindow, &out.MaintenanceWindow + *out = new(string) + **out = **in + } + if in.NodeType != nil { + in, out := &in.NodeType, &out.NodeType + *out = new(string) + **out = **in + } + if in.NumReplicasPerShard != nil { + in, out := &in.NumReplicasPerShard, &out.NumReplicasPerShard + *out = new(float64) + **out = **in + } + if in.NumShards != nil { + in, out := &in.NumShards, &out.NumShards + *out = new(float64) + **out = **in + } + if in.ParameterGroupName != nil { + in, out := &in.ParameterGroupName, &out.ParameterGroupName + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.SnapshotArns != nil { + in, out := &in.SnapshotArns, &out.SnapshotArns + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnapshotName != nil { + in, out := &in.SnapshotName, &out.SnapshotName + *out = new(string) + **out = **in + } + if in.SnapshotRetentionLimit != nil { + in, out := &in.SnapshotRetentionLimit, &out.SnapshotRetentionLimit + *out = new(float64) + **out = **in + } + if in.SnapshotWindow != nil { + in, out := &in.SnapshotWindow, &out.SnapshotWindow + *out = new(string) + **out = **in + } + if in.SnsTopicArn != nil { + in, out := &in.SnsTopicArn, &out.SnsTopicArn + *out = new(string) + **out = **in + } + if in.TLSEnabled != nil { + in, out := &in.TLSEnabled, &out.TLSEnabled + *out = new(bool) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInitParameters. +func (in *ClusterInitParameters) DeepCopy() *ClusterInitParameters { + if in == nil { + return nil + } + out := new(ClusterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterList) DeepCopyInto(out *ClusterList) { *out = *in @@ -590,7 +825,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -605,7 +841,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -789,7 +1026,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -804,7 +1042,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -828,6 +1067,7 @@ func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. @@ -857,6 +1097,21 @@ func (in *ClusterStatus) DeepCopy() *ClusterStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EndpointInitParameters) DeepCopyInto(out *EndpointInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EndpointInitParameters. +func (in *EndpointInitParameters) DeepCopy() *EndpointInitParameters { + if in == nil { + return nil + } + out := new(EndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EndpointObservation) DeepCopyInto(out *EndpointObservation) { *out = *in @@ -897,6 +1152,21 @@ func (in *EndpointParameters) DeepCopy() *EndpointParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *NodesInitParameters) DeepCopyInto(out *NodesInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodesInitParameters. +func (in *NodesInitParameters) DeepCopy() *NodesInitParameters { + if in == nil { + return nil + } + out := new(NodesInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *NodesObservation) DeepCopyInto(out *NodesObservation) { *out = *in @@ -976,6 +1246,70 @@ func (in *ParameterGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterGroupInitParameters) DeepCopyInto(out *ParameterGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Family != nil { + in, out := &in.Family, &out.Family + *out = new(string) + **out = **in + } + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ParameterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupInitParameters. +func (in *ParameterGroupInitParameters) DeepCopy() *ParameterGroupInitParameters { + if in == nil { + return nil + } + out := new(ParameterGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterGroupList) DeepCopyInto(out *ParameterGroupList) { *out = *in @@ -1046,7 +1380,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1061,7 +1396,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1113,7 +1449,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1128,7 +1465,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1152,6 +1490,7 @@ func (in *ParameterGroupSpec) DeepCopyInto(out *ParameterGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupSpec. @@ -1181,6 +1520,31 @@ func (in *ParameterGroupStatus) DeepCopy() *ParameterGroupStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterInitParameters) DeepCopyInto(out *ParameterInitParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterInitParameters. +func (in *ParameterInitParameters) DeepCopy() *ParameterInitParameters { + if in == nil { + return nil + } + out := new(ParameterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterObservation) DeepCopyInto(out *ParameterObservation) { *out = *in @@ -1231,6 +1595,21 @@ func (in *ParameterParameters) DeepCopy() *ParameterParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ShardsInitParameters) DeepCopyInto(out *ShardsInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShardsInitParameters. +func (in *ShardsInitParameters) DeepCopy() *ShardsInitParameters { + if in == nil { + return nil + } + out := new(ShardsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ShardsObservation) DeepCopyInto(out *ShardsObservation) { *out = *in @@ -1310,6 +1689,53 @@ func (in *Snapshot) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SnapshotInitParameters) DeepCopyInto(out *SnapshotInitParameters) { + *out = *in + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotInitParameters. +func (in *SnapshotInitParameters) DeepCopy() *SnapshotInitParameters { + if in == nil { + return nil + } + out := new(SnapshotInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SnapshotList) DeepCopyInto(out *SnapshotList) { *out = *in @@ -1385,7 +1811,8 @@ func (in *SnapshotObservation) DeepCopyInto(out *SnapshotObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1400,7 +1827,8 @@ func (in *SnapshotObservation) DeepCopyInto(out *SnapshotObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1465,7 +1893,8 @@ func (in *SnapshotParameters) DeepCopyInto(out *SnapshotParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1480,7 +1909,8 @@ func (in *SnapshotParameters) DeepCopyInto(out *SnapshotParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1504,6 +1934,7 @@ func (in *SnapshotSpec) DeepCopyInto(out *SnapshotSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotSpec. @@ -1560,6 +1991,58 @@ func (in *SubnetGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SubnetGroupInitParameters) DeepCopyInto(out *SubnetGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupInitParameters. +func (in *SubnetGroupInitParameters) DeepCopy() *SubnetGroupInitParameters { + if in == nil { + return nil + } + out := new(SubnetGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SubnetGroupList) DeepCopyInto(out *SubnetGroupList) { *out = *in @@ -1629,7 +2112,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1644,7 +2128,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1712,7 +2197,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1727,7 +2213,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1751,6 +2238,7 @@ func (in *SubnetGroupSpec) DeepCopyInto(out *SubnetGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupSpec. diff --git a/apis/memorydb/v1alpha1/zz_generated.managed.go b/apis/memorydb/v1alpha1/zz_generated.managed.go index 71042b1..cfa9d9f 100644 --- a/apis/memorydb/v1alpha1/zz_generated.managed.go +++ b/apis/memorydb/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *ACL) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ACL. -func (mg *ACL) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ACL. +func (mg *ACL) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ACL. @@ -27,14 +27,6 @@ func (mg *ACL) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ACL. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ACL) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ACL. func (mg *ACL) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *ACL) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ACL. -func (mg *ACL) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ACL. +func (mg *ACL) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ACL. @@ -65,14 +57,6 @@ func (mg *ACL) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ACL. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ACL) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ACL. func (mg *ACL) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *Cluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Cluster. -func (mg *Cluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Cluster. +func (mg *Cluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Cluster. @@ -103,14 +87,6 @@ func (mg *Cluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Cluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Cluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *Cluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Cluster. -func (mg *Cluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Cluster. +func (mg *Cluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Cluster. @@ -141,14 +117,6 @@ func (mg *Cluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Cluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Cluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *ParameterGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ParameterGroup. @@ -179,14 +147,6 @@ func (mg *ParameterGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ParameterGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ParameterGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *ParameterGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ParameterGroup. @@ -217,14 +177,6 @@ func (mg *ParameterGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ParameterGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ParameterGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *Snapshot) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Snapshot. -func (mg *Snapshot) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Snapshot. +func (mg *Snapshot) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Snapshot. @@ -255,14 +207,6 @@ func (mg *Snapshot) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Snapshot. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Snapshot) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Snapshot. func (mg *Snapshot) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *Snapshot) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Snapshot. -func (mg *Snapshot) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Snapshot. +func (mg *Snapshot) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Snapshot. @@ -293,14 +237,6 @@ func (mg *Snapshot) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Snapshot. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Snapshot) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Snapshot. func (mg *Snapshot) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *SubnetGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SubnetGroup. @@ -331,14 +267,6 @@ func (mg *SubnetGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SubnetGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SubnetGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *SubnetGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SubnetGroup. @@ -369,14 +297,6 @@ func (mg *SubnetGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SubnetGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SubnetGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/memorydb/v1alpha1/zz_generated.resolvers.go b/apis/memorydb/v1alpha1/zz_generated.resolvers.go index 5973ff0..0add70c 100644 --- a/apis/memorydb/v1alpha1/zz_generated.resolvers.go +++ b/apis/memorydb/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" v1alpha11 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" v1alpha1 "kubedb.dev/provider-aws/apis/kms/v1alpha1" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/memorydb/v1alpha1/zz_generated_terraformed.go b/apis/memorydb/v1alpha1/zz_generated_terraformed.go index 5ad6d2a..5b10f1f 100755 --- a/apis/memorydb/v1alpha1/zz_generated_terraformed.go +++ b/apis/memorydb/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this ACL @@ -69,6 +74,46 @@ func (tr *ACL) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ACL +func (tr *ACL) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ACL +func (tr *ACL) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ACL using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ACL) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *Cluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Cluster +func (tr *Cluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Cluster +func (tr *Cluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Cluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Cluster) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *ParameterGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ParameterGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ParameterGroup) LateInitialize(attrs []byte) (bool, error) { @@ -291,6 +416,46 @@ func (tr *Snapshot) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Snapshot +func (tr *Snapshot) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Snapshot +func (tr *Snapshot) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Snapshot using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Snapshot) LateInitialize(attrs []byte) (bool, error) { @@ -365,6 +530,46 @@ func (tr *SubnetGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SubnetGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SubnetGroup) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/memorydb/v1alpha1/zz_groupversion_info.go b/apis/memorydb/v1alpha1/zz_groupversion_info.go index ab7a389..e95843e 100755 --- a/apis/memorydb/v1alpha1/zz_groupversion_info.go +++ b/apis/memorydb/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/memorydb/v1alpha1/zz_parametergroup_types.go b/apis/memorydb/v1alpha1/zz_parametergroup_types.go index 650e977..52c42ab 100755 --- a/apis/memorydb/v1alpha1/zz_parametergroup_types.go +++ b/apis/memorydb/v1alpha1/zz_parametergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ParameterGroupInitParameters struct { + + // Description for the parameter group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // The engine version that the parameter group can be used with. + Family *string `json:"family,omitempty" tf:"family,omitempty"` + + // Set of MemoryDB parameters to apply. Any parameters not specified will fall back to their family defaults. Detailed below. + Parameter []ParameterInitParameters `json:"parameter,omitempty" tf:"parameter,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ParameterGroupObservation struct { // The ARN of the parameter group. @@ -65,6 +87,15 @@ type ParameterGroupParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ParameterInitParameters struct { + + // The name of the parameter. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The value of the parameter. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type ParameterObservation struct { // The name of the parameter. @@ -77,11 +108,11 @@ type ParameterObservation struct { type ParameterParameters struct { // The name of the parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The value of the parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -89,6 +120,17 @@ type ParameterParameters struct { type ParameterGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ParameterGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ParameterGroupInitParameters `json:"initProvider,omitempty"` } // ParameterGroupStatus defines the observed state of ParameterGroup. @@ -109,8 +151,8 @@ type ParameterGroupStatus struct { type ParameterGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family)",message="family is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.family) || (has(self.initProvider) && has(self.initProvider.family))",message="spec.forProvider.family is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ParameterGroupSpec `json:"spec"` Status ParameterGroupStatus `json:"status,omitempty"` } diff --git a/apis/memorydb/v1alpha1/zz_snapshot_types.go b/apis/memorydb/v1alpha1/zz_snapshot_types.go index b58579a..ae09211 100755 --- a/apis/memorydb/v1alpha1/zz_snapshot_types.go +++ b/apis/memorydb/v1alpha1/zz_snapshot_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,9 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterConfigurationInitParameters struct { +} + type ClusterConfigurationObservation struct { // Description for the cluster. @@ -58,6 +65,15 @@ type ClusterConfigurationObservation struct { type ClusterConfigurationParameters struct { } +type SnapshotInitParameters struct { + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SnapshotObservation struct { // The ARN of the snapshot. @@ -131,6 +147,17 @@ type SnapshotParameters struct { type SnapshotSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SnapshotParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SnapshotInitParameters `json:"initProvider,omitempty"` } // SnapshotStatus defines the observed state of Snapshot. @@ -151,7 +178,7 @@ type SnapshotStatus struct { type Snapshot struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SnapshotSpec `json:"spec"` Status SnapshotStatus `json:"status,omitempty"` } diff --git a/apis/memorydb/v1alpha1/zz_subnetgroup_types.go b/apis/memorydb/v1alpha1/zz_subnetgroup_types.go index a4e38e2..842f597 100755 --- a/apis/memorydb/v1alpha1/zz_subnetgroup_types.go +++ b/apis/memorydb/v1alpha1/zz_subnetgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SubnetGroupInitParameters struct { + + // Description for the subnet group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SubnetGroupObservation struct { // The ARN of the subnet group. @@ -76,6 +92,17 @@ type SubnetGroupParameters struct { type SubnetGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SubnetGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SubnetGroupInitParameters `json:"initProvider,omitempty"` } // SubnetGroupStatus defines the observed state of SubnetGroup. @@ -96,7 +123,7 @@ type SubnetGroupStatus struct { type SubnetGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SubnetGroupSpec `json:"spec"` Status SubnetGroupStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_cluster_types.go b/apis/rds/v1alpha1/zz_cluster_types.go index 80b4b71..b965d45 100755 --- a/apis/rds/v1alpha1/zz_cluster_types.go +++ b/apis/rds/v1alpha1/zz_cluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,134 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterInitParameters struct { + + // The amount of storage in gibibytes (GiB) to allocate to each DB instance in the Multi-AZ DB cluster. + AllocatedStorage *float64 `json:"allocatedStorage,omitempty" tf:"allocated_storage,omitempty"` + + // Enable to allow major engine version upgrades when changing engine versions. Defaults to false. + AllowMajorVersionUpgrade *bool `json:"allowMajorVersionUpgrade,omitempty" tf:"allow_major_version_upgrade,omitempty"` + + // Specifies whether any cluster modifications are applied immediately, or during the next maintenance window. Default is false. See Amazon RDS Documentation for more information. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // List of EC2 Availability Zones for the DB cluster storage where DB cluster instances can be created. We recommend specifying 3 AZs or using the if necessary. A maximum of 3 AZs can be configured. + AvailabilityZones []*string `json:"availabilityZones,omitempty" tf:"availability_zones,omitempty"` + + // Target backtrack window, in seconds. Only available for aurora and aurora-mysql engines currently. To disable backtracking, set this value to 0. Defaults to 0. Must be between 0 and 259200 (72 hours) + BacktrackWindow *float64 `json:"backtrackWindow,omitempty" tf:"backtrack_window,omitempty"` + + // Days to retain backups for. Default 1 + BackupRetentionPeriod *float64 `json:"backupRetentionPeriod,omitempty" tf:"backup_retention_period,omitempty"` + + // – List of RDS Instances that are a part of this cluster + ClusterMembers []*string `json:"clusterMembers,omitempty" tf:"cluster_members,omitempty"` + + // – Copy all Cluster tags to snapshots. Default is false. + CopyTagsToSnapshot *bool `json:"copyTagsToSnapshot,omitempty" tf:"copy_tags_to_snapshot,omitempty"` + + // Compute and memory capacity of each DB instance in the Multi-AZ DB cluster, for example db.m6g.xlarge. Not all DB instance classes are available in all AWS Regions, or for all database engines. For the full list of DB instance classes and availability for your engine, see DB instance class in the Amazon RDS User Guide. (This setting is required to create a Multi-AZ DB cluster). + DBClusterInstanceClass *string `json:"dbClusterInstanceClass,omitempty" tf:"db_cluster_instance_class,omitempty"` + + DBClusterParameterGroupName *string `json:"dbClusterParameterGroupName,omitempty" tf:"db_cluster_parameter_group_name,omitempty"` + + // Instance parameter group to associate with all instances of the DB cluster. The db_instance_parameter_group_name parameter is only valid in combination with the allow_major_version_upgrade parameter. + DBInstanceParameterGroupName *string `json:"dbInstanceParameterGroupName,omitempty" tf:"db_instance_parameter_group_name,omitempty"` + + // Name for an automatically created database on cluster creation. There are different naming restrictions per database engine: RDS Naming Constraints + DatabaseName *string `json:"databaseName,omitempty" tf:"database_name,omitempty"` + + // If the DB instance should have deletion protection enabled. The database can't be deleted when this value is set to true. The default is false. + DeletionProtection *bool `json:"deletionProtection,omitempty" tf:"deletion_protection,omitempty"` + + // Whether cluster should forward writes to an associated global cluster. Applied to secondary clusters to enable them to forward writes to an aws_rds_global_cluster's primary cluster. See the Aurora Userguide documentation for more information. + EnableGlobalWriteForwarding *bool `json:"enableGlobalWriteForwarding,omitempty" tf:"enable_global_write_forwarding,omitempty"` + + // Enable HTTP endpoint (data API). Only valid when engine_mode is set to serverless. + EnableHTTPEndpoint *bool `json:"enableHttpEndpoint,omitempty" tf:"enable_http_endpoint,omitempty"` + + // Set of log types to export to cloudwatch. If omitted, no logs will be exported. The following log types are supported: audit, error, general, slowquery, postgresql (PostgreSQL). + EnabledCloudwatchLogsExports []*string `json:"enabledCloudwatchLogsExports,omitempty" tf:"enabled_cloudwatch_logs_exports,omitempty"` + + // Name of the database engine to be used for this DB cluster. Valid Values: aurora-mysql, aurora-postgresql, mysql, postgres. (Note that mysql and postgres are Multi-AZ RDS clusters). + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Database engine mode. Valid values: global (only valid for Aurora MySQL 1.21 and earlier), multimaster, parallelquery, provisioned, serverless. Defaults to: provisioned. See the RDS User Guide for limitations when using serverless. + EngineMode *string `json:"engineMode,omitempty" tf:"engine_mode,omitempty"` + + // Database engine version. Updating this argument results in an outage. See the Aurora MySQL and Aurora Postgres documentation for your configured engine to determine this value, or by running aws rds describe-db-engine-versions. For example with Aurora MySQL 2, a potential value for this argument is 5.7.mysql_aurora.2.03.2. The value can contain a partial version where supported by the API. The actual engine version used is returned in the attribute engine_version_actual, , see Attributes Reference below. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // Name of your final DB snapshot when this DB cluster is deleted. If omitted, no final snapshot will be made. + FinalSnapshotIdentifier *string `json:"finalSnapshotIdentifier,omitempty" tf:"final_snapshot_identifier,omitempty"` + + // Global cluster identifier specified on aws_rds_global_cluster. + GlobalClusterIdentifier *string `json:"globalClusterIdentifier,omitempty" tf:"global_cluster_identifier,omitempty"` + + // Specifies whether or not mappings of AWS Identity and Access Management (IAM) accounts to database accounts is enabled. Please see AWS Documentation for availability and limitations. + IAMDatabaseAuthenticationEnabled *bool `json:"iamDatabaseAuthenticationEnabled,omitempty" tf:"iam_database_authentication_enabled,omitempty"` + + // Amount of Provisioned IOPS (input/output operations per second) to be initially allocated for each DB instance in the Multi-AZ DB cluster. For information about valid Iops values, see Amazon RDS Provisioned IOPS storage to improve performance in the Amazon RDS User Guide. (This setting is required to create a Multi-AZ DB cluster). Must be a multiple between .5 and 50 of the storage amount for the DB cluster. + Iops *float64 `json:"iops,omitempty" tf:"iops,omitempty"` + + // Set to true to allow RDS to manage the master user password in Secrets Manager. Cannot be set if master_password is provided. + ManageMasterUserPassword *bool `json:"manageMasterUserPassword,omitempty" tf:"manage_master_user_password,omitempty"` + + // Username for the master DB user. Please refer to the RDS Naming Constraints. This argument does not support in-place updates and cannot be changed during a restore from snapshot. + MasterUsername *string `json:"masterUsername,omitempty" tf:"master_username,omitempty"` + + // Network type of the cluster. Valid values: IPV4, DUAL. + NetworkType *string `json:"networkType,omitempty" tf:"network_type,omitempty"` + + // Port on which the DB accepts connections + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // Daily time range during which automated backups are created if automated backups are enabled using the BackupRetentionPeriod parameter.Time in UTC. Default: A 30-minute window selected at random from an 8-hour block of time per regionE.g., 04:00-09:00 + PreferredBackupWindow *string `json:"preferredBackupWindow,omitempty" tf:"preferred_backup_window,omitempty"` + + // Weekly time range during which system maintenance can occur, in (UTC) e.g., wed:04:00-wed:04:30 + PreferredMaintenanceWindow *string `json:"preferredMaintenanceWindow,omitempty" tf:"preferred_maintenance_window,omitempty"` + + // ARN of a source DB cluster or DB instance if this DB cluster is to be created as a Read Replica. + ReplicationSourceIdentifier *string `json:"replicationSourceIdentifier,omitempty" tf:"replication_source_identifier,omitempty"` + + // Nested attribute for point in time restore. More details below. + RestoreToPointInTime []ClusterRestoreToPointInTimeInitParameters `json:"restoreToPointInTime,omitempty" tf:"restore_to_point_in_time,omitempty"` + + // Port on which the DB accepts connections + S3Import []ClusterS3ImportInitParameters `json:"s3Import,omitempty" tf:"s3_import,omitempty"` + + // Nested attribute with scaling properties. Only valid when engine_mode is set to serverless. More details below. + ScalingConfiguration []ScalingConfigurationInitParameters `json:"scalingConfiguration,omitempty" tf:"scaling_configuration,omitempty"` + + // Nested attribute with scaling properties for ServerlessV2. Only valid when engine_mode is set to provisioned. More details below. + Serverlessv2ScalingConfiguration []Serverlessv2ScalingConfigurationInitParameters `json:"serverlessv2ScalingConfiguration,omitempty" tf:"serverlessv2_scaling_configuration,omitempty"` + + // Determines whether a final DB snapshot is created before the DB cluster is deleted. If true is specified, no DB snapshot is created. If false is specified, a DB snapshot is created before the DB cluster is deleted, using the value from final_snapshot_identifier. Default is false. + SkipFinalSnapshot *bool `json:"skipFinalSnapshot,omitempty" tf:"skip_final_snapshot,omitempty"` + + // Specifies whether or not to create this cluster from a snapshot. You can use either the name or ARN when specifying a DB cluster snapshot, or the ARN when specifying a DB snapshot. Conflicts with global_cluster_identifier. Clusters cannot be restored from snapshot and joined to an existing global cluster in a single operation. See the AWS documentation or the Global Cluster Restored From Snapshot example for instructions on building a global cluster starting with a snapshot. + SnapshotIdentifier *string `json:"snapshotIdentifier,omitempty" tf:"snapshot_identifier,omitempty"` + + // The source region for an encrypted replica DB cluster. + SourceRegion *string `json:"sourceRegion,omitempty" tf:"source_region,omitempty"` + + // Specifies whether the DB cluster is encrypted. The default is false for provisioned engine_mode and true for serverless engine_mode. When restoring an unencrypted snapshot_identifier, the kms_key_id argument must be provided to encrypt the restored cluster. + StorageEncrypted *bool `json:"storageEncrypted,omitempty" tf:"storage_encrypted,omitempty"` + + // (Forces new for Multi-AZ DB clusters) Specifies the storage type to be associated with the DB cluster. For Aurora DB clusters, storage_type modifications can be done in-place. For Multi-AZ DB Clusters, the iops argument must also be set. Valid values are: "", aurora-iopt1 (Aurora DB Clusters); io1 (Multi-AZ DB Clusters). Default: "" (Aurora DB Clusters); io1 (Multi-AZ DB Clusters). + StorageType *string `json:"storageType,omitempty" tf:"storage_type,omitempty"` + + // A map of tags to assign to the DB cluster. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + +type ClusterMasterUserSecretInitParameters struct { +} + type ClusterMasterUserSecretObservation struct { // Amazon Web Services KMS key identifier that is used to encrypt the secret. @@ -322,7 +454,7 @@ type ClusterParameters struct { // Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. To use a KMS key in a different Amazon Web Services account, specify the key ARN or alias ARN. If not specified, the default KMS key for your Amazon Web Services account is used. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/kms/v1alpha1.Key - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("key_id",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("key_id",true) // +kubebuilder:validation:Optional MasterUserSecretKMSKeyID *string `json:"masterUserSecretKmsKeyId,omitempty" tf:"master_user_secret_kms_key_id,omitempty"` @@ -423,6 +555,19 @@ type ClusterParameters struct { VPCSecurityGroupIds []*string `json:"vpcSecurityGroupIds,omitempty" tf:"vpc_security_group_ids,omitempty"` } +type ClusterRestoreToPointInTimeInitParameters struct { + + // Date and time in UTC format to restore the database cluster to. Conflicts with use_latest_restorable_time. + RestoreToTime *string `json:"restoreToTime,omitempty" tf:"restore_to_time,omitempty"` + + // Type of restore to be performed. + // Valid options are full-copy (default) and copy-on-write. + RestoreType *string `json:"restoreType,omitempty" tf:"restore_type,omitempty"` + + // Set to true to restore the database cluster to the latest restorable backup time. Defaults to false. Conflicts with restore_to_time. + UseLatestRestorableTime *bool `json:"useLatestRestorableTime,omitempty" tf:"use_latest_restorable_time,omitempty"` +} + type ClusterRestoreToPointInTimeObservation struct { // Date and time in UTC format to restore the database cluster to. Conflicts with use_latest_restorable_time. @@ -468,6 +613,24 @@ type ClusterRestoreToPointInTimeParameters struct { UseLatestRestorableTime *bool `json:"useLatestRestorableTime,omitempty" tf:"use_latest_restorable_time,omitempty"` } +type ClusterS3ImportInitParameters struct { + + // Bucket name where your backup is stored + BucketName *string `json:"bucketName,omitempty" tf:"bucket_name,omitempty"` + + // Can be blank, but is the path to your backup + BucketPrefix *string `json:"bucketPrefix,omitempty" tf:"bucket_prefix,omitempty"` + + // Role applied to load the data. + IngestionRole *string `json:"ingestionRole,omitempty" tf:"ingestion_role,omitempty"` + + // Source engine for the backup + SourceEngine *string `json:"sourceEngine,omitempty" tf:"source_engine,omitempty"` + + // Version of the source engine used to make the backup + SourceEngineVersion *string `json:"sourceEngineVersion,omitempty" tf:"source_engine_version,omitempty"` +} + type ClusterS3ImportObservation struct { // Bucket name where your backup is stored @@ -489,7 +652,7 @@ type ClusterS3ImportObservation struct { type ClusterS3ImportParameters struct { // Bucket name where your backup is stored - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional BucketName *string `json:"bucketName" tf:"bucket_name,omitempty"` // Can be blank, but is the path to your backup @@ -497,18 +660,36 @@ type ClusterS3ImportParameters struct { BucketPrefix *string `json:"bucketPrefix,omitempty" tf:"bucket_prefix,omitempty"` // Role applied to load the data. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional IngestionRole *string `json:"ingestionRole" tf:"ingestion_role,omitempty"` // Source engine for the backup - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional SourceEngine *string `json:"sourceEngine" tf:"source_engine,omitempty"` // Version of the source engine used to make the backup - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional SourceEngineVersion *string `json:"sourceEngineVersion" tf:"source_engine_version,omitempty"` } +type ScalingConfigurationInitParameters struct { + + // Whether to enable automatic pause. A DB cluster can be paused only when it's idle (it has no connections). If a DB cluster is paused for more than seven days, the DB cluster might be backed up with a snapshot. In this case, the DB cluster is restored when there is a request to connect to it. Defaults to true. + AutoPause *bool `json:"autoPause,omitempty" tf:"auto_pause,omitempty"` + + // Maximum capacity for an Aurora DB cluster in serverless DB engine mode. The maximum capacity must be greater than or equal to the minimum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 16. + MaxCapacity *float64 `json:"maxCapacity,omitempty" tf:"max_capacity,omitempty"` + + // Minimum capacity for an Aurora DB cluster in serverless DB engine mode. The minimum capacity must be lesser than or equal to the maximum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 1. + MinCapacity *float64 `json:"minCapacity,omitempty" tf:"min_capacity,omitempty"` + + // Time, in seconds, before an Aurora DB cluster in serverless mode is paused. Valid values are 300 through 86400. Defaults to 300. + SecondsUntilAutoPause *float64 `json:"secondsUntilAutoPause,omitempty" tf:"seconds_until_auto_pause,omitempty"` + + // Action to take when the timeout is reached. Valid values: ForceApplyCapacityChange, RollbackCapacityChange. Defaults to RollbackCapacityChange. See documentation. + TimeoutAction *string `json:"timeoutAction,omitempty" tf:"timeout_action,omitempty"` +} + type ScalingConfigurationObservation struct { // Whether to enable automatic pause. A DB cluster can be paused only when it's idle (it has no connections). If a DB cluster is paused for more than seven days, the DB cluster might be backed up with a snapshot. In this case, the DB cluster is restored when there is a request to connect to it. Defaults to true. @@ -550,6 +731,15 @@ type ScalingConfigurationParameters struct { TimeoutAction *string `json:"timeoutAction,omitempty" tf:"timeout_action,omitempty"` } +type Serverlessv2ScalingConfigurationInitParameters struct { + + // Maximum capacity for an Aurora DB cluster in serverless DB engine mode. The maximum capacity must be greater than or equal to the minimum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 16. + MaxCapacity *float64 `json:"maxCapacity,omitempty" tf:"max_capacity,omitempty"` + + // Minimum capacity for an Aurora DB cluster in serverless DB engine mode. The minimum capacity must be lesser than or equal to the maximum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 1. + MinCapacity *float64 `json:"minCapacity,omitempty" tf:"min_capacity,omitempty"` +} + type Serverlessv2ScalingConfigurationObservation struct { // Maximum capacity for an Aurora DB cluster in serverless DB engine mode. The maximum capacity must be greater than or equal to the minimum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 16. @@ -562,11 +752,11 @@ type Serverlessv2ScalingConfigurationObservation struct { type Serverlessv2ScalingConfigurationParameters struct { // Maximum capacity for an Aurora DB cluster in serverless DB engine mode. The maximum capacity must be greater than or equal to the minimum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 16. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional MaxCapacity *float64 `json:"maxCapacity" tf:"max_capacity,omitempty"` // Minimum capacity for an Aurora DB cluster in serverless DB engine mode. The minimum capacity must be lesser than or equal to the maximum capacity. Valid Aurora MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 1. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional MinCapacity *float64 `json:"minCapacity" tf:"min_capacity,omitempty"` } @@ -574,6 +764,17 @@ type Serverlessv2ScalingConfigurationParameters struct { type ClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInitParameters `json:"initProvider,omitempty"` } // ClusterStatus defines the observed state of Cluster. @@ -594,8 +795,8 @@ type ClusterStatus struct { type Cluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine)",message="engine is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSpec `json:"spec"` Status ClusterStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clusteractivitystream_types.go b/apis/rds/v1alpha1/zz_clusteractivitystream_types.go index 6d5431c..289ce4e 100755 --- a/apis/rds/v1alpha1/zz_clusteractivitystream_types.go +++ b/apis/rds/v1alpha1/zz_clusteractivitystream_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterActivityStreamInitParameters struct { + + // Specifies whether the database activity stream includes engine-native audit fields. This option only applies to an Oracle DB instance. By default, no engine-native audit fields are included. Defaults false. + EngineNativeAuditFieldsIncluded *bool `json:"engineNativeAuditFieldsIncluded,omitempty" tf:"engine_native_audit_fields_included,omitempty"` + + // Specifies the mode of the database activity stream. Database events such as a change or access generate an activity stream event. The database session can handle these events either synchronously or asynchronously. One of: sync, async. + Mode *string `json:"mode,omitempty" tf:"mode,omitempty"` +} + type ClusterActivityStreamObservation struct { // Specifies whether the database activity stream includes engine-native audit fields. This option only applies to an Oracle DB instance. By default, no engine-native audit fields are included. Defaults false. @@ -64,7 +77,7 @@ type ClusterActivityStreamParameters struct { // The Amazon Resource Name (ARN) of the DB cluster. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true) // +kubebuilder:validation:Optional ResourceArn *string `json:"resourceArn,omitempty" tf:"resource_arn,omitempty"` @@ -81,6 +94,17 @@ type ClusterActivityStreamParameters struct { type ClusterActivityStreamSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterActivityStreamParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterActivityStreamInitParameters `json:"initProvider,omitempty"` } // ClusterActivityStreamStatus defines the observed state of ClusterActivityStream. @@ -101,8 +125,8 @@ type ClusterActivityStreamStatus struct { type ClusterActivityStream struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.mode)",message="mode is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.mode) || (has(self.initProvider) && has(self.initProvider.mode))",message="spec.forProvider.mode is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterActivityStreamSpec `json:"spec"` Status ClusterActivityStreamStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clusterendpoint_types.go b/apis/rds/v1alpha1/zz_clusterendpoint_types.go index d624d00..eaf87ed 100755 --- a/apis/rds/v1alpha1/zz_clusterendpoint_types.go +++ b/apis/rds/v1alpha1/zz_clusterendpoint_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterEndpointInitParameters struct { + + // The type of the endpoint. One of: READER , ANY . + CustomEndpointType *string `json:"customEndpointType,omitempty" tf:"custom_endpoint_type,omitempty"` + + // List of DB instance identifiers that aren't part of the custom endpoint group. All other eligible instances are reachable through the custom endpoint. Only relevant if the list of static members is empty. Conflicts with static_members. + ExcludedMembers []*string `json:"excludedMembers,omitempty" tf:"excluded_members,omitempty"` + + // List of DB instance identifiers that are part of the custom endpoint group. Conflicts with excluded_members. + StaticMembers []*string `json:"staticMembers,omitempty" tf:"static_members,omitempty"` + + // Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterEndpointObservation struct { // Amazon Resource Name (ARN) of cluster @@ -47,7 +69,7 @@ type ClusterEndpointParameters struct { // The cluster identifier. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional ClusterIdentifier *string `json:"clusterIdentifier,omitempty" tf:"cluster_identifier,omitempty"` @@ -89,6 +111,17 @@ type ClusterEndpointParameters struct { type ClusterEndpointSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterEndpointParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterEndpointInitParameters `json:"initProvider,omitempty"` } // ClusterEndpointStatus defines the observed state of ClusterEndpoint. @@ -109,8 +142,8 @@ type ClusterEndpointStatus struct { type ClusterEndpoint struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.customEndpointType)",message="customEndpointType is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.customEndpointType) || (has(self.initProvider) && has(self.initProvider.customEndpointType))",message="spec.forProvider.customEndpointType is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterEndpointSpec `json:"spec"` Status ClusterEndpointStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clusterinstance_types.go b/apis/rds/v1alpha1/zz_clusterinstance_types.go index bff3201..2d12a90 100755 --- a/apis/rds/v1alpha1/zz_clusterinstance_types.go +++ b/apis/rds/v1alpha1/zz_clusterinstance_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,66 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterInstanceInitParameters struct { + + // Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default isfalse. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default true. + AutoMinorVersionUpgrade *bool `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // EC2 Availability Zone that the DB instance is created in. See docs about the details. + AvailabilityZone *string `json:"availabilityZone,omitempty" tf:"availability_zone,omitempty"` + + // Identifier of the CA certificate for the DB instance. + CACertIdentifier *string `json:"caCertIdentifier,omitempty" tf:"ca_cert_identifier,omitempty"` + + // defined tags from the DB instance to snapshots of the DB instance. Default false. + CopyTagsToSnapshot *bool `json:"copyTagsToSnapshot,omitempty" tf:"copy_tags_to_snapshot,omitempty"` + + // Name of the DB parameter group to associate with this instance. + DBParameterGroupName *string `json:"dbParameterGroupName,omitempty" tf:"db_parameter_group_name,omitempty"` + + // Name of the database engine to be used for the RDS instance. Valid Values: aurora-mysql, aurora-postgresql, mysql, postgres. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Database engine version. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // Instance class to use. For details on CPU and memory, see Scaling Aurora DB Instances. Aurora uses db.* instance classes/types. Please see AWS Documentation for currently available instance classes and complete details. + InstanceClass *string `json:"instanceClass,omitempty" tf:"instance_class,omitempty"` + + // Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60. + MonitoringInterval *float64 `json:"monitoringInterval,omitempty" tf:"monitoring_interval,omitempty"` + + // ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the AWS Documentation what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances. + MonitoringRoleArn *string `json:"monitoringRoleArn,omitempty" tf:"monitoring_role_arn,omitempty"` + + // Specifies whether Performance Insights is enabled or not. + PerformanceInsightsEnabled *bool `json:"performanceInsightsEnabled,omitempty" tf:"performance_insights_enabled,omitempty"` + + // Amount of time in days to retain Performance Insights data. Valid values are 7, 731 (2 years) or a multiple of 31. When specifying performance_insights_retention_period, performance_insights_enabled needs to be set to true. Defaults to '7'. + PerformanceInsightsRetentionPeriod *float64 `json:"performanceInsightsRetentionPeriod,omitempty" tf:"performance_insights_retention_period,omitempty"` + + // Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". NOTE: If preferred_backup_window is set at the cluster level, this argument must be omitted. + PreferredBackupWindow *string `json:"preferredBackupWindow,omitempty" tf:"preferred_backup_window,omitempty"` + + // Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00". + PreferredMaintenanceWindow *string `json:"preferredMaintenanceWindow,omitempty" tf:"preferred_maintenance_window,omitempty"` + + // Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer. + PromotionTier *float64 `json:"promotionTier,omitempty" tf:"promotion_tier,omitempty"` + + // Bool to control if instance is publicly accessible. Default false. See the documentation on Creating DB Instances for more details on controlling this property. + PubliclyAccessible *bool `json:"publiclyAccessible,omitempty" tf:"publicly_accessible,omitempty"` + + // Map of tags to assign to the instance. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // Map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterInstanceObservation struct { // Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default isfalse. @@ -132,7 +196,7 @@ type ClusterInstanceParameters struct { // Identifier of the aws_rds_cluster in which to launch this instance. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional ClusterIdentifier *string `json:"clusterIdentifier,omitempty" tf:"cluster_identifier,omitempty"` @@ -240,6 +304,17 @@ type ClusterInstanceParameters struct { type ClusterInstanceSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterInstanceParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterInstanceInitParameters `json:"initProvider,omitempty"` } // ClusterInstanceStatus defines the observed state of ClusterInstance. @@ -260,9 +335,9 @@ type ClusterInstanceStatus struct { type ClusterInstance struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine)",message="engine is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass)",message="instanceClass is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.instanceClass) || (has(self.initProvider) && has(self.initProvider.instanceClass))",message="spec.forProvider.instanceClass is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterInstanceSpec `json:"spec"` Status ClusterInstanceStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clusterparametergroup_types.go b/apis/rds/v1alpha1/zz_clusterparametergroup_types.go index 231cb7e..aa6becf 100755 --- a/apis/rds/v1alpha1/zz_clusterparametergroup_types.go +++ b/apis/rds/v1alpha1/zz_clusterparametergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterParameterGroupInitParameters struct { + + // The description of the DB cluster parameter group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // The family of the DB cluster parameter group. + Family *string `json:"family,omitempty" tf:"family,omitempty"` + + // A list of DB parameters to apply. Note that parameters may differ from a family to an other. Full list of all parameters can be discovered via aws rds describe-db-cluster-parameters after initial creation of the group. + Parameter []ClusterParameterGroupParameterInitParameters `json:"parameter,omitempty" tf:"parameter,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterParameterGroupObservation struct { // The ARN of the db cluster parameter group. @@ -37,6 +59,20 @@ type ClusterParameterGroupObservation struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ClusterParameterGroupParameterInitParameters struct { + + // "immediate" (default), or "pending-reboot". Some + // engines can't apply some parameters without a reboot, and you will need to + // specify "pending-reboot" here. + ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` + + // The name of the DB cluster parameter group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The value of the DB parameter. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type ClusterParameterGroupParameterObservation struct { // "immediate" (default), or "pending-reboot". Some @@ -60,11 +96,11 @@ type ClusterParameterGroupParameterParameters struct { ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` // The name of the DB cluster parameter group. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The value of the DB parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -100,6 +136,17 @@ type ClusterParameterGroupParameters struct { type ClusterParameterGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterParameterGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterParameterGroupInitParameters `json:"initProvider,omitempty"` } // ClusterParameterGroupStatus defines the observed state of ClusterParameterGroup. @@ -120,8 +167,8 @@ type ClusterParameterGroupStatus struct { type ClusterParameterGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family)",message="family is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.family) || (has(self.initProvider) && has(self.initProvider.family))",message="spec.forProvider.family is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterParameterGroupSpec `json:"spec"` Status ClusterParameterGroupStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clusterroleassociation_types.go b/apis/rds/v1alpha1/zz_clusterroleassociation_types.go index bf59ab6..c189ef3 100755 --- a/apis/rds/v1alpha1/zz_clusterroleassociation_types.go +++ b/apis/rds/v1alpha1/zz_clusterroleassociation_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterRoleAssociationInitParameters struct { + + // Name of the feature for association. This can be found in the AWS documentation relevant to the integration or a full list is available in the SupportedFeatureNames list returned by AWS CLI rds describe-db-engine-versions. + FeatureName *string `json:"featureName,omitempty" tf:"feature_name,omitempty"` + + // Amazon Resource Name (ARN) of the IAM Role to associate with the DB Cluster. + RoleArn *string `json:"roleArn,omitempty" tf:"role_arn,omitempty"` +} + type ClusterRoleAssociationObservation struct { // DB Cluster Identifier to associate with the IAM Role. @@ -32,7 +45,7 @@ type ClusterRoleAssociationParameters struct { // DB Cluster Identifier to associate with the IAM Role. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional DBClusterIdentifier *string `json:"dbClusterIdentifier,omitempty" tf:"db_cluster_identifier,omitempty"` @@ -62,6 +75,17 @@ type ClusterRoleAssociationParameters struct { type ClusterRoleAssociationSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterRoleAssociationParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterRoleAssociationInitParameters `json:"initProvider,omitempty"` } // ClusterRoleAssociationStatus defines the observed state of ClusterRoleAssociation. @@ -82,9 +106,9 @@ type ClusterRoleAssociationStatus struct { type ClusterRoleAssociation struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.featureName)",message="featureName is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn)",message="roleArn is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.featureName) || (has(self.initProvider) && has(self.initProvider.featureName))",message="spec.forProvider.featureName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.roleArn) || (has(self.initProvider) && has(self.initProvider.roleArn))",message="spec.forProvider.roleArn is a required parameter" Spec ClusterRoleAssociationSpec `json:"spec"` Status ClusterRoleAssociationStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_clustersnapshot_types.go b/apis/rds/v1alpha1/zz_clustersnapshot_types.go index 6784136..f1640c1 100755 --- a/apis/rds/v1alpha1/zz_clustersnapshot_types.go +++ b/apis/rds/v1alpha1/zz_clustersnapshot_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ClusterSnapshotInitParameters struct { + + // The Identifier for the snapshot. + DBClusterSnapshotIdentifier *string `json:"dbClusterSnapshotIdentifier,omitempty" tf:"db_cluster_snapshot_identifier,omitempty"` + + // A map of tags to assign to the DB cluster. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ClusterSnapshotObservation struct { // Allocated storage size in gigabytes (GB). @@ -72,7 +88,7 @@ type ClusterSnapshotParameters struct { // The DB Cluster Identifier from which to take the snapshot. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractResourceID() + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractResourceID() // +kubebuilder:validation:Optional DBClusterIdentifier *string `json:"dbClusterIdentifier,omitempty" tf:"db_cluster_identifier,omitempty"` @@ -106,6 +122,17 @@ type ClusterSnapshotParameters struct { type ClusterSnapshotSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ClusterSnapshotParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ClusterSnapshotInitParameters `json:"initProvider,omitempty"` } // ClusterSnapshotStatus defines the observed state of ClusterSnapshot. @@ -126,8 +153,8 @@ type ClusterSnapshotStatus struct { type ClusterSnapshot struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.dbClusterSnapshotIdentifier)",message="dbClusterSnapshotIdentifier is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.dbClusterSnapshotIdentifier) || (has(self.initProvider) && has(self.initProvider.dbClusterSnapshotIdentifier))",message="spec.forProvider.dbClusterSnapshotIdentifier is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ClusterSnapshotSpec `json:"spec"` Status ClusterSnapshotStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_dbinstanceautomatedbackupsreplication_types.go b/apis/rds/v1alpha1/zz_dbinstanceautomatedbackupsreplication_types.go index 9db31e9..4ce759b 100755 --- a/apis/rds/v1alpha1/zz_dbinstanceautomatedbackupsreplication_types.go +++ b/apis/rds/v1alpha1/zz_dbinstanceautomatedbackupsreplication_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type DBInstanceAutomatedBackupsReplicationInitParameters struct { + + // A URL that contains a Signature Version 4 signed request for the StartDBInstanceAutomatedBackupsReplication action to be called in the AWS Region of the source DB instance. + PreSignedURL *string `json:"preSignedUrl,omitempty" tf:"pre_signed_url,omitempty"` + + // The retention period for the replicated automated backups, defaults to 7. + RetentionPeriod *float64 `json:"retentionPeriod,omitempty" tf:"retention_period,omitempty"` +} + type DBInstanceAutomatedBackupsReplicationObservation struct { // The Amazon Resource Name (ARN) of the replicated automated backups. @@ -61,7 +74,7 @@ type DBInstanceAutomatedBackupsReplicationParameters struct { // The Amazon Resource Name (ARN) of the source DB instance for the replicated automated backups, for example, arn:aws:rds:us-west-2:123456789012:db:mydatabase. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Instance - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true) // +kubebuilder:validation:Optional SourceDBInstanceArn *string `json:"sourceDbInstanceArn,omitempty" tf:"source_db_instance_arn,omitempty"` @@ -78,6 +91,17 @@ type DBInstanceAutomatedBackupsReplicationParameters struct { type DBInstanceAutomatedBackupsReplicationSpec struct { v1.ResourceSpec `json:",inline"` ForProvider DBInstanceAutomatedBackupsReplicationParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider DBInstanceAutomatedBackupsReplicationInitParameters `json:"initProvider,omitempty"` } // DBInstanceAutomatedBackupsReplicationStatus defines the observed state of DBInstanceAutomatedBackupsReplication. @@ -98,7 +122,7 @@ type DBInstanceAutomatedBackupsReplicationStatus struct { type DBInstanceAutomatedBackupsReplication struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec DBInstanceAutomatedBackupsReplicationSpec `json:"spec"` Status DBInstanceAutomatedBackupsReplicationStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_dbsnapshotcopy_types.go b/apis/rds/v1alpha1/zz_dbsnapshotcopy_types.go index 632d370..58bbee6 100755 --- a/apis/rds/v1alpha1/zz_dbsnapshotcopy_types.go +++ b/apis/rds/v1alpha1/zz_dbsnapshotcopy_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,33 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type DBSnapshotCopyInitParameters struct { + + // Whether to copy existing tags. Defaults to false. + CopyTags *bool `json:"copyTags,omitempty" tf:"copy_tags,omitempty"` + + // The Destination region to place snapshot copy. + DestinationRegion *string `json:"destinationRegion,omitempty" tf:"destination_region,omitempty"` + + // The name of an option group to associate with the copy of the snapshot. + OptionGroupName *string `json:"optionGroupName,omitempty" tf:"option_group_name,omitempty"` + + // he URL that contains a Signature Version 4 signed request. + PresignedURL *string `json:"presignedUrl,omitempty" tf:"presigned_url,omitempty"` + + // Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // The external custom Availability Zone. + TargetCustomAvailabilityZone *string `json:"targetCustomAvailabilityZone,omitempty" tf:"target_custom_availability_zone,omitempty"` + + // The Identifier for the snapshot. + TargetDBSnapshotIdentifier *string `json:"targetDbSnapshotIdentifier,omitempty" tf:"target_db_snapshot_identifier,omitempty"` +} + type DBSnapshotCopyObservation struct { // Specifies the allocated storage size in gigabytes (GB). @@ -124,7 +155,7 @@ type DBSnapshotCopyParameters struct { // Snapshot identifier of the source snapshot. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Snapshot - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("db_snapshot_arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("db_snapshot_arn",true) // +kubebuilder:validation:Optional SourceDBSnapshotIdentifier *string `json:"sourceDbSnapshotIdentifier,omitempty" tf:"source_db_snapshot_identifier,omitempty"` @@ -157,6 +188,17 @@ type DBSnapshotCopyParameters struct { type DBSnapshotCopySpec struct { v1.ResourceSpec `json:",inline"` ForProvider DBSnapshotCopyParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider DBSnapshotCopyInitParameters `json:"initProvider,omitempty"` } // DBSnapshotCopyStatus defines the observed state of DBSnapshotCopy. @@ -177,8 +219,8 @@ type DBSnapshotCopyStatus struct { type DBSnapshotCopy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.targetDbSnapshotIdentifier)",message="targetDbSnapshotIdentifier is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.targetDbSnapshotIdentifier) || (has(self.initProvider) && has(self.initProvider.targetDbSnapshotIdentifier))",message="spec.forProvider.targetDbSnapshotIdentifier is a required parameter" Spec DBSnapshotCopySpec `json:"spec"` Status DBSnapshotCopyStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_eventsubscription_types.go b/apis/rds/v1alpha1/zz_eventsubscription_types.go index 99a116d..29bea10 100755 --- a/apis/rds/v1alpha1/zz_eventsubscription_types.go +++ b/apis/rds/v1alpha1/zz_eventsubscription_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,30 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type EventSubscriptionInitParameters struct { + + // A boolean flag to enable/disable the subscription. Defaults to true. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` + + // A list of event categories for a SourceType that you want to subscribe to. See http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html or run aws rds describe-event-categories. + EventCategories []*string `json:"eventCategories,omitempty" tf:"event_categories,omitempty"` + + // The SNS topic to send events to. + SnsTopic *string `json:"snsTopic,omitempty" tf:"sns_topic,omitempty"` + + // A list of identifiers of the event sources for which events will be returned. If not specified, then all sources are included in the response. If specified, a source_type must also be specified. + SourceIds []*string `json:"sourceIds,omitempty" tf:"source_ids,omitempty"` + + // The type of source that will be generating the events. Valid options are db-instance, db-security-group, db-parameter-group, db-snapshot, db-cluster or db-cluster-snapshot. If not set, all sources will be subscribed to. + SourceType *string `json:"sourceType,omitempty" tf:"source_type,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type EventSubscriptionObservation struct { // The Amazon Resource Name of the RDS event notification subscription @@ -86,6 +114,17 @@ type EventSubscriptionParameters struct { type EventSubscriptionSpec struct { v1.ResourceSpec `json:",inline"` ForProvider EventSubscriptionParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider EventSubscriptionInitParameters `json:"initProvider,omitempty"` } // EventSubscriptionStatus defines the observed state of EventSubscription. @@ -106,8 +145,8 @@ type EventSubscriptionStatus struct { type EventSubscription struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.snsTopic)",message="snsTopic is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.snsTopic) || (has(self.initProvider) && has(self.initProvider.snsTopic))",message="spec.forProvider.snsTopic is a required parameter" Spec EventSubscriptionSpec `json:"spec"` Status EventSubscriptionStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_generated.deepcopy.go b/apis/rds/v1alpha1/zz_generated.deepcopy.go index 46203c6..4c80490 100644 --- a/apis/rds/v1alpha1/zz_generated.deepcopy.go +++ b/apis/rds/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. @@ -14,6 +13,51 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *AuthInitParameters) DeepCopyInto(out *AuthInitParameters) { + *out = *in + if in.AuthScheme != nil { + in, out := &in.AuthScheme, &out.AuthScheme + *out = new(string) + **out = **in + } + if in.ClientPasswordAuthType != nil { + in, out := &in.ClientPasswordAuthType, &out.ClientPasswordAuthType + *out = new(string) + **out = **in + } + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.IAMAuth != nil { + in, out := &in.IAMAuth, &out.IAMAuth + *out = new(string) + **out = **in + } + if in.SecretArn != nil { + in, out := &in.SecretArn, &out.SecretArn + *out = new(string) + **out = **in + } + if in.Username != nil { + in, out := &in.Username, &out.Username + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AuthInitParameters. +func (in *AuthInitParameters) DeepCopy() *AuthInitParameters { + if in == nil { + return nil + } + out := new(AuthInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *AuthObservation) DeepCopyInto(out *AuthObservation) { *out = *in @@ -104,6 +148,26 @@ func (in *AuthParameters) DeepCopy() *AuthParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *BlueGreenUpdateInitParameters) DeepCopyInto(out *BlueGreenUpdateInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BlueGreenUpdateInitParameters. +func (in *BlueGreenUpdateInitParameters) DeepCopy() *BlueGreenUpdateInitParameters { + if in == nil { + return nil + } + out := new(BlueGreenUpdateInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *BlueGreenUpdateObservation) DeepCopyInto(out *BlueGreenUpdateObservation) { *out = *in @@ -198,6 +262,31 @@ func (in *ClusterActivityStream) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterActivityStreamInitParameters) DeepCopyInto(out *ClusterActivityStreamInitParameters) { + *out = *in + if in.EngineNativeAuditFieldsIncluded != nil { + in, out := &in.EngineNativeAuditFieldsIncluded, &out.EngineNativeAuditFieldsIncluded + *out = new(bool) + **out = **in + } + if in.Mode != nil { + in, out := &in.Mode, &out.Mode + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterActivityStreamInitParameters. +func (in *ClusterActivityStreamInitParameters) DeepCopy() *ClusterActivityStreamInitParameters { + if in == nil { + return nil + } + out := new(ClusterActivityStreamInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterActivityStreamList) DeepCopyInto(out *ClusterActivityStreamList) { *out = *in @@ -340,6 +429,7 @@ func (in *ClusterActivityStreamSpec) DeepCopyInto(out *ClusterActivityStreamSpec *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterActivityStreamSpec. @@ -396,6 +486,80 @@ func (in *ClusterEndpoint) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterEndpointInitParameters) DeepCopyInto(out *ClusterEndpointInitParameters) { + *out = *in + if in.CustomEndpointType != nil { + in, out := &in.CustomEndpointType, &out.CustomEndpointType + *out = new(string) + **out = **in + } + if in.ExcludedMembers != nil { + in, out := &in.ExcludedMembers, &out.ExcludedMembers + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.StaticMembers != nil { + in, out := &in.StaticMembers, &out.StaticMembers + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterEndpointInitParameters. +func (in *ClusterEndpointInitParameters) DeepCopy() *ClusterEndpointInitParameters { + if in == nil { + return nil + } + out := new(ClusterEndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ClusterEndpointList) DeepCopyInto(out *ClusterEndpointList) { *out = *in @@ -486,7 +650,8 @@ func (in *ClusterEndpointObservation) DeepCopyInto(out *ClusterEndpointObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -501,7 +666,8 @@ func (in *ClusterEndpointObservation) DeepCopyInto(out *ClusterEndpointObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -578,7 +744,8 @@ func (in *ClusterEndpointParameters) DeepCopyInto(out *ClusterEndpointParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -593,7 +760,8 @@ func (in *ClusterEndpointParameters) DeepCopyInto(out *ClusterEndpointParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -617,6 +785,7 @@ func (in *ClusterEndpointSpec) DeepCopyInto(out *ClusterEndpointSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterEndpointSpec. @@ -647,180 +816,154 @@ func (in *ClusterEndpointStatus) DeepCopy() *ClusterEndpointStatus { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstance) DeepCopyInto(out *ClusterInstance) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstance. -func (in *ClusterInstance) DeepCopy() *ClusterInstance { - if in == nil { - return nil - } - out := new(ClusterInstance) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterInstance) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstanceList) DeepCopyInto(out *ClusterInstanceList) { +func (in *ClusterInitParameters) DeepCopyInto(out *ClusterInitParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]ClusterInstance, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceList. -func (in *ClusterInstanceList) DeepCopy() *ClusterInstanceList { - if in == nil { - return nil + if in.AllocatedStorage != nil { + in, out := &in.AllocatedStorage, &out.AllocatedStorage + *out = new(float64) + **out = **in } - out := new(ClusterInstanceList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterInstanceList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c + if in.AllowMajorVersionUpgrade != nil { + in, out := &in.AllowMajorVersionUpgrade, &out.AllowMajorVersionUpgrade + *out = new(bool) + **out = **in } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservation) { - *out = *in if in.ApplyImmediately != nil { in, out := &in.ApplyImmediately, &out.ApplyImmediately *out = new(bool) **out = **in } - if in.Arn != nil { - in, out := &in.Arn, &out.Arn - *out = new(string) - **out = **in - } - if in.AutoMinorVersionUpgrade != nil { - in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade - *out = new(bool) - **out = **in + if in.AvailabilityZones != nil { + in, out := &in.AvailabilityZones, &out.AvailabilityZones + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } } - if in.AvailabilityZone != nil { - in, out := &in.AvailabilityZone, &out.AvailabilityZone - *out = new(string) + if in.BacktrackWindow != nil { + in, out := &in.BacktrackWindow, &out.BacktrackWindow + *out = new(float64) **out = **in } - if in.CACertIdentifier != nil { - in, out := &in.CACertIdentifier, &out.CACertIdentifier - *out = new(string) + if in.BackupRetentionPeriod != nil { + in, out := &in.BackupRetentionPeriod, &out.BackupRetentionPeriod + *out = new(float64) **out = **in } - if in.ClusterIdentifier != nil { - in, out := &in.ClusterIdentifier, &out.ClusterIdentifier - *out = new(string) - **out = **in + if in.ClusterMembers != nil { + in, out := &in.ClusterMembers, &out.ClusterMembers + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } } if in.CopyTagsToSnapshot != nil { in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot *out = new(bool) **out = **in } - if in.DBParameterGroupName != nil { - in, out := &in.DBParameterGroupName, &out.DBParameterGroupName + if in.DBClusterInstanceClass != nil { + in, out := &in.DBClusterInstanceClass, &out.DBClusterInstanceClass *out = new(string) **out = **in } - if in.DBSubnetGroupName != nil { - in, out := &in.DBSubnetGroupName, &out.DBSubnetGroupName + if in.DBClusterParameterGroupName != nil { + in, out := &in.DBClusterParameterGroupName, &out.DBClusterParameterGroupName *out = new(string) **out = **in } - if in.DbiResourceID != nil { - in, out := &in.DbiResourceID, &out.DbiResourceID + if in.DBInstanceParameterGroupName != nil { + in, out := &in.DBInstanceParameterGroupName, &out.DBInstanceParameterGroupName *out = new(string) **out = **in } - if in.Endpoint != nil { - in, out := &in.Endpoint, &out.Endpoint + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName *out = new(string) **out = **in } - if in.Engine != nil { - in, out := &in.Engine, &out.Engine - *out = new(string) + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) **out = **in } - if in.EngineVersion != nil { - in, out := &in.EngineVersion, &out.EngineVersion - *out = new(string) + if in.EnableGlobalWriteForwarding != nil { + in, out := &in.EnableGlobalWriteForwarding, &out.EnableGlobalWriteForwarding + *out = new(bool) **out = **in } - if in.EngineVersionActual != nil { - in, out := &in.EngineVersionActual, &out.EngineVersionActual - *out = new(string) + if in.EnableHTTPEndpoint != nil { + in, out := &in.EnableHTTPEndpoint, &out.EnableHTTPEndpoint + *out = new(bool) **out = **in } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.EnabledCloudwatchLogsExports != nil { + in, out := &in.EnabledCloudwatchLogsExports, &out.EnabledCloudwatchLogsExports + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine *out = new(string) **out = **in } - if in.InstanceClass != nil { - in, out := &in.InstanceClass, &out.InstanceClass + if in.EngineMode != nil { + in, out := &in.EngineMode, &out.EngineMode *out = new(string) **out = **in } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion *out = new(string) **out = **in } - if in.MonitoringInterval != nil { - in, out := &in.MonitoringInterval, &out.MonitoringInterval - *out = new(float64) + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + *out = new(string) **out = **in } - if in.MonitoringRoleArn != nil { - in, out := &in.MonitoringRoleArn, &out.MonitoringRoleArn + if in.GlobalClusterIdentifier != nil { + in, out := &in.GlobalClusterIdentifier, &out.GlobalClusterIdentifier *out = new(string) **out = **in } - if in.NetworkType != nil { - in, out := &in.NetworkType, &out.NetworkType - *out = new(string) + if in.IAMDatabaseAuthenticationEnabled != nil { + in, out := &in.IAMDatabaseAuthenticationEnabled, &out.IAMDatabaseAuthenticationEnabled + *out = new(bool) **out = **in } - if in.PerformanceInsightsEnabled != nil { - in, out := &in.PerformanceInsightsEnabled, &out.PerformanceInsightsEnabled + if in.Iops != nil { + in, out := &in.Iops, &out.Iops + *out = new(float64) + **out = **in + } + if in.ManageMasterUserPassword != nil { + in, out := &in.ManageMasterUserPassword, &out.ManageMasterUserPassword *out = new(bool) **out = **in } - if in.PerformanceInsightsKMSKeyID != nil { - in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID + if in.MasterUsername != nil { + in, out := &in.MasterUsername, &out.MasterUsername *out = new(string) **out = **in } - if in.PerformanceInsightsRetentionPeriod != nil { - in, out := &in.PerformanceInsightsRetentionPeriod, &out.PerformanceInsightsRetentionPeriod - *out = new(float64) + if in.NetworkType != nil { + in, out := &in.NetworkType, &out.NetworkType + *out = new(string) **out = **in } if in.Port != nil { @@ -838,21 +981,64 @@ func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservati *out = new(string) **out = **in } - if in.PromotionTier != nil { - in, out := &in.PromotionTier, &out.PromotionTier - *out = new(float64) + if in.ReplicationSourceIdentifier != nil { + in, out := &in.ReplicationSourceIdentifier, &out.ReplicationSourceIdentifier + *out = new(string) **out = **in } - if in.PubliclyAccessible != nil { - in, out := &in.PubliclyAccessible, &out.PubliclyAccessible + if in.RestoreToPointInTime != nil { + in, out := &in.RestoreToPointInTime, &out.RestoreToPointInTime + *out = make([]ClusterRestoreToPointInTimeInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.S3Import != nil { + in, out := &in.S3Import, &out.S3Import + *out = make([]ClusterS3ImportInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ScalingConfiguration != nil { + in, out := &in.ScalingConfiguration, &out.ScalingConfiguration + *out = make([]ScalingConfigurationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Serverlessv2ScalingConfiguration != nil { + in, out := &in.Serverlessv2ScalingConfiguration, &out.Serverlessv2ScalingConfiguration + *out = make([]Serverlessv2ScalingConfigurationInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.SkipFinalSnapshot != nil { + in, out := &in.SkipFinalSnapshot, &out.SkipFinalSnapshot *out = new(bool) **out = **in } + if in.SnapshotIdentifier != nil { + in, out := &in.SnapshotIdentifier, &out.SnapshotIdentifier + *out = new(string) + **out = **in + } + if in.SourceRegion != nil { + in, out := &in.SourceRegion, &out.SourceRegion + *out = new(string) + **out = **in + } if in.StorageEncrypted != nil { in, out := &in.StorageEncrypted, &out.StorageEncrypted *out = new(bool) **out = **in } + if in.StorageType != nil { + in, out := &in.StorageType, &out.StorageType + *out = new(string) + **out = **in + } if in.Tags != nil { in, out := &in.Tags, &out.Tags *out = make(map[string]*string, len(*in)) @@ -861,7 +1047,8 @@ func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -876,32 +1063,55 @@ func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservati if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } - if in.Writer != nil { - in, out := &in.Writer, &out.Writer - *out = new(bool) - **out = **in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInitParameters. +func (in *ClusterInitParameters) DeepCopy() *ClusterInitParameters { + if in == nil { + return nil } + out := new(ClusterInitParameters) + in.DeepCopyInto(out) + return out } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceObservation. -func (in *ClusterInstanceObservation) DeepCopy() *ClusterInstanceObservation { +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterInstance) DeepCopyInto(out *ClusterInstance) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstance. +func (in *ClusterInstance) DeepCopy() *ClusterInstance { if in == nil { return nil } - out := new(ClusterInstanceObservation) + out := new(ClusterInstance) in.DeepCopyInto(out) return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterInstance) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters) { +func (in *ClusterInstanceInitParameters) DeepCopyInto(out *ClusterInstanceInitParameters) { *out = *in if in.ApplyImmediately != nil { in, out := &in.ApplyImmediately, &out.ApplyImmediately @@ -923,21 +1133,6 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters *out = new(string) **out = **in } - if in.ClusterIdentifier != nil { - in, out := &in.ClusterIdentifier, &out.ClusterIdentifier - *out = new(string) - **out = **in - } - if in.ClusterIdentifierRef != nil { - in, out := &in.ClusterIdentifierRef, &out.ClusterIdentifierRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.ClusterIdentifierSelector != nil { - in, out := &in.ClusterIdentifierSelector, &out.ClusterIdentifierSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.CopyTagsToSnapshot != nil { in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot *out = new(bool) @@ -948,21 +1143,6 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters *out = new(string) **out = **in } - if in.DBSubnetGroupName != nil { - in, out := &in.DBSubnetGroupName, &out.DBSubnetGroupName - *out = new(string) - **out = **in - } - if in.DBSubnetGroupNameRef != nil { - in, out := &in.DBSubnetGroupNameRef, &out.DBSubnetGroupNameRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.DBSubnetGroupNameSelector != nil { - in, out := &in.DBSubnetGroupNameSelector, &out.DBSubnetGroupNameSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) @@ -993,21 +1173,6 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters *out = new(bool) **out = **in } - if in.PerformanceInsightsKMSKeyID != nil { - in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID - *out = new(string) - **out = **in - } - if in.PerformanceInsightsKMSKeyIDRef != nil { - in, out := &in.PerformanceInsightsKMSKeyIDRef, &out.PerformanceInsightsKMSKeyIDRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.PerformanceInsightsKMSKeyIDSelector != nil { - in, out := &in.PerformanceInsightsKMSKeyIDSelector, &out.PerformanceInsightsKMSKeyIDSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.PerformanceInsightsRetentionPeriod != nil { in, out := &in.PerformanceInsightsRetentionPeriod, &out.PerformanceInsightsRetentionPeriod *out = new(float64) @@ -1033,11 +1198,6 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters *out = new(bool) **out = **in } - if in.Region != nil { - in, out := &in.Region, &out.Region - *out = new(string) - **out = **in - } if in.Tags != nil { in, out := &in.Tags, &out.Tags *out = make(map[string]*string, len(*in)) @@ -1046,7 +1206,8 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1061,7 +1222,8 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1070,140 +1232,51 @@ func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceParameters. -func (in *ClusterInstanceParameters) DeepCopy() *ClusterInstanceParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceInitParameters. +func (in *ClusterInstanceInitParameters) DeepCopy() *ClusterInstanceInitParameters { if in == nil { return nil } - out := new(ClusterInstanceParameters) + out := new(ClusterInstanceInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstanceSpec) DeepCopyInto(out *ClusterInstanceSpec) { +func (in *ClusterInstanceList) DeepCopyInto(out *ClusterInstanceList) { *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ClusterInstance, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceSpec. -func (in *ClusterInstanceSpec) DeepCopy() *ClusterInstanceSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceList. +func (in *ClusterInstanceList) DeepCopy() *ClusterInstanceList { if in == nil { return nil } - out := new(ClusterInstanceSpec) + out := new(ClusterInstanceList) in.DeepCopyInto(out) return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterInstanceList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterInstanceStatus) DeepCopyInto(out *ClusterInstanceStatus) { +func (in *ClusterInstanceObservation) DeepCopyInto(out *ClusterInstanceObservation) { *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceStatus. -func (in *ClusterInstanceStatus) DeepCopy() *ClusterInstanceStatus { - if in == nil { - return nil - } - out := new(ClusterInstanceStatus) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterList) DeepCopyInto(out *ClusterList) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Cluster, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterList. -func (in *ClusterList) DeepCopy() *ClusterList { - if in == nil { - return nil - } - out := new(ClusterList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterMasterUserSecretObservation) DeepCopyInto(out *ClusterMasterUserSecretObservation) { - *out = *in - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID - *out = new(string) - **out = **in - } - if in.SecretArn != nil { - in, out := &in.SecretArn, &out.SecretArn - *out = new(string) - **out = **in - } - if in.SecretStatus != nil { - in, out := &in.SecretStatus, &out.SecretStatus - *out = new(string) - **out = **in - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterMasterUserSecretObservation. -func (in *ClusterMasterUserSecretObservation) DeepCopy() *ClusterMasterUserSecretObservation { - if in == nil { - return nil - } - out := new(ClusterMasterUserSecretObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterMasterUserSecretParameters) DeepCopyInto(out *ClusterMasterUserSecretParameters) { - *out = *in -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterMasterUserSecretParameters. -func (in *ClusterMasterUserSecretParameters) DeepCopy() *ClusterMasterUserSecretParameters { - if in == nil { - return nil - } - out := new(ClusterMasterUserSecretParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { - *out = *in - if in.AllocatedStorage != nil { - in, out := &in.AllocatedStorage, &out.AllocatedStorage - *out = new(float64) - **out = **in - } - if in.AllowMajorVersionUpgrade != nil { - in, out := &in.AllowMajorVersionUpgrade, &out.AllowMajorVersionUpgrade - *out = new(bool) - **out = **in - } if in.ApplyImmediately != nil { in, out := &in.ApplyImmediately, &out.ApplyImmediately *out = new(bool) @@ -1214,40 +1287,23 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(string) **out = **in } - if in.AvailabilityZones != nil { - in, out := &in.AvailabilityZones, &out.AvailabilityZones - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } - if in.BacktrackWindow != nil { - in, out := &in.BacktrackWindow, &out.BacktrackWindow - *out = new(float64) + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(bool) **out = **in } - if in.BackupRetentionPeriod != nil { - in, out := &in.BackupRetentionPeriod, &out.BackupRetentionPeriod - *out = new(float64) + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) **out = **in } - if in.ClusterMembers != nil { - in, out := &in.ClusterMembers, &out.ClusterMembers - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } + if in.CACertIdentifier != nil { + in, out := &in.CACertIdentifier, &out.CACertIdentifier + *out = new(string) + **out = **in } - if in.ClusterResourceID != nil { - in, out := &in.ClusterResourceID, &out.ClusterResourceID + if in.ClusterIdentifier != nil { + in, out := &in.ClusterIdentifier, &out.ClusterIdentifier *out = new(string) **out = **in } @@ -1256,18 +1312,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(bool) **out = **in } - if in.DBClusterInstanceClass != nil { - in, out := &in.DBClusterInstanceClass, &out.DBClusterInstanceClass - *out = new(string) - **out = **in - } - if in.DBClusterParameterGroupName != nil { - in, out := &in.DBClusterParameterGroupName, &out.DBClusterParameterGroupName - *out = new(string) - **out = **in - } - if in.DBInstanceParameterGroupName != nil { - in, out := &in.DBInstanceParameterGroupName, &out.DBInstanceParameterGroupName + if in.DBParameterGroupName != nil { + in, out := &in.DBParameterGroupName, &out.DBParameterGroupName *out = new(string) **out = **in } @@ -1276,37 +1322,11 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(string) **out = **in } - if in.DatabaseName != nil { - in, out := &in.DatabaseName, &out.DatabaseName + if in.DbiResourceID != nil { + in, out := &in.DbiResourceID, &out.DbiResourceID *out = new(string) **out = **in } - if in.DeletionProtection != nil { - in, out := &in.DeletionProtection, &out.DeletionProtection - *out = new(bool) - **out = **in - } - if in.EnableGlobalWriteForwarding != nil { - in, out := &in.EnableGlobalWriteForwarding, &out.EnableGlobalWriteForwarding - *out = new(bool) - **out = **in - } - if in.EnableHTTPEndpoint != nil { - in, out := &in.EnableHTTPEndpoint, &out.EnableHTTPEndpoint - *out = new(bool) - **out = **in - } - if in.EnabledCloudwatchLogsExports != nil { - in, out := &in.EnabledCloudwatchLogsExports, &out.EnabledCloudwatchLogsExports - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } if in.Endpoint != nil { in, out := &in.Endpoint, &out.Endpoint *out = new(string) @@ -1317,11 +1337,6 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(string) **out = **in } - if in.EngineMode != nil { - in, out := &in.EngineMode, &out.EngineMode - *out = new(string) - **out = **in - } if in.EngineVersion != nil { in, out := &in.EngineVersion, &out.EngineVersion *out = new(string) @@ -1332,77 +1347,49 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(string) **out = **in } - if in.FinalSnapshotIdentifier != nil { - in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + if in.ID != nil { + in, out := &in.ID, &out.ID *out = new(string) **out = **in } - if in.GlobalClusterIdentifier != nil { - in, out := &in.GlobalClusterIdentifier, &out.GlobalClusterIdentifier + if in.InstanceClass != nil { + in, out := &in.InstanceClass, &out.InstanceClass *out = new(string) **out = **in } - if in.HostedZoneID != nil { - in, out := &in.HostedZoneID, &out.HostedZoneID + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID *out = new(string) **out = **in } - if in.IAMDatabaseAuthenticationEnabled != nil { - in, out := &in.IAMDatabaseAuthenticationEnabled, &out.IAMDatabaseAuthenticationEnabled - *out = new(bool) + if in.MonitoringInterval != nil { + in, out := &in.MonitoringInterval, &out.MonitoringInterval + *out = new(float64) **out = **in } - if in.IAMRoles != nil { - in, out := &in.IAMRoles, &out.IAMRoles - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.MonitoringRoleArn != nil { + in, out := &in.MonitoringRoleArn, &out.MonitoringRoleArn *out = new(string) **out = **in } - if in.Iops != nil { - in, out := &in.Iops, &out.Iops - *out = new(float64) - **out = **in - } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.NetworkType != nil { + in, out := &in.NetworkType, &out.NetworkType *out = new(string) **out = **in } - if in.ManageMasterUserPassword != nil { - in, out := &in.ManageMasterUserPassword, &out.ManageMasterUserPassword + if in.PerformanceInsightsEnabled != nil { + in, out := &in.PerformanceInsightsEnabled, &out.PerformanceInsightsEnabled *out = new(bool) **out = **in } - if in.MasterUserSecret != nil { - in, out := &in.MasterUserSecret, &out.MasterUserSecret - *out = make([]ClusterMasterUserSecretObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.MasterUserSecretKMSKeyID != nil { - in, out := &in.MasterUserSecretKMSKeyID, &out.MasterUserSecretKMSKeyID - *out = new(string) - **out = **in - } - if in.MasterUsername != nil { - in, out := &in.MasterUsername, &out.MasterUsername + if in.PerformanceInsightsKMSKeyID != nil { + in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID *out = new(string) **out = **in } - if in.NetworkType != nil { - in, out := &in.NetworkType, &out.NetworkType - *out = new(string) + if in.PerformanceInsightsRetentionPeriod != nil { + in, out := &in.PerformanceInsightsRetentionPeriod, &out.PerformanceInsightsRetentionPeriod + *out = new(float64) **out = **in } if in.Port != nil { @@ -1420,69 +1407,21 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = new(string) **out = **in } - if in.ReaderEndpoint != nil { - in, out := &in.ReaderEndpoint, &out.ReaderEndpoint - *out = new(string) - **out = **in - } - if in.ReplicationSourceIdentifier != nil { - in, out := &in.ReplicationSourceIdentifier, &out.ReplicationSourceIdentifier - *out = new(string) + if in.PromotionTier != nil { + in, out := &in.PromotionTier, &out.PromotionTier + *out = new(float64) **out = **in } - if in.RestoreToPointInTime != nil { - in, out := &in.RestoreToPointInTime, &out.RestoreToPointInTime - *out = make([]ClusterRestoreToPointInTimeObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.S3Import != nil { - in, out := &in.S3Import, &out.S3Import - *out = make([]ClusterS3ImportObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.ScalingConfiguration != nil { - in, out := &in.ScalingConfiguration, &out.ScalingConfiguration - *out = make([]ScalingConfigurationObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.Serverlessv2ScalingConfiguration != nil { - in, out := &in.Serverlessv2ScalingConfiguration, &out.Serverlessv2ScalingConfiguration - *out = make([]Serverlessv2ScalingConfigurationObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.SkipFinalSnapshot != nil { - in, out := &in.SkipFinalSnapshot, &out.SkipFinalSnapshot + if in.PubliclyAccessible != nil { + in, out := &in.PubliclyAccessible, &out.PubliclyAccessible *out = new(bool) **out = **in } - if in.SnapshotIdentifier != nil { - in, out := &in.SnapshotIdentifier, &out.SnapshotIdentifier - *out = new(string) - **out = **in - } - if in.SourceRegion != nil { - in, out := &in.SourceRegion, &out.SourceRegion - *out = new(string) - **out = **in - } if in.StorageEncrypted != nil { in, out := &in.StorageEncrypted, &out.StorageEncrypted *out = new(bool) **out = **in } - if in.StorageType != nil { - in, out := &in.StorageType, &out.StorageType - *out = new(string) - **out = **in - } if in.Tags != nil { in, out := &in.Tags, &out.Tags *out = make(map[string]*string, len(*in)) @@ -1491,7 +1430,8 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1506,246 +1446,163 @@ func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } - if in.VPCSecurityGroupIds != nil { - in, out := &in.VPCSecurityGroupIds, &out.VPCSecurityGroupIds - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterObservation. -func (in *ClusterObservation) DeepCopy() *ClusterObservation { - if in == nil { - return nil + if in.Writer != nil { + in, out := &in.Writer, &out.Writer + *out = new(bool) + **out = **in } - out := new(ClusterObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroup) DeepCopyInto(out *ClusterParameterGroup) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroup. -func (in *ClusterParameterGroup) DeepCopy() *ClusterParameterGroup { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceObservation. +func (in *ClusterInstanceObservation) DeepCopy() *ClusterInstanceObservation { if in == nil { return nil } - out := new(ClusterParameterGroup) + out := new(ClusterInstanceObservation) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterParameterGroup) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupList) DeepCopyInto(out *ClusterParameterGroupList) { +func (in *ClusterInstanceParameters) DeepCopyInto(out *ClusterInstanceParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]ClusterParameterGroup, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupList. -func (in *ClusterParameterGroupList) DeepCopy() *ClusterParameterGroupList { - if in == nil { - return nil + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in } - out := new(ClusterParameterGroupList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterParameterGroupList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(bool) + **out = **in } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupObservation) DeepCopyInto(out *ClusterParameterGroupObservation) { - *out = *in - if in.Arn != nil { - in, out := &in.Arn, &out.Arn + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone *out = new(string) **out = **in } - if in.Description != nil { - in, out := &in.Description, &out.Description + if in.CACertIdentifier != nil { + in, out := &in.CACertIdentifier, &out.CACertIdentifier *out = new(string) **out = **in } - if in.Family != nil { - in, out := &in.Family, &out.Family + if in.ClusterIdentifier != nil { + in, out := &in.ClusterIdentifier, &out.ClusterIdentifier *out = new(string) **out = **in } - if in.ID != nil { - in, out := &in.ID, &out.ID - *out = new(string) + if in.ClusterIdentifierRef != nil { + in, out := &in.ClusterIdentifierRef, &out.ClusterIdentifierRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIdentifierSelector != nil { + in, out := &in.ClusterIdentifierSelector, &out.ClusterIdentifierSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.CopyTagsToSnapshot != nil { + in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot + *out = new(bool) **out = **in } - if in.Parameter != nil { - in, out := &in.Parameter, &out.Parameter - *out = make([]ClusterParameterGroupParameterObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.DBParameterGroupName != nil { + in, out := &in.DBParameterGroupName, &out.DBParameterGroupName + *out = new(string) + **out = **in } - if in.Tags != nil { - in, out := &in.Tags, &out.Tags - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } + if in.DBSubnetGroupName != nil { + in, out := &in.DBSubnetGroupName, &out.DBSubnetGroupName + *out = new(string) + **out = **in } - if in.TagsAll != nil { - in, out := &in.TagsAll, &out.TagsAll - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } + if in.DBSubnetGroupNameRef != nil { + in, out := &in.DBSubnetGroupNameRef, &out.DBSubnetGroupNameRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupObservation. -func (in *ClusterParameterGroupObservation) DeepCopy() *ClusterParameterGroupObservation { - if in == nil { - return nil + if in.DBSubnetGroupNameSelector != nil { + in, out := &in.DBSubnetGroupNameSelector, &out.DBSubnetGroupNameSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) } - out := new(ClusterParameterGroupObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupParameterObservation) DeepCopyInto(out *ClusterParameterGroupParameterObservation) { - *out = *in - if in.ApplyMethod != nil { - in, out := &in.ApplyMethod, &out.ApplyMethod + if in.Engine != nil { + in, out := &in.Engine, &out.Engine *out = new(string) **out = **in } - if in.Name != nil { - in, out := &in.Name, &out.Name + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion *out = new(string) **out = **in } - if in.Value != nil { - in, out := &in.Value, &out.Value + if in.InstanceClass != nil { + in, out := &in.InstanceClass, &out.InstanceClass *out = new(string) **out = **in } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameterObservation. -func (in *ClusterParameterGroupParameterObservation) DeepCopy() *ClusterParameterGroupParameterObservation { - if in == nil { - return nil + if in.MonitoringInterval != nil { + in, out := &in.MonitoringInterval, &out.MonitoringInterval + *out = new(float64) + **out = **in } - out := new(ClusterParameterGroupParameterObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupParameterParameters) DeepCopyInto(out *ClusterParameterGroupParameterParameters) { - *out = *in - if in.ApplyMethod != nil { - in, out := &in.ApplyMethod, &out.ApplyMethod + if in.MonitoringRoleArn != nil { + in, out := &in.MonitoringRoleArn, &out.MonitoringRoleArn *out = new(string) **out = **in } - if in.Name != nil { - in, out := &in.Name, &out.Name - *out = new(string) + if in.PerformanceInsightsEnabled != nil { + in, out := &in.PerformanceInsightsEnabled, &out.PerformanceInsightsEnabled + *out = new(bool) **out = **in } - if in.Value != nil { - in, out := &in.Value, &out.Value + if in.PerformanceInsightsKMSKeyID != nil { + in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID *out = new(string) **out = **in } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameterParameters. -func (in *ClusterParameterGroupParameterParameters) DeepCopy() *ClusterParameterGroupParameterParameters { - if in == nil { - return nil + if in.PerformanceInsightsKMSKeyIDRef != nil { + in, out := &in.PerformanceInsightsKMSKeyIDRef, &out.PerformanceInsightsKMSKeyIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) } - out := new(ClusterParameterGroupParameterParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGroupParameters) { - *out = *in - if in.Description != nil { - in, out := &in.Description, &out.Description + if in.PerformanceInsightsKMSKeyIDSelector != nil { + in, out := &in.PerformanceInsightsKMSKeyIDSelector, &out.PerformanceInsightsKMSKeyIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.PerformanceInsightsRetentionPeriod != nil { + in, out := &in.PerformanceInsightsRetentionPeriod, &out.PerformanceInsightsRetentionPeriod + *out = new(float64) + **out = **in + } + if in.PreferredBackupWindow != nil { + in, out := &in.PreferredBackupWindow, &out.PreferredBackupWindow *out = new(string) **out = **in } - if in.Family != nil { - in, out := &in.Family, &out.Family + if in.PreferredMaintenanceWindow != nil { + in, out := &in.PreferredMaintenanceWindow, &out.PreferredMaintenanceWindow *out = new(string) **out = **in } - if in.Parameter != nil { - in, out := &in.Parameter, &out.Parameter - *out = make([]ClusterParameterGroupParameterParameters, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.PromotionTier != nil { + in, out := &in.PromotionTier, &out.PromotionTier + *out = new(float64) + **out = **in + } + if in.PubliclyAccessible != nil { + in, out := &in.PubliclyAccessible, &out.PubliclyAccessible + *out = new(bool) + **out = **in } if in.Region != nil { in, out := &in.Region, &out.Region @@ -1760,7 +1617,8 @@ func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGro if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1775,7 +1633,8 @@ func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGro if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -1784,52 +1643,145 @@ func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGro } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameters. -func (in *ClusterParameterGroupParameters) DeepCopy() *ClusterParameterGroupParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceParameters. +func (in *ClusterInstanceParameters) DeepCopy() *ClusterInstanceParameters { if in == nil { return nil } - out := new(ClusterParameterGroupParameters) + out := new(ClusterInstanceParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupSpec) DeepCopyInto(out *ClusterParameterGroupSpec) { +func (in *ClusterInstanceSpec) DeepCopyInto(out *ClusterInstanceSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupSpec. -func (in *ClusterParameterGroupSpec) DeepCopy() *ClusterParameterGroupSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceSpec. +func (in *ClusterInstanceSpec) DeepCopy() *ClusterInstanceSpec { if in == nil { return nil } - out := new(ClusterParameterGroupSpec) + out := new(ClusterInstanceSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameterGroupStatus) DeepCopyInto(out *ClusterParameterGroupStatus) { +func (in *ClusterInstanceStatus) DeepCopyInto(out *ClusterInstanceStatus) { *out = *in in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupStatus. -func (in *ClusterParameterGroupStatus) DeepCopy() *ClusterParameterGroupStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterInstanceStatus. +func (in *ClusterInstanceStatus) DeepCopy() *ClusterInstanceStatus { if in == nil { return nil } - out := new(ClusterParameterGroupStatus) + out := new(ClusterInstanceStatus) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { +func (in *ClusterList) DeepCopyInto(out *ClusterList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Cluster, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterList. +func (in *ClusterList) DeepCopy() *ClusterList { + if in == nil { + return nil + } + out := new(ClusterList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterMasterUserSecretInitParameters) DeepCopyInto(out *ClusterMasterUserSecretInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterMasterUserSecretInitParameters. +func (in *ClusterMasterUserSecretInitParameters) DeepCopy() *ClusterMasterUserSecretInitParameters { + if in == nil { + return nil + } + out := new(ClusterMasterUserSecretInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterMasterUserSecretObservation) DeepCopyInto(out *ClusterMasterUserSecretObservation) { + *out = *in + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } + if in.SecretArn != nil { + in, out := &in.SecretArn, &out.SecretArn + *out = new(string) + **out = **in + } + if in.SecretStatus != nil { + in, out := &in.SecretStatus, &out.SecretStatus + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterMasterUserSecretObservation. +func (in *ClusterMasterUserSecretObservation) DeepCopy() *ClusterMasterUserSecretObservation { + if in == nil { + return nil + } + out := new(ClusterMasterUserSecretObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterMasterUserSecretParameters) DeepCopyInto(out *ClusterMasterUserSecretParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterMasterUserSecretParameters. +func (in *ClusterMasterUserSecretParameters) DeepCopy() *ClusterMasterUserSecretParameters { + if in == nil { + return nil + } + out := new(ClusterMasterUserSecretParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterObservation) DeepCopyInto(out *ClusterObservation) { *out = *in if in.AllocatedStorage != nil { in, out := &in.AllocatedStorage, &out.AllocatedStorage @@ -1846,6 +1798,11 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(bool) **out = **in } + if in.Arn != nil { + in, out := &in.Arn, &out.Arn + *out = new(string) + **out = **in + } if in.AvailabilityZones != nil { in, out := &in.AvailabilityZones, &out.AvailabilityZones *out = make([]*string, len(*in)) @@ -1878,6 +1835,11 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { } } } + if in.ClusterResourceID != nil { + in, out := &in.ClusterResourceID, &out.ClusterResourceID + *out = new(string) + **out = **in + } if in.CopyTagsToSnapshot != nil { in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot *out = new(bool) @@ -1903,16 +1865,6 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(string) **out = **in } - if in.DBSubnetGroupNameRef != nil { - in, out := &in.DBSubnetGroupNameRef, &out.DBSubnetGroupNameRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.DBSubnetGroupNameSelector != nil { - in, out := &in.DBSubnetGroupNameSelector, &out.DBSubnetGroupNameSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.DatabaseName != nil { in, out := &in.DatabaseName, &out.DatabaseName *out = new(string) @@ -1944,6 +1896,11 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { } } } + if in.Endpoint != nil { + in, out := &in.Endpoint, &out.Endpoint + *out = new(string) + **out = **in + } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) @@ -1959,6 +1916,11 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(string) **out = **in } + if in.EngineVersionActual != nil { + in, out := &in.EngineVersionActual, &out.EngineVersionActual + *out = new(string) + **out = **in + } if in.FinalSnapshotIdentifier != nil { in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier *out = new(string) @@ -1969,11 +1931,32 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(string) **out = **in } + if in.HostedZoneID != nil { + in, out := &in.HostedZoneID, &out.HostedZoneID + *out = new(string) + **out = **in + } if in.IAMDatabaseAuthenticationEnabled != nil { in, out := &in.IAMDatabaseAuthenticationEnabled, &out.IAMDatabaseAuthenticationEnabled *out = new(bool) **out = **in } + if in.IAMRoles != nil { + in, out := &in.IAMRoles, &out.IAMRoles + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ID != nil { + in, out := &in.ID, &out.ID + *out = new(string) + **out = **in + } if in.Iops != nil { in, out := &in.Iops, &out.Iops *out = new(float64) @@ -1984,41 +1967,23 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(string) **out = **in } - if in.KMSKeyIDRef != nil { - in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.KMSKeyIDSelector != nil { - in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.ManageMasterUserPassword != nil { in, out := &in.ManageMasterUserPassword, &out.ManageMasterUserPassword *out = new(bool) **out = **in } - if in.MasterPasswordSecretRef != nil { - in, out := &in.MasterPasswordSecretRef, &out.MasterPasswordSecretRef - *out = new(v1.SecretKeySelector) - **out = **in + if in.MasterUserSecret != nil { + in, out := &in.MasterUserSecret, &out.MasterUserSecret + *out = make([]ClusterMasterUserSecretObservation, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } } if in.MasterUserSecretKMSKeyID != nil { in, out := &in.MasterUserSecretKMSKeyID, &out.MasterUserSecretKMSKeyID *out = new(string) **out = **in } - if in.MasterUserSecretKMSKeyIDRef != nil { - in, out := &in.MasterUserSecretKMSKeyIDRef, &out.MasterUserSecretKMSKeyIDRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.MasterUserSecretKMSKeyIDSelector != nil { - in, out := &in.MasterUserSecretKMSKeyIDSelector, &out.MasterUserSecretKMSKeyIDSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.MasterUsername != nil { in, out := &in.MasterUsername, &out.MasterUsername *out = new(string) @@ -2044,8 +2009,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = new(string) **out = **in } - if in.Region != nil { - in, out := &in.Region, &out.Region + if in.ReaderEndpoint != nil { + in, out := &in.ReaderEndpoint, &out.ReaderEndpoint *out = new(string) **out = **in } @@ -2056,28 +2021,28 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { } if in.RestoreToPointInTime != nil { in, out := &in.RestoreToPointInTime, &out.RestoreToPointInTime - *out = make([]ClusterRestoreToPointInTimeParameters, len(*in)) + *out = make([]ClusterRestoreToPointInTimeObservation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } if in.S3Import != nil { in, out := &in.S3Import, &out.S3Import - *out = make([]ClusterS3ImportParameters, len(*in)) + *out = make([]ClusterS3ImportObservation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } if in.ScalingConfiguration != nil { in, out := &in.ScalingConfiguration, &out.ScalingConfiguration - *out = make([]ScalingConfigurationParameters, len(*in)) + *out = make([]ScalingConfigurationObservation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } if in.Serverlessv2ScalingConfiguration != nil { in, out := &in.Serverlessv2ScalingConfiguration, &out.Serverlessv2ScalingConfiguration - *out = make([]Serverlessv2ScalingConfigurationParameters, len(*in)) + *out = make([]Serverlessv2ScalingConfigurationObservation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -2115,7 +2080,8 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2130,25 +2096,14 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } - if in.VPCSecurityGroupIDRefs != nil { - in, out := &in.VPCSecurityGroupIDRefs, &out.VPCSecurityGroupIDRefs - *out = make([]v1.Reference, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.VPCSecurityGroupIDSelector != nil { - in, out := &in.VPCSecurityGroupIDSelector, &out.VPCSecurityGroupIDSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } if in.VPCSecurityGroupIds != nil { in, out := &in.VPCSecurityGroupIds, &out.VPCSecurityGroupIds *out = make([]*string, len(*in)) @@ -2162,149 +2117,133 @@ func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameters. -func (in *ClusterParameters) DeepCopy() *ClusterParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterObservation. +func (in *ClusterObservation) DeepCopy() *ClusterObservation { if in == nil { return nil } - out := new(ClusterParameters) + out := new(ClusterObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRestoreToPointInTimeObservation) DeepCopyInto(out *ClusterRestoreToPointInTimeObservation) { +func (in *ClusterParameterGroup) DeepCopyInto(out *ClusterParameterGroup) { *out = *in - if in.RestoreToTime != nil { - in, out := &in.RestoreToTime, &out.RestoreToTime - *out = new(string) - **out = **in - } - if in.RestoreType != nil { - in, out := &in.RestoreType, &out.RestoreType - *out = new(string) - **out = **in - } - if in.SourceClusterIdentifier != nil { - in, out := &in.SourceClusterIdentifier, &out.SourceClusterIdentifier - *out = new(string) - **out = **in - } - if in.UseLatestRestorableTime != nil { - in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime - *out = new(bool) - **out = **in - } + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRestoreToPointInTimeObservation. -func (in *ClusterRestoreToPointInTimeObservation) DeepCopy() *ClusterRestoreToPointInTimeObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroup. +func (in *ClusterParameterGroup) DeepCopy() *ClusterParameterGroup { if in == nil { return nil } - out := new(ClusterRestoreToPointInTimeObservation) + out := new(ClusterParameterGroup) in.DeepCopyInto(out) return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterParameterGroup) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRestoreToPointInTimeParameters) DeepCopyInto(out *ClusterRestoreToPointInTimeParameters) { +func (in *ClusterParameterGroupInitParameters) DeepCopyInto(out *ClusterParameterGroupInitParameters) { *out = *in - if in.RestoreToTime != nil { - in, out := &in.RestoreToTime, &out.RestoreToTime - *out = new(string) - **out = **in - } - if in.RestoreType != nil { - in, out := &in.RestoreType, &out.RestoreType + if in.Description != nil { + in, out := &in.Description, &out.Description *out = new(string) **out = **in } - if in.SourceClusterIdentifier != nil { - in, out := &in.SourceClusterIdentifier, &out.SourceClusterIdentifier + if in.Family != nil { + in, out := &in.Family, &out.Family *out = new(string) **out = **in } - if in.SourceClusterIdentifierRef != nil { - in, out := &in.SourceClusterIdentifierRef, &out.SourceClusterIdentifierRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.SourceClusterIdentifierSelector != nil { - in, out := &in.SourceClusterIdentifierSelector, &out.SourceClusterIdentifierSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ClusterParameterGroupParameterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } } - if in.UseLatestRestorableTime != nil { - in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime - *out = new(bool) - **out = **in + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRestoreToPointInTimeParameters. -func (in *ClusterRestoreToPointInTimeParameters) DeepCopy() *ClusterRestoreToPointInTimeParameters { - if in == nil { - return nil + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } - out := new(ClusterRestoreToPointInTimeParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociation) DeepCopyInto(out *ClusterRoleAssociation) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociation. -func (in *ClusterRoleAssociation) DeepCopy() *ClusterRoleAssociation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupInitParameters. +func (in *ClusterParameterGroupInitParameters) DeepCopy() *ClusterParameterGroupInitParameters { if in == nil { return nil } - out := new(ClusterRoleAssociation) + out := new(ClusterParameterGroupInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterRoleAssociation) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociationList) DeepCopyInto(out *ClusterRoleAssociationList) { +func (in *ClusterParameterGroupList) DeepCopyInto(out *ClusterParameterGroupList) { *out = *in out.TypeMeta = in.TypeMeta in.ListMeta.DeepCopyInto(&out.ListMeta) if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]ClusterRoleAssociation, len(*in)) + *out = make([]ClusterParameterGroup, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationList. -func (in *ClusterRoleAssociationList) DeepCopy() *ClusterRoleAssociationList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupList. +func (in *ClusterParameterGroupList) DeepCopy() *ClusterParameterGroupList { if in == nil { return nil } - out := new(ClusterRoleAssociationList) + out := new(ClusterParameterGroupList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterRoleAssociationList) DeepCopyObject() runtime.Object { +func (in *ClusterParameterGroupList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -2312,266 +2251,291 @@ func (in *ClusterRoleAssociationList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociationObservation) DeepCopyInto(out *ClusterRoleAssociationObservation) { +func (in *ClusterParameterGroupObservation) DeepCopyInto(out *ClusterParameterGroupObservation) { *out = *in - if in.DBClusterIdentifier != nil { - in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier + if in.Arn != nil { + in, out := &in.Arn, &out.Arn *out = new(string) **out = **in } - if in.FeatureName != nil { - in, out := &in.FeatureName, &out.FeatureName + if in.Description != nil { + in, out := &in.Description, &out.Description *out = new(string) **out = **in } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.Family != nil { + in, out := &in.Family, &out.Family *out = new(string) **out = **in } - if in.RoleArn != nil { - in, out := &in.RoleArn, &out.RoleArn + if in.ID != nil { + in, out := &in.ID, &out.ID *out = new(string) **out = **in } + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ClusterParameterGroupParameterObservation, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationObservation. -func (in *ClusterRoleAssociationObservation) DeepCopy() *ClusterRoleAssociationObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupObservation. +func (in *ClusterParameterGroupObservation) DeepCopy() *ClusterParameterGroupObservation { if in == nil { return nil } - out := new(ClusterRoleAssociationObservation) + out := new(ClusterParameterGroupObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociationParameters) DeepCopyInto(out *ClusterRoleAssociationParameters) { +func (in *ClusterParameterGroupParameterInitParameters) DeepCopyInto(out *ClusterParameterGroupParameterInitParameters) { *out = *in - if in.DBClusterIdentifier != nil { - in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier + if in.ApplyMethod != nil { + in, out := &in.ApplyMethod, &out.ApplyMethod *out = new(string) **out = **in } - if in.DBClusterIdentifierRef != nil { - in, out := &in.DBClusterIdentifierRef, &out.DBClusterIdentifierRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.DBClusterIdentifierSelector != nil { - in, out := &in.DBClusterIdentifierSelector, &out.DBClusterIdentifierSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } - if in.FeatureName != nil { - in, out := &in.FeatureName, &out.FeatureName - *out = new(string) - **out = **in - } - if in.Region != nil { - in, out := &in.Region, &out.Region + if in.Name != nil { + in, out := &in.Name, &out.Name *out = new(string) **out = **in } - if in.RoleArn != nil { - in, out := &in.RoleArn, &out.RoleArn + if in.Value != nil { + in, out := &in.Value, &out.Value *out = new(string) **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationParameters. -func (in *ClusterRoleAssociationParameters) DeepCopy() *ClusterRoleAssociationParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameterInitParameters. +func (in *ClusterParameterGroupParameterInitParameters) DeepCopy() *ClusterParameterGroupParameterInitParameters { if in == nil { return nil } - out := new(ClusterRoleAssociationParameters) + out := new(ClusterParameterGroupParameterInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociationSpec) DeepCopyInto(out *ClusterRoleAssociationSpec) { +func (in *ClusterParameterGroupParameterObservation) DeepCopyInto(out *ClusterParameterGroupParameterObservation) { *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationSpec. -func (in *ClusterRoleAssociationSpec) DeepCopy() *ClusterRoleAssociationSpec { - if in == nil { - return nil + if in.ApplyMethod != nil { + in, out := &in.ApplyMethod, &out.ApplyMethod + *out = new(string) + **out = **in + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in } - out := new(ClusterRoleAssociationSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterRoleAssociationStatus) DeepCopyInto(out *ClusterRoleAssociationStatus) { - *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationStatus. -func (in *ClusterRoleAssociationStatus) DeepCopy() *ClusterRoleAssociationStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameterObservation. +func (in *ClusterParameterGroupParameterObservation) DeepCopy() *ClusterParameterGroupParameterObservation { if in == nil { return nil } - out := new(ClusterRoleAssociationStatus) + out := new(ClusterParameterGroupParameterObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterS3ImportObservation) DeepCopyInto(out *ClusterS3ImportObservation) { +func (in *ClusterParameterGroupParameterParameters) DeepCopyInto(out *ClusterParameterGroupParameterParameters) { *out = *in - if in.BucketName != nil { - in, out := &in.BucketName, &out.BucketName - *out = new(string) - **out = **in - } - if in.BucketPrefix != nil { - in, out := &in.BucketPrefix, &out.BucketPrefix - *out = new(string) - **out = **in - } - if in.IngestionRole != nil { - in, out := &in.IngestionRole, &out.IngestionRole + if in.ApplyMethod != nil { + in, out := &in.ApplyMethod, &out.ApplyMethod *out = new(string) **out = **in } - if in.SourceEngine != nil { - in, out := &in.SourceEngine, &out.SourceEngine + if in.Name != nil { + in, out := &in.Name, &out.Name *out = new(string) **out = **in } - if in.SourceEngineVersion != nil { - in, out := &in.SourceEngineVersion, &out.SourceEngineVersion + if in.Value != nil { + in, out := &in.Value, &out.Value *out = new(string) **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterS3ImportObservation. -func (in *ClusterS3ImportObservation) DeepCopy() *ClusterS3ImportObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameterParameters. +func (in *ClusterParameterGroupParameterParameters) DeepCopy() *ClusterParameterGroupParameterParameters { if in == nil { return nil } - out := new(ClusterS3ImportObservation) + out := new(ClusterParameterGroupParameterParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterS3ImportParameters) DeepCopyInto(out *ClusterS3ImportParameters) { +func (in *ClusterParameterGroupParameters) DeepCopyInto(out *ClusterParameterGroupParameters) { *out = *in - if in.BucketName != nil { - in, out := &in.BucketName, &out.BucketName + if in.Description != nil { + in, out := &in.Description, &out.Description *out = new(string) **out = **in } - if in.BucketPrefix != nil { - in, out := &in.BucketPrefix, &out.BucketPrefix + if in.Family != nil { + in, out := &in.Family, &out.Family *out = new(string) **out = **in } - if in.IngestionRole != nil { - in, out := &in.IngestionRole, &out.IngestionRole - *out = new(string) - **out = **in + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ClusterParameterGroupParameterParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } } - if in.SourceEngine != nil { - in, out := &in.SourceEngine, &out.SourceEngine + if in.Region != nil { + in, out := &in.Region, &out.Region *out = new(string) **out = **in } - if in.SourceEngineVersion != nil { - in, out := &in.SourceEngineVersion, &out.SourceEngineVersion - *out = new(string) - **out = **in + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterS3ImportParameters. -func (in *ClusterS3ImportParameters) DeepCopy() *ClusterS3ImportParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupParameters. +func (in *ClusterParameterGroupParameters) DeepCopy() *ClusterParameterGroupParameters { if in == nil { return nil } - out := new(ClusterS3ImportParameters) + out := new(ClusterParameterGroupParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshot) DeepCopyInto(out *ClusterSnapshot) { +func (in *ClusterParameterGroupSpec) DeepCopyInto(out *ClusterParameterGroupSpec) { *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshot. -func (in *ClusterSnapshot) DeepCopy() *ClusterSnapshot { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupSpec. +func (in *ClusterParameterGroupSpec) DeepCopy() *ClusterParameterGroupSpec { if in == nil { return nil } - out := new(ClusterSnapshot) + out := new(ClusterParameterGroupSpec) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterSnapshot) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshotList) DeepCopyInto(out *ClusterSnapshotList) { +func (in *ClusterParameterGroupStatus) DeepCopyInto(out *ClusterParameterGroupStatus) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]ClusterSnapshot, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotList. -func (in *ClusterSnapshotList) DeepCopy() *ClusterSnapshotList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameterGroupStatus. +func (in *ClusterParameterGroupStatus) DeepCopy() *ClusterParameterGroupStatus { if in == nil { return nil } - out := new(ClusterSnapshotList) + out := new(ClusterParameterGroupStatus) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterSnapshotList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshotObservation) DeepCopyInto(out *ClusterSnapshotObservation) { +func (in *ClusterParameters) DeepCopyInto(out *ClusterParameters) { *out = *in if in.AllocatedStorage != nil { in, out := &in.AllocatedStorage, &out.AllocatedStorage *out = new(float64) **out = **in } + if in.AllowMajorVersionUpgrade != nil { + in, out := &in.AllowMajorVersionUpgrade, &out.AllowMajorVersionUpgrade + *out = new(bool) + **out = **in + } + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } if in.AvailabilityZones != nil { in, out := &in.AvailabilityZones, &out.AvailabilityZones *out = make([]*string, len(*in)) @@ -2583,138 +2547,190 @@ func (in *ClusterSnapshotObservation) DeepCopyInto(out *ClusterSnapshotObservati } } } - if in.DBClusterIdentifier != nil { - in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier - *out = new(string) + if in.BacktrackWindow != nil { + in, out := &in.BacktrackWindow, &out.BacktrackWindow + *out = new(float64) **out = **in } - if in.DBClusterSnapshotArn != nil { - in, out := &in.DBClusterSnapshotArn, &out.DBClusterSnapshotArn - *out = new(string) + if in.BackupRetentionPeriod != nil { + in, out := &in.BackupRetentionPeriod, &out.BackupRetentionPeriod + *out = new(float64) **out = **in } - if in.DBClusterSnapshotIdentifier != nil { - in, out := &in.DBClusterSnapshotIdentifier, &out.DBClusterSnapshotIdentifier - *out = new(string) - **out = **in + if in.ClusterMembers != nil { + in, out := &in.ClusterMembers, &out.ClusterMembers + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } } - if in.Engine != nil { - in, out := &in.Engine, &out.Engine - *out = new(string) + if in.CopyTagsToSnapshot != nil { + in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot + *out = new(bool) **out = **in } - if in.EngineVersion != nil { - in, out := &in.EngineVersion, &out.EngineVersion + if in.DBClusterInstanceClass != nil { + in, out := &in.DBClusterInstanceClass, &out.DBClusterInstanceClass *out = new(string) **out = **in } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.DBClusterParameterGroupName != nil { + in, out := &in.DBClusterParameterGroupName, &out.DBClusterParameterGroupName *out = new(string) **out = **in } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.DBInstanceParameterGroupName != nil { + in, out := &in.DBInstanceParameterGroupName, &out.DBInstanceParameterGroupName *out = new(string) **out = **in } - if in.LicenseModel != nil { - in, out := &in.LicenseModel, &out.LicenseModel + if in.DBSubnetGroupName != nil { + in, out := &in.DBSubnetGroupName, &out.DBSubnetGroupName *out = new(string) **out = **in } - if in.Port != nil { - in, out := &in.Port, &out.Port - *out = new(float64) - **out = **in + if in.DBSubnetGroupNameRef != nil { + in, out := &in.DBSubnetGroupNameRef, &out.DBSubnetGroupNameRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) } - if in.SnapshotType != nil { - in, out := &in.SnapshotType, &out.SnapshotType + if in.DBSubnetGroupNameSelector != nil { + in, out := &in.DBSubnetGroupNameSelector, &out.DBSubnetGroupNameSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName *out = new(string) **out = **in } - if in.SourceDBClusterSnapshotArn != nil { - in, out := &in.SourceDBClusterSnapshotArn, &out.SourceDBClusterSnapshotArn - *out = new(string) + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) **out = **in } - if in.Status != nil { - in, out := &in.Status, &out.Status - *out = new(string) + if in.EnableGlobalWriteForwarding != nil { + in, out := &in.EnableGlobalWriteForwarding, &out.EnableGlobalWriteForwarding + *out = new(bool) **out = **in } - if in.StorageEncrypted != nil { - in, out := &in.StorageEncrypted, &out.StorageEncrypted + if in.EnableHTTPEndpoint != nil { + in, out := &in.EnableHTTPEndpoint, &out.EnableHTTPEndpoint *out = new(bool) **out = **in } - if in.Tags != nil { - in, out := &in.Tags, &out.Tags - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal + if in.EnabledCloudwatchLogsExports != nil { + in, out := &in.EnabledCloudwatchLogsExports, &out.EnabledCloudwatchLogsExports + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] *out = new(string) **out = **in } - (*out)[key] = outVal } } - if in.TagsAll != nil { - in, out := &in.TagsAll, &out.TagsAll - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in } - if in.VPCID != nil { - in, out := &in.VPCID, &out.VPCID + if in.EngineMode != nil { + in, out := &in.EngineMode, &out.EngineMode *out = new(string) **out = **in } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotObservation. -func (in *ClusterSnapshotObservation) DeepCopy() *ClusterSnapshotObservation { - if in == nil { - return nil + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in } - out := new(ClusterSnapshotObservation) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshotParameters) DeepCopyInto(out *ClusterSnapshotParameters) { - *out = *in - if in.DBClusterIdentifier != nil { - in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier *out = new(string) **out = **in } - if in.DBClusterIdentifierRef != nil { - in, out := &in.DBClusterIdentifierRef, &out.DBClusterIdentifierRef + if in.GlobalClusterIdentifier != nil { + in, out := &in.GlobalClusterIdentifier, &out.GlobalClusterIdentifier + *out = new(string) + **out = **in + } + if in.IAMDatabaseAuthenticationEnabled != nil { + in, out := &in.IAMDatabaseAuthenticationEnabled, &out.IAMDatabaseAuthenticationEnabled + *out = new(bool) + **out = **in + } + if in.Iops != nil { + in, out := &in.Iops, &out.Iops + *out = new(float64) + **out = **in + } + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } + if in.KMSKeyIDRef != nil { + in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef *out = new(v1.Reference) (*in).DeepCopyInto(*out) } - if in.DBClusterIdentifierSelector != nil { - in, out := &in.DBClusterIdentifierSelector, &out.DBClusterIdentifierSelector + if in.KMSKeyIDSelector != nil { + in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector *out = new(v1.Selector) (*in).DeepCopyInto(*out) } - if in.DBClusterSnapshotIdentifier != nil { - in, out := &in.DBClusterSnapshotIdentifier, &out.DBClusterSnapshotIdentifier + if in.ManageMasterUserPassword != nil { + in, out := &in.ManageMasterUserPassword, &out.ManageMasterUserPassword + *out = new(bool) + **out = **in + } + if in.MasterPasswordSecretRef != nil { + in, out := &in.MasterPasswordSecretRef, &out.MasterPasswordSecretRef + *out = new(v1.SecretKeySelector) + **out = **in + } + if in.MasterUserSecretKMSKeyID != nil { + in, out := &in.MasterUserSecretKMSKeyID, &out.MasterUserSecretKMSKeyID + *out = new(string) + **out = **in + } + if in.MasterUserSecretKMSKeyIDRef != nil { + in, out := &in.MasterUserSecretKMSKeyIDRef, &out.MasterUserSecretKMSKeyIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.MasterUserSecretKMSKeyIDSelector != nil { + in, out := &in.MasterUserSecretKMSKeyIDSelector, &out.MasterUserSecretKMSKeyIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.MasterUsername != nil { + in, out := &in.MasterUsername, &out.MasterUsername + *out = new(string) + **out = **in + } + if in.NetworkType != nil { + in, out := &in.NetworkType, &out.NetworkType + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PreferredBackupWindow != nil { + in, out := &in.PreferredBackupWindow, &out.PreferredBackupWindow + *out = new(string) + **out = **in + } + if in.PreferredMaintenanceWindow != nil { + in, out := &in.PreferredMaintenanceWindow, &out.PreferredMaintenanceWindow *out = new(string) **out = **in } @@ -2723,6 +2739,64 @@ func (in *ClusterSnapshotParameters) DeepCopyInto(out *ClusterSnapshotParameters *out = new(string) **out = **in } + if in.ReplicationSourceIdentifier != nil { + in, out := &in.ReplicationSourceIdentifier, &out.ReplicationSourceIdentifier + *out = new(string) + **out = **in + } + if in.RestoreToPointInTime != nil { + in, out := &in.RestoreToPointInTime, &out.RestoreToPointInTime + *out = make([]ClusterRestoreToPointInTimeParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.S3Import != nil { + in, out := &in.S3Import, &out.S3Import + *out = make([]ClusterS3ImportParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.ScalingConfiguration != nil { + in, out := &in.ScalingConfiguration, &out.ScalingConfiguration + *out = make([]ScalingConfigurationParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Serverlessv2ScalingConfiguration != nil { + in, out := &in.Serverlessv2ScalingConfiguration, &out.Serverlessv2ScalingConfiguration + *out = make([]Serverlessv2ScalingConfigurationParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.SkipFinalSnapshot != nil { + in, out := &in.SkipFinalSnapshot, &out.SkipFinalSnapshot + *out = new(bool) + **out = **in + } + if in.SnapshotIdentifier != nil { + in, out := &in.SnapshotIdentifier, &out.SnapshotIdentifier + *out = new(string) + **out = **in + } + if in.SourceRegion != nil { + in, out := &in.SourceRegion, &out.SourceRegion + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } + if in.StorageType != nil { + in, out := &in.StorageType, &out.StorageType + *out = new(string) + **out = **in + } if in.Tags != nil { in, out := &in.Tags, &out.Tags *out = make(map[string]*string, len(*in)) @@ -2731,7 +2805,8 @@ func (in *ClusterSnapshotParameters) DeepCopyInto(out *ClusterSnapshotParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -2746,187 +2821,161 @@ func (in *ClusterSnapshotParameters) DeepCopyInto(out *ClusterSnapshotParameters if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } + if in.VPCSecurityGroupIDRefs != nil { + in, out := &in.VPCSecurityGroupIDRefs, &out.VPCSecurityGroupIDRefs + *out = make([]v1.Reference, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.VPCSecurityGroupIDSelector != nil { + in, out := &in.VPCSecurityGroupIDSelector, &out.VPCSecurityGroupIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.VPCSecurityGroupIds != nil { + in, out := &in.VPCSecurityGroupIds, &out.VPCSecurityGroupIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotParameters. -func (in *ClusterSnapshotParameters) DeepCopy() *ClusterSnapshotParameters { - if in == nil { - return nil - } - out := new(ClusterSnapshotParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshotSpec) DeepCopyInto(out *ClusterSnapshotSpec) { - *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotSpec. -func (in *ClusterSnapshotSpec) DeepCopy() *ClusterSnapshotSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterParameters. +func (in *ClusterParameters) DeepCopy() *ClusterParameters { if in == nil { return nil } - out := new(ClusterSnapshotSpec) + out := new(ClusterParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSnapshotStatus) DeepCopyInto(out *ClusterSnapshotStatus) { +func (in *ClusterRestoreToPointInTimeInitParameters) DeepCopyInto(out *ClusterRestoreToPointInTimeInitParameters) { *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotStatus. -func (in *ClusterSnapshotStatus) DeepCopy() *ClusterSnapshotStatus { - if in == nil { - return nil + if in.RestoreToTime != nil { + in, out := &in.RestoreToTime, &out.RestoreToTime + *out = new(string) + **out = **in } - out := new(ClusterSnapshotStatus) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { - *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. -func (in *ClusterSpec) DeepCopy() *ClusterSpec { - if in == nil { - return nil + if in.RestoreType != nil { + in, out := &in.RestoreType, &out.RestoreType + *out = new(string) + **out = **in + } + if in.UseLatestRestorableTime != nil { + in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime + *out = new(bool) + **out = **in } - out := new(ClusterSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterStatus) DeepCopyInto(out *ClusterStatus) { - *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterStatus. -func (in *ClusterStatus) DeepCopy() *ClusterStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRestoreToPointInTimeInitParameters. +func (in *ClusterRestoreToPointInTimeInitParameters) DeepCopy() *ClusterRestoreToPointInTimeInitParameters { if in == nil { return nil } - out := new(ClusterStatus) + out := new(ClusterRestoreToPointInTimeInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ConnectionPoolConfigObservation) DeepCopyInto(out *ConnectionPoolConfigObservation) { +func (in *ClusterRestoreToPointInTimeObservation) DeepCopyInto(out *ClusterRestoreToPointInTimeObservation) { *out = *in - if in.ConnectionBorrowTimeout != nil { - in, out := &in.ConnectionBorrowTimeout, &out.ConnectionBorrowTimeout - *out = new(float64) + if in.RestoreToTime != nil { + in, out := &in.RestoreToTime, &out.RestoreToTime + *out = new(string) **out = **in } - if in.InitQuery != nil { - in, out := &in.InitQuery, &out.InitQuery + if in.RestoreType != nil { + in, out := &in.RestoreType, &out.RestoreType *out = new(string) **out = **in } - if in.MaxConnectionsPercent != nil { - in, out := &in.MaxConnectionsPercent, &out.MaxConnectionsPercent - *out = new(float64) + if in.SourceClusterIdentifier != nil { + in, out := &in.SourceClusterIdentifier, &out.SourceClusterIdentifier + *out = new(string) **out = **in } - if in.MaxIdleConnectionsPercent != nil { - in, out := &in.MaxIdleConnectionsPercent, &out.MaxIdleConnectionsPercent - *out = new(float64) + if in.UseLatestRestorableTime != nil { + in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime + *out = new(bool) **out = **in } - if in.SessionPinningFilters != nil { - in, out := &in.SessionPinningFilters, &out.SessionPinningFilters - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectionPoolConfigObservation. -func (in *ConnectionPoolConfigObservation) DeepCopy() *ConnectionPoolConfigObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRestoreToPointInTimeObservation. +func (in *ClusterRestoreToPointInTimeObservation) DeepCopy() *ClusterRestoreToPointInTimeObservation { if in == nil { return nil } - out := new(ConnectionPoolConfigObservation) + out := new(ClusterRestoreToPointInTimeObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ConnectionPoolConfigParameters) DeepCopyInto(out *ConnectionPoolConfigParameters) { +func (in *ClusterRestoreToPointInTimeParameters) DeepCopyInto(out *ClusterRestoreToPointInTimeParameters) { *out = *in - if in.ConnectionBorrowTimeout != nil { - in, out := &in.ConnectionBorrowTimeout, &out.ConnectionBorrowTimeout - *out = new(float64) + if in.RestoreToTime != nil { + in, out := &in.RestoreToTime, &out.RestoreToTime + *out = new(string) **out = **in } - if in.InitQuery != nil { - in, out := &in.InitQuery, &out.InitQuery + if in.RestoreType != nil { + in, out := &in.RestoreType, &out.RestoreType *out = new(string) **out = **in } - if in.MaxConnectionsPercent != nil { - in, out := &in.MaxConnectionsPercent, &out.MaxConnectionsPercent - *out = new(float64) + if in.SourceClusterIdentifier != nil { + in, out := &in.SourceClusterIdentifier, &out.SourceClusterIdentifier + *out = new(string) **out = **in } - if in.MaxIdleConnectionsPercent != nil { - in, out := &in.MaxIdleConnectionsPercent, &out.MaxIdleConnectionsPercent - *out = new(float64) - **out = **in + if in.SourceClusterIdentifierRef != nil { + in, out := &in.SourceClusterIdentifierRef, &out.SourceClusterIdentifierRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) } - if in.SessionPinningFilters != nil { - in, out := &in.SessionPinningFilters, &out.SessionPinningFilters - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } + if in.SourceClusterIdentifierSelector != nil { + in, out := &in.SourceClusterIdentifierSelector, &out.SourceClusterIdentifierSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.UseLatestRestorableTime != nil { + in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime + *out = new(bool) + **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectionPoolConfigParameters. -func (in *ConnectionPoolConfigParameters) DeepCopy() *ConnectionPoolConfigParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRestoreToPointInTimeParameters. +func (in *ClusterRestoreToPointInTimeParameters) DeepCopy() *ClusterRestoreToPointInTimeParameters { if in == nil { return nil } - out := new(ConnectionPoolConfigParameters) + out := new(ClusterRestoreToPointInTimeParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplication) DeepCopyInto(out *DBInstanceAutomatedBackupsReplication) { +func (in *ClusterRoleAssociation) DeepCopyInto(out *ClusterRoleAssociation) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -2934,18 +2983,18 @@ func (in *DBInstanceAutomatedBackupsReplication) DeepCopyInto(out *DBInstanceAut in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplication. -func (in *DBInstanceAutomatedBackupsReplication) DeepCopy() *DBInstanceAutomatedBackupsReplication { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociation. +func (in *ClusterRoleAssociation) DeepCopy() *ClusterRoleAssociation { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplication) + out := new(ClusterRoleAssociation) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *DBInstanceAutomatedBackupsReplication) DeepCopyObject() runtime.Object { +func (in *ClusterRoleAssociation) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -2953,31 +3002,56 @@ func (in *DBInstanceAutomatedBackupsReplication) DeepCopyObject() runtime.Object } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationList) { +func (in *ClusterRoleAssociationInitParameters) DeepCopyInto(out *ClusterRoleAssociationInitParameters) { + *out = *in + if in.FeatureName != nil { + in, out := &in.FeatureName, &out.FeatureName + *out = new(string) + **out = **in + } + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationInitParameters. +func (in *ClusterRoleAssociationInitParameters) DeepCopy() *ClusterRoleAssociationInitParameters { + if in == nil { + return nil + } + out := new(ClusterRoleAssociationInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterRoleAssociationList) DeepCopyInto(out *ClusterRoleAssociationList) { *out = *in out.TypeMeta = in.TypeMeta in.ListMeta.DeepCopyInto(&out.ListMeta) if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]DBInstanceAutomatedBackupsReplication, len(*in)) + *out = make([]ClusterRoleAssociation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationList. -func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopy() *DBInstanceAutomatedBackupsReplicationList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationList. +func (in *ClusterRoleAssociationList) DeepCopy() *ClusterRoleAssociationList { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplicationList) + out := new(ClusterRoleAssociationList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopyObject() runtime.Object { +func (in *ClusterRoleAssociationList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -2985,65 +3059,60 @@ func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopyObject() runtime.Ob } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplicationObservation) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationObservation) { +func (in *ClusterRoleAssociationObservation) DeepCopyInto(out *ClusterRoleAssociationObservation) { *out = *in - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.DBClusterIdentifier != nil { + in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier *out = new(string) **out = **in } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.FeatureName != nil { + in, out := &in.FeatureName, &out.FeatureName *out = new(string) **out = **in } - if in.PreSignedURL != nil { - in, out := &in.PreSignedURL, &out.PreSignedURL + if in.ID != nil { + in, out := &in.ID, &out.ID *out = new(string) **out = **in } - if in.RetentionPeriod != nil { - in, out := &in.RetentionPeriod, &out.RetentionPeriod - *out = new(float64) - **out = **in - } - if in.SourceDBInstanceArn != nil { - in, out := &in.SourceDBInstanceArn, &out.SourceDBInstanceArn + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn *out = new(string) **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationObservation. -func (in *DBInstanceAutomatedBackupsReplicationObservation) DeepCopy() *DBInstanceAutomatedBackupsReplicationObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationObservation. +func (in *ClusterRoleAssociationObservation) DeepCopy() *ClusterRoleAssociationObservation { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplicationObservation) + out := new(ClusterRoleAssociationObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplicationParameters) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationParameters) { +func (in *ClusterRoleAssociationParameters) DeepCopyInto(out *ClusterRoleAssociationParameters) { *out = *in - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.DBClusterIdentifier != nil { + in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier *out = new(string) **out = **in } - if in.KMSKeyIDRef != nil { - in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef + if in.DBClusterIdentifierRef != nil { + in, out := &in.DBClusterIdentifierRef, &out.DBClusterIdentifierRef *out = new(v1.Reference) (*in).DeepCopyInto(*out) } - if in.KMSKeyIDSelector != nil { - in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector + if in.DBClusterIdentifierSelector != nil { + in, out := &in.DBClusterIdentifierSelector, &out.DBClusterIdentifierSelector *out = new(v1.Selector) (*in).DeepCopyInto(*out) } - if in.PreSignedURL != nil { - in, out := &in.PreSignedURL, &out.PreSignedURL + if in.FeatureName != nil { + in, out := &in.FeatureName, &out.FeatureName *out = new(string) **out = **in } @@ -3052,226 +3121,210 @@ func (in *DBInstanceAutomatedBackupsReplicationParameters) DeepCopyInto(out *DBI *out = new(string) **out = **in } - if in.RetentionPeriod != nil { - in, out := &in.RetentionPeriod, &out.RetentionPeriod - *out = new(float64) - **out = **in - } - if in.SourceDBInstanceArn != nil { - in, out := &in.SourceDBInstanceArn, &out.SourceDBInstanceArn + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn *out = new(string) **out = **in } - if in.SourceDBInstanceArnRef != nil { - in, out := &in.SourceDBInstanceArnRef, &out.SourceDBInstanceArnRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.SourceDBInstanceArnSelector != nil { - in, out := &in.SourceDBInstanceArnSelector, &out.SourceDBInstanceArnSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationParameters. -func (in *DBInstanceAutomatedBackupsReplicationParameters) DeepCopy() *DBInstanceAutomatedBackupsReplicationParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationParameters. +func (in *ClusterRoleAssociationParameters) DeepCopy() *ClusterRoleAssociationParameters { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplicationParameters) + out := new(ClusterRoleAssociationParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplicationSpec) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationSpec) { +func (in *ClusterRoleAssociationSpec) DeepCopyInto(out *ClusterRoleAssociationSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationSpec. -func (in *DBInstanceAutomatedBackupsReplicationSpec) DeepCopy() *DBInstanceAutomatedBackupsReplicationSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationSpec. +func (in *ClusterRoleAssociationSpec) DeepCopy() *ClusterRoleAssociationSpec { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplicationSpec) + out := new(ClusterRoleAssociationSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBInstanceAutomatedBackupsReplicationStatus) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationStatus) { +func (in *ClusterRoleAssociationStatus) DeepCopyInto(out *ClusterRoleAssociationStatus) { *out = *in in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationStatus. -func (in *DBInstanceAutomatedBackupsReplicationStatus) DeepCopy() *DBInstanceAutomatedBackupsReplicationStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterRoleAssociationStatus. +func (in *ClusterRoleAssociationStatus) DeepCopy() *ClusterRoleAssociationStatus { if in == nil { return nil } - out := new(DBInstanceAutomatedBackupsReplicationStatus) + out := new(ClusterRoleAssociationStatus) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopy) DeepCopyInto(out *DBSnapshotCopy) { +func (in *ClusterS3ImportInitParameters) DeepCopyInto(out *ClusterS3ImportInitParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopy. -func (in *DBSnapshotCopy) DeepCopy() *DBSnapshotCopy { - if in == nil { - return nil + if in.BucketName != nil { + in, out := &in.BucketName, &out.BucketName + *out = new(string) + **out = **in } - out := new(DBSnapshotCopy) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *DBSnapshotCopy) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c + if in.BucketPrefix != nil { + in, out := &in.BucketPrefix, &out.BucketPrefix + *out = new(string) + **out = **in } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopyList) DeepCopyInto(out *DBSnapshotCopyList) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]DBSnapshotCopy, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.IngestionRole != nil { + in, out := &in.IngestionRole, &out.IngestionRole + *out = new(string) + **out = **in + } + if in.SourceEngine != nil { + in, out := &in.SourceEngine, &out.SourceEngine + *out = new(string) + **out = **in + } + if in.SourceEngineVersion != nil { + in, out := &in.SourceEngineVersion, &out.SourceEngineVersion + *out = new(string) + **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyList. -func (in *DBSnapshotCopyList) DeepCopy() *DBSnapshotCopyList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterS3ImportInitParameters. +func (in *ClusterS3ImportInitParameters) DeepCopy() *ClusterS3ImportInitParameters { if in == nil { return nil } - out := new(DBSnapshotCopyList) + out := new(ClusterS3ImportInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *DBSnapshotCopyList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopyObservation) DeepCopyInto(out *DBSnapshotCopyObservation) { +func (in *ClusterS3ImportObservation) DeepCopyInto(out *ClusterS3ImportObservation) { *out = *in - if in.AllocatedStorage != nil { - in, out := &in.AllocatedStorage, &out.AllocatedStorage - *out = new(float64) - **out = **in - } - if in.AvailabilityZone != nil { - in, out := &in.AvailabilityZone, &out.AvailabilityZone - *out = new(string) - **out = **in - } - if in.CopyTags != nil { - in, out := &in.CopyTags, &out.CopyTags - *out = new(bool) - **out = **in - } - if in.DBSnapshotArn != nil { - in, out := &in.DBSnapshotArn, &out.DBSnapshotArn + if in.BucketName != nil { + in, out := &in.BucketName, &out.BucketName *out = new(string) **out = **in } - if in.DestinationRegion != nil { - in, out := &in.DestinationRegion, &out.DestinationRegion + if in.BucketPrefix != nil { + in, out := &in.BucketPrefix, &out.BucketPrefix *out = new(string) **out = **in } - if in.Encrypted != nil { - in, out := &in.Encrypted, &out.Encrypted - *out = new(bool) - **out = **in - } - if in.Engine != nil { - in, out := &in.Engine, &out.Engine + if in.IngestionRole != nil { + in, out := &in.IngestionRole, &out.IngestionRole *out = new(string) **out = **in } - if in.EngineVersion != nil { - in, out := &in.EngineVersion, &out.EngineVersion + if in.SourceEngine != nil { + in, out := &in.SourceEngine, &out.SourceEngine *out = new(string) **out = **in } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.SourceEngineVersion != nil { + in, out := &in.SourceEngineVersion, &out.SourceEngineVersion *out = new(string) **out = **in } - if in.Iops != nil { - in, out := &in.Iops, &out.Iops - *out = new(float64) - **out = **in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterS3ImportObservation. +func (in *ClusterS3ImportObservation) DeepCopy() *ClusterS3ImportObservation { + if in == nil { + return nil } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + out := new(ClusterS3ImportObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterS3ImportParameters) DeepCopyInto(out *ClusterS3ImportParameters) { + *out = *in + if in.BucketName != nil { + in, out := &in.BucketName, &out.BucketName *out = new(string) **out = **in } - if in.LicenseModel != nil { - in, out := &in.LicenseModel, &out.LicenseModel + if in.BucketPrefix != nil { + in, out := &in.BucketPrefix, &out.BucketPrefix *out = new(string) **out = **in } - if in.OptionGroupName != nil { - in, out := &in.OptionGroupName, &out.OptionGroupName + if in.IngestionRole != nil { + in, out := &in.IngestionRole, &out.IngestionRole *out = new(string) **out = **in } - if in.Port != nil { - in, out := &in.Port, &out.Port - *out = new(float64) - **out = **in - } - if in.PresignedURL != nil { - in, out := &in.PresignedURL, &out.PresignedURL + if in.SourceEngine != nil { + in, out := &in.SourceEngine, &out.SourceEngine *out = new(string) **out = **in } - if in.SnapshotType != nil { - in, out := &in.SnapshotType, &out.SnapshotType + if in.SourceEngineVersion != nil { + in, out := &in.SourceEngineVersion, &out.SourceEngineVersion *out = new(string) **out = **in } - if in.SourceDBSnapshotIdentifier != nil { - in, out := &in.SourceDBSnapshotIdentifier, &out.SourceDBSnapshotIdentifier - *out = new(string) - **out = **in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterS3ImportParameters. +func (in *ClusterS3ImportParameters) DeepCopy() *ClusterS3ImportParameters { + if in == nil { + return nil } - if in.SourceRegion != nil { - in, out := &in.SourceRegion, &out.SourceRegion - *out = new(string) - **out = **in + out := new(ClusterS3ImportParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterSnapshot) DeepCopyInto(out *ClusterSnapshot) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshot. +func (in *ClusterSnapshot) DeepCopy() *ClusterSnapshot { + if in == nil { + return nil } - if in.StorageType != nil { - in, out := &in.StorageType, &out.StorageType + out := new(ClusterSnapshot) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterSnapshot) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterSnapshotInitParameters) DeepCopyInto(out *ClusterSnapshotInitParameters) { + *out = *in + if in.DBClusterSnapshotIdentifier != nil { + in, out := &in.DBClusterSnapshotIdentifier, &out.DBClusterSnapshotIdentifier *out = new(string) **out = **in } @@ -3283,7 +3336,8 @@ func (in *DBSnapshotCopyObservation) DeepCopyInto(out *DBSnapshotCopyObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -3298,97 +3352,141 @@ func (in *DBSnapshotCopyObservation) DeepCopyInto(out *DBSnapshotCopyObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } - if in.TargetCustomAvailabilityZone != nil { - in, out := &in.TargetCustomAvailabilityZone, &out.TargetCustomAvailabilityZone - *out = new(string) - **out = **in - } - if in.TargetDBSnapshotIdentifier != nil { - in, out := &in.TargetDBSnapshotIdentifier, &out.TargetDBSnapshotIdentifier - *out = new(string) - **out = **in - } - if in.VPCID != nil { - in, out := &in.VPCID, &out.VPCID - *out = new(string) - **out = **in - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyObservation. -func (in *DBSnapshotCopyObservation) DeepCopy() *DBSnapshotCopyObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotInitParameters. +func (in *ClusterSnapshotInitParameters) DeepCopy() *ClusterSnapshotInitParameters { if in == nil { return nil } - out := new(DBSnapshotCopyObservation) + out := new(ClusterSnapshotInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopyParameters) DeepCopyInto(out *DBSnapshotCopyParameters) { +func (in *ClusterSnapshotList) DeepCopyInto(out *ClusterSnapshotList) { *out = *in - if in.CopyTags != nil { - in, out := &in.CopyTags, &out.CopyTags - *out = new(bool) + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ClusterSnapshot, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotList. +func (in *ClusterSnapshotList) DeepCopy() *ClusterSnapshotList { + if in == nil { + return nil + } + out := new(ClusterSnapshotList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClusterSnapshotList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterSnapshotObservation) DeepCopyInto(out *ClusterSnapshotObservation) { + *out = *in + if in.AllocatedStorage != nil { + in, out := &in.AllocatedStorage, &out.AllocatedStorage + *out = new(float64) **out = **in } - if in.DestinationRegion != nil { - in, out := &in.DestinationRegion, &out.DestinationRegion + if in.AvailabilityZones != nil { + in, out := &in.AvailabilityZones, &out.AvailabilityZones + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.DBClusterIdentifier != nil { + in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier *out = new(string) **out = **in } - if in.KMSKeyID != nil { - in, out := &in.KMSKeyID, &out.KMSKeyID + if in.DBClusterSnapshotArn != nil { + in, out := &in.DBClusterSnapshotArn, &out.DBClusterSnapshotArn *out = new(string) **out = **in } - if in.KMSKeyIDRef != nil { - in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) + if in.DBClusterSnapshotIdentifier != nil { + in, out := &in.DBClusterSnapshotIdentifier, &out.DBClusterSnapshotIdentifier + *out = new(string) + **out = **in } - if in.KMSKeyIDSelector != nil { - in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in } - if in.OptionGroupName != nil { - in, out := &in.OptionGroupName, &out.OptionGroupName + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion *out = new(string) **out = **in } - if in.PresignedURL != nil { - in, out := &in.PresignedURL, &out.PresignedURL + if in.ID != nil { + in, out := &in.ID, &out.ID *out = new(string) **out = **in } - if in.Region != nil { - in, out := &in.Region, &out.Region + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID *out = new(string) **out = **in } - if in.SourceDBSnapshotIdentifier != nil { - in, out := &in.SourceDBSnapshotIdentifier, &out.SourceDBSnapshotIdentifier + if in.LicenseModel != nil { + in, out := &in.LicenseModel, &out.LicenseModel *out = new(string) **out = **in } - if in.SourceDBSnapshotIdentifierRef != nil { - in, out := &in.SourceDBSnapshotIdentifierRef, &out.SourceDBSnapshotIdentifierRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in } - if in.SourceDBSnapshotIdentifierSelector != nil { - in, out := &in.SourceDBSnapshotIdentifierSelector, &out.SourceDBSnapshotIdentifierSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) + if in.SnapshotType != nil { + in, out := &in.SnapshotType, &out.SnapshotType + *out = new(string) + **out = **in + } + if in.SourceDBClusterSnapshotArn != nil { + in, out := &in.SourceDBClusterSnapshotArn, &out.SourceDBClusterSnapshotArn + *out = new(string) + **out = **in + } + if in.Status != nil { + in, out := &in.Status, &out.Status + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in } if in.Tags != nil { in, out := &in.Tags, &out.Tags @@ -3398,7 +3496,8 @@ func (in *DBSnapshotCopyParameters) DeepCopyInto(out *DBSnapshotCopyParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -3413,169 +3512,244 @@ func (in *DBSnapshotCopyParameters) DeepCopyInto(out *DBSnapshotCopyParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } (*out)[key] = outVal } } - if in.TargetCustomAvailabilityZone != nil { - in, out := &in.TargetCustomAvailabilityZone, &out.TargetCustomAvailabilityZone + if in.VPCID != nil { + in, out := &in.VPCID, &out.VPCID *out = new(string) **out = **in } - if in.TargetDBSnapshotIdentifier != nil { - in, out := &in.TargetDBSnapshotIdentifier, &out.TargetDBSnapshotIdentifier +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotObservation. +func (in *ClusterSnapshotObservation) DeepCopy() *ClusterSnapshotObservation { + if in == nil { + return nil + } + out := new(ClusterSnapshotObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterSnapshotParameters) DeepCopyInto(out *ClusterSnapshotParameters) { + *out = *in + if in.DBClusterIdentifier != nil { + in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier + *out = new(string) + **out = **in + } + if in.DBClusterIdentifierRef != nil { + in, out := &in.DBClusterIdentifierRef, &out.DBClusterIdentifierRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.DBClusterIdentifierSelector != nil { + in, out := &in.DBClusterIdentifierSelector, &out.DBClusterIdentifierSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.DBClusterSnapshotIdentifier != nil { + in, out := &in.DBClusterSnapshotIdentifier, &out.DBClusterSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.Region != nil { + in, out := &in.Region, &out.Region *out = new(string) **out = **in } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyParameters. -func (in *DBSnapshotCopyParameters) DeepCopy() *DBSnapshotCopyParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotParameters. +func (in *ClusterSnapshotParameters) DeepCopy() *ClusterSnapshotParameters { if in == nil { return nil } - out := new(DBSnapshotCopyParameters) + out := new(ClusterSnapshotParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopySpec) DeepCopyInto(out *DBSnapshotCopySpec) { +func (in *ClusterSnapshotSpec) DeepCopyInto(out *ClusterSnapshotSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopySpec. -func (in *DBSnapshotCopySpec) DeepCopy() *DBSnapshotCopySpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotSpec. +func (in *ClusterSnapshotSpec) DeepCopy() *ClusterSnapshotSpec { if in == nil { return nil } - out := new(DBSnapshotCopySpec) + out := new(ClusterSnapshotSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DBSnapshotCopyStatus) DeepCopyInto(out *DBSnapshotCopyStatus) { +func (in *ClusterSnapshotStatus) DeepCopyInto(out *ClusterSnapshotStatus) { *out = *in in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyStatus. -func (in *DBSnapshotCopyStatus) DeepCopy() *DBSnapshotCopyStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSnapshotStatus. +func (in *ClusterSnapshotStatus) DeepCopy() *ClusterSnapshotStatus { if in == nil { return nil } - out := new(DBSnapshotCopyStatus) + out := new(ClusterSnapshotStatus) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscription) DeepCopyInto(out *EventSubscription) { +func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec) { *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscription. -func (in *EventSubscription) DeepCopy() *EventSubscription { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec. +func (in *ClusterSpec) DeepCopy() *ClusterSpec { if in == nil { return nil } - out := new(EventSubscription) + out := new(ClusterSpec) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *EventSubscription) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClusterStatus) DeepCopyInto(out *ClusterStatus) { + *out = *in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterStatus. +func (in *ClusterStatus) DeepCopy() *ClusterStatus { + if in == nil { + return nil } - return nil + out := new(ClusterStatus) + in.DeepCopyInto(out) + return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscriptionList) DeepCopyInto(out *EventSubscriptionList) { +func (in *ConnectionPoolConfigInitParameters) DeepCopyInto(out *ConnectionPoolConfigInitParameters) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]EventSubscription, len(*in)) + if in.ConnectionBorrowTimeout != nil { + in, out := &in.ConnectionBorrowTimeout, &out.ConnectionBorrowTimeout + *out = new(float64) + **out = **in + } + if in.InitQuery != nil { + in, out := &in.InitQuery, &out.InitQuery + *out = new(string) + **out = **in + } + if in.MaxConnectionsPercent != nil { + in, out := &in.MaxConnectionsPercent, &out.MaxConnectionsPercent + *out = new(float64) + **out = **in + } + if in.MaxIdleConnectionsPercent != nil { + in, out := &in.MaxIdleConnectionsPercent, &out.MaxIdleConnectionsPercent + *out = new(float64) + **out = **in + } + if in.SessionPinningFilters != nil { + in, out := &in.SessionPinningFilters, &out.SessionPinningFilters + *out = make([]*string, len(*in)) for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } } } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionList. -func (in *EventSubscriptionList) DeepCopy() *EventSubscriptionList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectionPoolConfigInitParameters. +func (in *ConnectionPoolConfigInitParameters) DeepCopy() *ConnectionPoolConfigInitParameters { if in == nil { return nil } - out := new(EventSubscriptionList) + out := new(ConnectionPoolConfigInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *EventSubscriptionList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscriptionObservation) DeepCopyInto(out *EventSubscriptionObservation) { +func (in *ConnectionPoolConfigObservation) DeepCopyInto(out *ConnectionPoolConfigObservation) { *out = *in - if in.Arn != nil { - in, out := &in.Arn, &out.Arn - *out = new(string) + if in.ConnectionBorrowTimeout != nil { + in, out := &in.ConnectionBorrowTimeout, &out.ConnectionBorrowTimeout + *out = new(float64) **out = **in } - if in.CustomerAwsID != nil { - in, out := &in.CustomerAwsID, &out.CustomerAwsID + if in.InitQuery != nil { + in, out := &in.InitQuery, &out.InitQuery *out = new(string) **out = **in } - if in.Enabled != nil { - in, out := &in.Enabled, &out.Enabled - *out = new(bool) - **out = **in - } - if in.EventCategories != nil { - in, out := &in.EventCategories, &out.EventCategories - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } - if in.ID != nil { - in, out := &in.ID, &out.ID - *out = new(string) + if in.MaxConnectionsPercent != nil { + in, out := &in.MaxConnectionsPercent, &out.MaxConnectionsPercent + *out = new(float64) **out = **in } - if in.SnsTopic != nil { - in, out := &in.SnsTopic, &out.SnsTopic - *out = new(string) + if in.MaxIdleConnectionsPercent != nil { + in, out := &in.MaxIdleConnectionsPercent, &out.MaxIdleConnectionsPercent + *out = new(float64) **out = **in } - if in.SourceIds != nil { - in, out := &in.SourceIds, &out.SourceIds + if in.SessionPinningFilters != nil { + in, out := &in.SessionPinningFilters, &out.SessionPinningFilters *out = make([]*string, len(*in)) for i := range *in { if (*in)[i] != nil { @@ -3585,84 +3759,43 @@ func (in *EventSubscriptionObservation) DeepCopyInto(out *EventSubscriptionObser } } } - if in.SourceType != nil { - in, out := &in.SourceType, &out.SourceType - *out = new(string) - **out = **in - } - if in.Tags != nil { - in, out := &in.Tags, &out.Tags - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } - } - if in.TagsAll != nil { - in, out := &in.TagsAll, &out.TagsAll - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionObservation. -func (in *EventSubscriptionObservation) DeepCopy() *EventSubscriptionObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectionPoolConfigObservation. +func (in *ConnectionPoolConfigObservation) DeepCopy() *ConnectionPoolConfigObservation { if in == nil { return nil } - out := new(EventSubscriptionObservation) + out := new(ConnectionPoolConfigObservation) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscriptionParameters) DeepCopyInto(out *EventSubscriptionParameters) { +func (in *ConnectionPoolConfigParameters) DeepCopyInto(out *ConnectionPoolConfigParameters) { *out = *in - if in.Enabled != nil { - in, out := &in.Enabled, &out.Enabled - *out = new(bool) + if in.ConnectionBorrowTimeout != nil { + in, out := &in.ConnectionBorrowTimeout, &out.ConnectionBorrowTimeout + *out = new(float64) **out = **in } - if in.EventCategories != nil { - in, out := &in.EventCategories, &out.EventCategories - *out = make([]*string, len(*in)) - for i := range *in { - if (*in)[i] != nil { - in, out := &(*in)[i], &(*out)[i] - *out = new(string) - **out = **in - } - } - } - if in.Region != nil { - in, out := &in.Region, &out.Region + if in.InitQuery != nil { + in, out := &in.InitQuery, &out.InitQuery *out = new(string) **out = **in } - if in.SnsTopic != nil { - in, out := &in.SnsTopic, &out.SnsTopic - *out = new(string) + if in.MaxConnectionsPercent != nil { + in, out := &in.MaxConnectionsPercent, &out.MaxConnectionsPercent + *out = new(float64) **out = **in } - if in.SourceIds != nil { - in, out := &in.SourceIds, &out.SourceIds + if in.MaxIdleConnectionsPercent != nil { + in, out := &in.MaxIdleConnectionsPercent, &out.MaxIdleConnectionsPercent + *out = new(float64) + **out = **in + } + if in.SessionPinningFilters != nil { + in, out := &in.SessionPinningFilters, &out.SessionPinningFilters *out = make([]*string, len(*in)) for i := range *in { if (*in)[i] != nil { @@ -3672,108 +3805,96 @@ func (in *EventSubscriptionParameters) DeepCopyInto(out *EventSubscriptionParame } } } - if in.SourceType != nil { - in, out := &in.SourceType, &out.SourceType - *out = new(string) - **out = **in - } - if in.Tags != nil { - in, out := &in.Tags, &out.Tags - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } - } - if in.TagsAll != nil { - in, out := &in.TagsAll, &out.TagsAll - *out = make(map[string]*string, len(*in)) - for key, val := range *in { - var outVal *string - if val == nil { - (*out)[key] = nil - } else { - in, out := &val, &outVal - *out = new(string) - **out = **in - } - (*out)[key] = outVal - } - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionParameters. -func (in *EventSubscriptionParameters) DeepCopy() *EventSubscriptionParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConnectionPoolConfigParameters. +func (in *ConnectionPoolConfigParameters) DeepCopy() *ConnectionPoolConfigParameters { if in == nil { return nil } - out := new(EventSubscriptionParameters) + out := new(ConnectionPoolConfigParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscriptionSpec) DeepCopyInto(out *EventSubscriptionSpec) { +func (in *DBInstanceAutomatedBackupsReplication) DeepCopyInto(out *DBInstanceAutomatedBackupsReplication) { *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionSpec. -func (in *EventSubscriptionSpec) DeepCopy() *EventSubscriptionSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplication. +func (in *DBInstanceAutomatedBackupsReplication) DeepCopy() *DBInstanceAutomatedBackupsReplication { if in == nil { return nil } - out := new(EventSubscriptionSpec) + out := new(DBInstanceAutomatedBackupsReplication) in.DeepCopyInto(out) return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DBInstanceAutomatedBackupsReplication) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *EventSubscriptionStatus) DeepCopyInto(out *EventSubscriptionStatus) { +func (in *DBInstanceAutomatedBackupsReplicationInitParameters) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationInitParameters) { *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) + if in.PreSignedURL != nil { + in, out := &in.PreSignedURL, &out.PreSignedURL + *out = new(string) + **out = **in + } + if in.RetentionPeriod != nil { + in, out := &in.RetentionPeriod, &out.RetentionPeriod + *out = new(float64) + **out = **in + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionStatus. -func (in *EventSubscriptionStatus) DeepCopy() *EventSubscriptionStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationInitParameters. +func (in *DBInstanceAutomatedBackupsReplicationInitParameters) DeepCopy() *DBInstanceAutomatedBackupsReplicationInitParameters { if in == nil { return nil } - out := new(EventSubscriptionStatus) + out := new(DBInstanceAutomatedBackupsReplicationInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalCluster) DeepCopyInto(out *GlobalCluster) { +func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationList) { *out = *in out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DBInstanceAutomatedBackupsReplication, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalCluster. -func (in *GlobalCluster) DeepCopy() *GlobalCluster { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationList. +func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopy() *DBInstanceAutomatedBackupsReplicationList { if in == nil { return nil } - out := new(GlobalCluster) + out := new(DBInstanceAutomatedBackupsReplicationList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *GlobalCluster) DeepCopyObject() runtime.Object { +func (in *DBInstanceAutomatedBackupsReplicationList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -3781,166 +3902,1414 @@ func (in *GlobalCluster) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterList) DeepCopyInto(out *GlobalClusterList) { +func (in *DBInstanceAutomatedBackupsReplicationObservation) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationObservation) { *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]GlobalCluster, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.ID != nil { + in, out := &in.ID, &out.ID + *out = new(string) + **out = **in + } + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } + if in.PreSignedURL != nil { + in, out := &in.PreSignedURL, &out.PreSignedURL + *out = new(string) + **out = **in + } + if in.RetentionPeriod != nil { + in, out := &in.RetentionPeriod, &out.RetentionPeriod + *out = new(float64) + **out = **in + } + if in.SourceDBInstanceArn != nil { + in, out := &in.SourceDBInstanceArn, &out.SourceDBInstanceArn + *out = new(string) + **out = **in } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterList. -func (in *GlobalClusterList) DeepCopy() *GlobalClusterList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationObservation. +func (in *DBInstanceAutomatedBackupsReplicationObservation) DeepCopy() *DBInstanceAutomatedBackupsReplicationObservation { if in == nil { return nil } - out := new(GlobalClusterList) + out := new(DBInstanceAutomatedBackupsReplicationObservation) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *GlobalClusterList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterMembersObservation) DeepCopyInto(out *GlobalClusterMembersObservation) { +func (in *DBInstanceAutomatedBackupsReplicationParameters) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationParameters) { *out = *in - if in.DBClusterArn != nil { - in, out := &in.DBClusterArn, &out.DBClusterArn + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID *out = new(string) **out = **in } - if in.IsWriter != nil { - in, out := &in.IsWriter, &out.IsWriter - *out = new(bool) + if in.KMSKeyIDRef != nil { + in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.KMSKeyIDSelector != nil { + in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.PreSignedURL != nil { + in, out := &in.PreSignedURL, &out.PreSignedURL + *out = new(string) + **out = **in + } + if in.Region != nil { + in, out := &in.Region, &out.Region + *out = new(string) + **out = **in + } + if in.RetentionPeriod != nil { + in, out := &in.RetentionPeriod, &out.RetentionPeriod + *out = new(float64) + **out = **in + } + if in.SourceDBInstanceArn != nil { + in, out := &in.SourceDBInstanceArn, &out.SourceDBInstanceArn + *out = new(string) **out = **in } + if in.SourceDBInstanceArnRef != nil { + in, out := &in.SourceDBInstanceArnRef, &out.SourceDBInstanceArnRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.SourceDBInstanceArnSelector != nil { + in, out := &in.SourceDBInstanceArnSelector, &out.SourceDBInstanceArnSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersObservation. -func (in *GlobalClusterMembersObservation) DeepCopy() *GlobalClusterMembersObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationParameters. +func (in *DBInstanceAutomatedBackupsReplicationParameters) DeepCopy() *DBInstanceAutomatedBackupsReplicationParameters { if in == nil { return nil } - out := new(GlobalClusterMembersObservation) + out := new(DBInstanceAutomatedBackupsReplicationParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterMembersParameters) DeepCopyInto(out *GlobalClusterMembersParameters) { +func (in *DBInstanceAutomatedBackupsReplicationSpec) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationSpec) { *out = *in + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersParameters. -func (in *GlobalClusterMembersParameters) DeepCopy() *GlobalClusterMembersParameters { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationSpec. +func (in *DBInstanceAutomatedBackupsReplicationSpec) DeepCopy() *DBInstanceAutomatedBackupsReplicationSpec { if in == nil { return nil } - out := new(GlobalClusterMembersParameters) + out := new(DBInstanceAutomatedBackupsReplicationSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterObservation) DeepCopyInto(out *GlobalClusterObservation) { +func (in *DBInstanceAutomatedBackupsReplicationStatus) DeepCopyInto(out *DBInstanceAutomatedBackupsReplicationStatus) { *out = *in - if in.Arn != nil { - in, out := &in.Arn, &out.Arn - *out = new(string) - **out = **in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBInstanceAutomatedBackupsReplicationStatus. +func (in *DBInstanceAutomatedBackupsReplicationStatus) DeepCopy() *DBInstanceAutomatedBackupsReplicationStatus { + if in == nil { + return nil } - if in.DatabaseName != nil { - in, out := &in.DatabaseName, &out.DatabaseName - *out = new(string) - **out = **in + out := new(DBInstanceAutomatedBackupsReplicationStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopy) DeepCopyInto(out *DBSnapshotCopy) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopy. +func (in *DBSnapshotCopy) DeepCopy() *DBSnapshotCopy { + if in == nil { + return nil } - if in.DeletionProtection != nil { - in, out := &in.DeletionProtection, &out.DeletionProtection + out := new(DBSnapshotCopy) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DBSnapshotCopy) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopyInitParameters) DeepCopyInto(out *DBSnapshotCopyInitParameters) { + *out = *in + if in.CopyTags != nil { + in, out := &in.CopyTags, &out.CopyTags *out = new(bool) **out = **in } - if in.Engine != nil { - in, out := &in.Engine, &out.Engine + if in.DestinationRegion != nil { + in, out := &in.DestinationRegion, &out.DestinationRegion *out = new(string) **out = **in } - if in.EngineVersion != nil { - in, out := &in.EngineVersion, &out.EngineVersion + if in.OptionGroupName != nil { + in, out := &in.OptionGroupName, &out.OptionGroupName *out = new(string) **out = **in } - if in.EngineVersionActual != nil { - in, out := &in.EngineVersionActual, &out.EngineVersionActual + if in.PresignedURL != nil { + in, out := &in.PresignedURL, &out.PresignedURL *out = new(string) **out = **in } - if in.ForceDestroy != nil { - in, out := &in.ForceDestroy, &out.ForceDestroy - *out = new(bool) - **out = **in - } - if in.GlobalClusterMembers != nil { - in, out := &in.GlobalClusterMembers, &out.GlobalClusterMembers - *out = make([]GlobalClusterMembersObservation, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal } } - if in.GlobalClusterResourceID != nil { - in, out := &in.GlobalClusterResourceID, &out.GlobalClusterResourceID - *out = new(string) - **out = **in + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } } - if in.ID != nil { - in, out := &in.ID, &out.ID + if in.TargetCustomAvailabilityZone != nil { + in, out := &in.TargetCustomAvailabilityZone, &out.TargetCustomAvailabilityZone *out = new(string) **out = **in } - if in.SourceDBClusterIdentifier != nil { - in, out := &in.SourceDBClusterIdentifier, &out.SourceDBClusterIdentifier + if in.TargetDBSnapshotIdentifier != nil { + in, out := &in.TargetDBSnapshotIdentifier, &out.TargetDBSnapshotIdentifier *out = new(string) **out = **in } - if in.StorageEncrypted != nil { - in, out := &in.StorageEncrypted, &out.StorageEncrypted - *out = new(bool) - **out = **in - } } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterObservation. -func (in *GlobalClusterObservation) DeepCopy() *GlobalClusterObservation { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyInitParameters. +func (in *DBSnapshotCopyInitParameters) DeepCopy() *DBSnapshotCopyInitParameters { if in == nil { return nil } - out := new(GlobalClusterObservation) + out := new(DBSnapshotCopyInitParameters) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterParameters) DeepCopyInto(out *GlobalClusterParameters) { +func (in *DBSnapshotCopyList) DeepCopyInto(out *DBSnapshotCopyList) { *out = *in - if in.DatabaseName != nil { - in, out := &in.DatabaseName, &out.DatabaseName - *out = new(string) - **out = **in - } - if in.DeletionProtection != nil { - in, out := &in.DeletionProtection, &out.DeletionProtection - *out = new(bool) - **out = **in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DBSnapshotCopy, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyList. +func (in *DBSnapshotCopyList) DeepCopy() *DBSnapshotCopyList { + if in == nil { + return nil + } + out := new(DBSnapshotCopyList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DBSnapshotCopyList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopyObservation) DeepCopyInto(out *DBSnapshotCopyObservation) { + *out = *in + if in.AllocatedStorage != nil { + in, out := &in.AllocatedStorage, &out.AllocatedStorage + *out = new(float64) + **out = **in + } + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) + **out = **in + } + if in.CopyTags != nil { + in, out := &in.CopyTags, &out.CopyTags + *out = new(bool) + **out = **in + } + if in.DBSnapshotArn != nil { + in, out := &in.DBSnapshotArn, &out.DBSnapshotArn + *out = new(string) + **out = **in + } + if in.DestinationRegion != nil { + in, out := &in.DestinationRegion, &out.DestinationRegion + *out = new(string) + **out = **in + } + if in.Encrypted != nil { + in, out := &in.Encrypted, &out.Encrypted + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.ID != nil { + in, out := &in.ID, &out.ID + *out = new(string) + **out = **in + } + if in.Iops != nil { + in, out := &in.Iops, &out.Iops + *out = new(float64) + **out = **in + } + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } + if in.LicenseModel != nil { + in, out := &in.LicenseModel, &out.LicenseModel + *out = new(string) + **out = **in + } + if in.OptionGroupName != nil { + in, out := &in.OptionGroupName, &out.OptionGroupName + *out = new(string) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PresignedURL != nil { + in, out := &in.PresignedURL, &out.PresignedURL + *out = new(string) + **out = **in + } + if in.SnapshotType != nil { + in, out := &in.SnapshotType, &out.SnapshotType + *out = new(string) + **out = **in + } + if in.SourceDBSnapshotIdentifier != nil { + in, out := &in.SourceDBSnapshotIdentifier, &out.SourceDBSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.SourceRegion != nil { + in, out := &in.SourceRegion, &out.SourceRegion + *out = new(string) + **out = **in + } + if in.StorageType != nil { + in, out := &in.StorageType, &out.StorageType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TargetCustomAvailabilityZone != nil { + in, out := &in.TargetCustomAvailabilityZone, &out.TargetCustomAvailabilityZone + *out = new(string) + **out = **in + } + if in.TargetDBSnapshotIdentifier != nil { + in, out := &in.TargetDBSnapshotIdentifier, &out.TargetDBSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.VPCID != nil { + in, out := &in.VPCID, &out.VPCID + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyObservation. +func (in *DBSnapshotCopyObservation) DeepCopy() *DBSnapshotCopyObservation { + if in == nil { + return nil + } + out := new(DBSnapshotCopyObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopyParameters) DeepCopyInto(out *DBSnapshotCopyParameters) { + *out = *in + if in.CopyTags != nil { + in, out := &in.CopyTags, &out.CopyTags + *out = new(bool) + **out = **in + } + if in.DestinationRegion != nil { + in, out := &in.DestinationRegion, &out.DestinationRegion + *out = new(string) + **out = **in + } + if in.KMSKeyID != nil { + in, out := &in.KMSKeyID, &out.KMSKeyID + *out = new(string) + **out = **in + } + if in.KMSKeyIDRef != nil { + in, out := &in.KMSKeyIDRef, &out.KMSKeyIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.KMSKeyIDSelector != nil { + in, out := &in.KMSKeyIDSelector, &out.KMSKeyIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.OptionGroupName != nil { + in, out := &in.OptionGroupName, &out.OptionGroupName + *out = new(string) + **out = **in + } + if in.PresignedURL != nil { + in, out := &in.PresignedURL, &out.PresignedURL + *out = new(string) + **out = **in + } + if in.Region != nil { + in, out := &in.Region, &out.Region + *out = new(string) + **out = **in + } + if in.SourceDBSnapshotIdentifier != nil { + in, out := &in.SourceDBSnapshotIdentifier, &out.SourceDBSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.SourceDBSnapshotIdentifierRef != nil { + in, out := &in.SourceDBSnapshotIdentifierRef, &out.SourceDBSnapshotIdentifierRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.SourceDBSnapshotIdentifierSelector != nil { + in, out := &in.SourceDBSnapshotIdentifierSelector, &out.SourceDBSnapshotIdentifierSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TargetCustomAvailabilityZone != nil { + in, out := &in.TargetCustomAvailabilityZone, &out.TargetCustomAvailabilityZone + *out = new(string) + **out = **in + } + if in.TargetDBSnapshotIdentifier != nil { + in, out := &in.TargetDBSnapshotIdentifier, &out.TargetDBSnapshotIdentifier + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyParameters. +func (in *DBSnapshotCopyParameters) DeepCopy() *DBSnapshotCopyParameters { + if in == nil { + return nil + } + out := new(DBSnapshotCopyParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopySpec) DeepCopyInto(out *DBSnapshotCopySpec) { + *out = *in + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopySpec. +func (in *DBSnapshotCopySpec) DeepCopy() *DBSnapshotCopySpec { + if in == nil { + return nil + } + out := new(DBSnapshotCopySpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DBSnapshotCopyStatus) DeepCopyInto(out *DBSnapshotCopyStatus) { + *out = *in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DBSnapshotCopyStatus. +func (in *DBSnapshotCopyStatus) DeepCopy() *DBSnapshotCopyStatus { + if in == nil { + return nil + } + out := new(DBSnapshotCopyStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscription) DeepCopyInto(out *EventSubscription) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscription. +func (in *EventSubscription) DeepCopy() *EventSubscription { + if in == nil { + return nil + } + out := new(EventSubscription) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *EventSubscription) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionInitParameters) DeepCopyInto(out *EventSubscriptionInitParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.EventCategories != nil { + in, out := &in.EventCategories, &out.EventCategories + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SnsTopic != nil { + in, out := &in.SnsTopic, &out.SnsTopic + *out = new(string) + **out = **in + } + if in.SourceIds != nil { + in, out := &in.SourceIds, &out.SourceIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SourceType != nil { + in, out := &in.SourceType, &out.SourceType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionInitParameters. +func (in *EventSubscriptionInitParameters) DeepCopy() *EventSubscriptionInitParameters { + if in == nil { + return nil + } + out := new(EventSubscriptionInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionList) DeepCopyInto(out *EventSubscriptionList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]EventSubscription, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionList. +func (in *EventSubscriptionList) DeepCopy() *EventSubscriptionList { + if in == nil { + return nil + } + out := new(EventSubscriptionList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *EventSubscriptionList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionObservation) DeepCopyInto(out *EventSubscriptionObservation) { + *out = *in + if in.Arn != nil { + in, out := &in.Arn, &out.Arn + *out = new(string) + **out = **in + } + if in.CustomerAwsID != nil { + in, out := &in.CustomerAwsID, &out.CustomerAwsID + *out = new(string) + **out = **in + } + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.EventCategories != nil { + in, out := &in.EventCategories, &out.EventCategories + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.ID != nil { + in, out := &in.ID, &out.ID + *out = new(string) + **out = **in + } + if in.SnsTopic != nil { + in, out := &in.SnsTopic, &out.SnsTopic + *out = new(string) + **out = **in + } + if in.SourceIds != nil { + in, out := &in.SourceIds, &out.SourceIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SourceType != nil { + in, out := &in.SourceType, &out.SourceType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionObservation. +func (in *EventSubscriptionObservation) DeepCopy() *EventSubscriptionObservation { + if in == nil { + return nil + } + out := new(EventSubscriptionObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionParameters) DeepCopyInto(out *EventSubscriptionParameters) { + *out = *in + if in.Enabled != nil { + in, out := &in.Enabled, &out.Enabled + *out = new(bool) + **out = **in + } + if in.EventCategories != nil { + in, out := &in.EventCategories, &out.EventCategories + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Region != nil { + in, out := &in.Region, &out.Region + *out = new(string) + **out = **in + } + if in.SnsTopic != nil { + in, out := &in.SnsTopic, &out.SnsTopic + *out = new(string) + **out = **in + } + if in.SourceIds != nil { + in, out := &in.SourceIds, &out.SourceIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.SourceType != nil { + in, out := &in.SourceType, &out.SourceType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionParameters. +func (in *EventSubscriptionParameters) DeepCopy() *EventSubscriptionParameters { + if in == nil { + return nil + } + out := new(EventSubscriptionParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionSpec) DeepCopyInto(out *EventSubscriptionSpec) { + *out = *in + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionSpec. +func (in *EventSubscriptionSpec) DeepCopy() *EventSubscriptionSpec { + if in == nil { + return nil + } + out := new(EventSubscriptionSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *EventSubscriptionStatus) DeepCopyInto(out *EventSubscriptionStatus) { + *out = *in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EventSubscriptionStatus. +func (in *EventSubscriptionStatus) DeepCopy() *EventSubscriptionStatus { + if in == nil { + return nil + } + out := new(EventSubscriptionStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalCluster) DeepCopyInto(out *GlobalCluster) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalCluster. +func (in *GlobalCluster) DeepCopy() *GlobalCluster { + if in == nil { + return nil + } + out := new(GlobalCluster) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *GlobalCluster) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterInitParameters) DeepCopyInto(out *GlobalClusterInitParameters) { + *out = *in + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName + *out = new(string) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.ForceDestroy != nil { + in, out := &in.ForceDestroy, &out.ForceDestroy + *out = new(bool) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterInitParameters. +func (in *GlobalClusterInitParameters) DeepCopy() *GlobalClusterInitParameters { + if in == nil { + return nil + } + out := new(GlobalClusterInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterList) DeepCopyInto(out *GlobalClusterList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]GlobalCluster, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterList. +func (in *GlobalClusterList) DeepCopy() *GlobalClusterList { + if in == nil { + return nil + } + out := new(GlobalClusterList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *GlobalClusterList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterMembersInitParameters) DeepCopyInto(out *GlobalClusterMembersInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersInitParameters. +func (in *GlobalClusterMembersInitParameters) DeepCopy() *GlobalClusterMembersInitParameters { + if in == nil { + return nil + } + out := new(GlobalClusterMembersInitParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterMembersObservation) DeepCopyInto(out *GlobalClusterMembersObservation) { + *out = *in + if in.DBClusterArn != nil { + in, out := &in.DBClusterArn, &out.DBClusterArn + *out = new(string) + **out = **in + } + if in.IsWriter != nil { + in, out := &in.IsWriter, &out.IsWriter + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersObservation. +func (in *GlobalClusterMembersObservation) DeepCopy() *GlobalClusterMembersObservation { + if in == nil { + return nil + } + out := new(GlobalClusterMembersObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterMembersParameters) DeepCopyInto(out *GlobalClusterMembersParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterMembersParameters. +func (in *GlobalClusterMembersParameters) DeepCopy() *GlobalClusterMembersParameters { + if in == nil { + return nil + } + out := new(GlobalClusterMembersParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterObservation) DeepCopyInto(out *GlobalClusterObservation) { + *out = *in + if in.Arn != nil { + in, out := &in.Arn, &out.Arn + *out = new(string) + **out = **in + } + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName + *out = new(string) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.EngineVersionActual != nil { + in, out := &in.EngineVersionActual, &out.EngineVersionActual + *out = new(string) + **out = **in + } + if in.ForceDestroy != nil { + in, out := &in.ForceDestroy, &out.ForceDestroy + *out = new(bool) + **out = **in + } + if in.GlobalClusterMembers != nil { + in, out := &in.GlobalClusterMembers, &out.GlobalClusterMembers + *out = make([]GlobalClusterMembersObservation, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.GlobalClusterResourceID != nil { + in, out := &in.GlobalClusterResourceID, &out.GlobalClusterResourceID + *out = new(string) + **out = **in + } + if in.ID != nil { + in, out := &in.ID, &out.ID + *out = new(string) + **out = **in + } + if in.SourceDBClusterIdentifier != nil { + in, out := &in.SourceDBClusterIdentifier, &out.SourceDBClusterIdentifier + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterObservation. +func (in *GlobalClusterObservation) DeepCopy() *GlobalClusterObservation { + if in == nil { + return nil + } + out := new(GlobalClusterObservation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterParameters) DeepCopyInto(out *GlobalClusterParameters) { + *out = *in + if in.DatabaseName != nil { + in, out := &in.DatabaseName, &out.DatabaseName + *out = new(string) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.Engine != nil { + in, out := &in.Engine, &out.Engine + *out = new(string) + **out = **in + } + if in.EngineVersion != nil { + in, out := &in.EngineVersion, &out.EngineVersion + *out = new(string) + **out = **in + } + if in.ForceDestroy != nil { + in, out := &in.ForceDestroy, &out.ForceDestroy + *out = new(bool) + **out = **in + } + if in.Region != nil { + in, out := &in.Region, &out.Region + *out = new(string) + **out = **in + } + if in.SourceDBClusterIdentifier != nil { + in, out := &in.SourceDBClusterIdentifier, &out.SourceDBClusterIdentifier + *out = new(string) + **out = **in + } + if in.SourceDBClusterIdentifierRef != nil { + in, out := &in.SourceDBClusterIdentifierRef, &out.SourceDBClusterIdentifierRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.SourceDBClusterIdentifierSelector != nil { + in, out := &in.SourceDBClusterIdentifierSelector, &out.SourceDBClusterIdentifierSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterParameters. +func (in *GlobalClusterParameters) DeepCopy() *GlobalClusterParameters { + if in == nil { + return nil + } + out := new(GlobalClusterParameters) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterSpec) DeepCopyInto(out *GlobalClusterSpec) { + *out = *in + in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) + in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterSpec. +func (in *GlobalClusterSpec) DeepCopy() *GlobalClusterSpec { + if in == nil { + return nil + } + out := new(GlobalClusterSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *GlobalClusterStatus) DeepCopyInto(out *GlobalClusterStatus) { + *out = *in + in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) + in.AtProvider.DeepCopyInto(&out.AtProvider) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterStatus. +func (in *GlobalClusterStatus) DeepCopy() *GlobalClusterStatus { + if in == nil { + return nil + } + out := new(GlobalClusterStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *Instance) DeepCopyInto(out *Instance) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Instance. +func (in *Instance) DeepCopy() *Instance { + if in == nil { + return nil + } + out := new(Instance) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *Instance) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *InstanceInitParameters) DeepCopyInto(out *InstanceInitParameters) { + *out = *in + if in.AllocatedStorage != nil { + in, out := &in.AllocatedStorage, &out.AllocatedStorage + *out = new(float64) + **out = **in + } + if in.AllowMajorVersionUpgrade != nil { + in, out := &in.AllowMajorVersionUpgrade, &out.AllowMajorVersionUpgrade + *out = new(bool) + **out = **in + } + if in.ApplyImmediately != nil { + in, out := &in.ApplyImmediately, &out.ApplyImmediately + *out = new(bool) + **out = **in + } + if in.AutoMinorVersionUpgrade != nil { + in, out := &in.AutoMinorVersionUpgrade, &out.AutoMinorVersionUpgrade + *out = new(bool) + **out = **in + } + if in.AvailabilityZone != nil { + in, out := &in.AvailabilityZone, &out.AvailabilityZone + *out = new(string) + **out = **in + } + if in.BackupRetentionPeriod != nil { + in, out := &in.BackupRetentionPeriod, &out.BackupRetentionPeriod + *out = new(float64) + **out = **in + } + if in.BackupWindow != nil { + in, out := &in.BackupWindow, &out.BackupWindow + *out = new(string) + **out = **in + } + if in.BlueGreenUpdate != nil { + in, out := &in.BlueGreenUpdate, &out.BlueGreenUpdate + *out = make([]BlueGreenUpdateInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.CACertIdentifier != nil { + in, out := &in.CACertIdentifier, &out.CACertIdentifier + *out = new(string) + **out = **in + } + if in.CharacterSetName != nil { + in, out := &in.CharacterSetName, &out.CharacterSetName + *out = new(string) + **out = **in + } + if in.CopyTagsToSnapshot != nil { + in, out := &in.CopyTagsToSnapshot, &out.CopyTagsToSnapshot + *out = new(bool) + **out = **in + } + if in.CustomIAMInstanceProfile != nil { + in, out := &in.CustomIAMInstanceProfile, &out.CustomIAMInstanceProfile + *out = new(string) + **out = **in + } + if in.CustomerOwnedIPEnabled != nil { + in, out := &in.CustomerOwnedIPEnabled, &out.CustomerOwnedIPEnabled + *out = new(bool) + **out = **in + } + if in.DBName != nil { + in, out := &in.DBName, &out.DBName + *out = new(string) + **out = **in + } + if in.DeleteAutomatedBackups != nil { + in, out := &in.DeleteAutomatedBackups, &out.DeleteAutomatedBackups + *out = new(bool) + **out = **in + } + if in.DeletionProtection != nil { + in, out := &in.DeletionProtection, &out.DeletionProtection + *out = new(bool) + **out = **in + } + if in.Domain != nil { + in, out := &in.Domain, &out.Domain + *out = new(string) + **out = **in + } + if in.DomainIAMRoleName != nil { + in, out := &in.DomainIAMRoleName, &out.DomainIAMRoleName + *out = new(string) + **out = **in + } + if in.EnabledCloudwatchLogsExports != nil { + in, out := &in.EnabledCloudwatchLogsExports, &out.EnabledCloudwatchLogsExports + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } } if in.Engine != nil { in, out := &in.Engine, &out.Engine @@ -3952,109 +5321,204 @@ func (in *GlobalClusterParameters) DeepCopyInto(out *GlobalClusterParameters) { *out = new(string) **out = **in } - if in.ForceDestroy != nil { - in, out := &in.ForceDestroy, &out.ForceDestroy + if in.FinalSnapshotIdentifier != nil { + in, out := &in.FinalSnapshotIdentifier, &out.FinalSnapshotIdentifier + *out = new(string) + **out = **in + } + if in.IAMDatabaseAuthenticationEnabled != nil { + in, out := &in.IAMDatabaseAuthenticationEnabled, &out.IAMDatabaseAuthenticationEnabled + *out = new(bool) + **out = **in + } + if in.InstanceClass != nil { + in, out := &in.InstanceClass, &out.InstanceClass + *out = new(string) + **out = **in + } + if in.Iops != nil { + in, out := &in.Iops, &out.Iops + *out = new(float64) + **out = **in + } + if in.LicenseModel != nil { + in, out := &in.LicenseModel, &out.LicenseModel + *out = new(string) + **out = **in + } + if in.MaintenanceWindow != nil { + in, out := &in.MaintenanceWindow, &out.MaintenanceWindow + *out = new(string) + **out = **in + } + if in.ManageMasterUserPassword != nil { + in, out := &in.ManageMasterUserPassword, &out.ManageMasterUserPassword + *out = new(bool) + **out = **in + } + if in.MaxAllocatedStorage != nil { + in, out := &in.MaxAllocatedStorage, &out.MaxAllocatedStorage + *out = new(float64) + **out = **in + } + if in.MonitoringInterval != nil { + in, out := &in.MonitoringInterval, &out.MonitoringInterval + *out = new(float64) + **out = **in + } + if in.MonitoringRoleArn != nil { + in, out := &in.MonitoringRoleArn, &out.MonitoringRoleArn + *out = new(string) + **out = **in + } + if in.MultiAz != nil { + in, out := &in.MultiAz, &out.MultiAz + *out = new(bool) + **out = **in + } + if in.NcharCharacterSetName != nil { + in, out := &in.NcharCharacterSetName, &out.NcharCharacterSetName + *out = new(string) + **out = **in + } + if in.NetworkType != nil { + in, out := &in.NetworkType, &out.NetworkType + *out = new(string) + **out = **in + } + if in.OptionGroupName != nil { + in, out := &in.OptionGroupName, &out.OptionGroupName + *out = new(string) + **out = **in + } + if in.ParameterGroupName != nil { + in, out := &in.ParameterGroupName, &out.ParameterGroupName + *out = new(string) + **out = **in + } + if in.PerformanceInsightsEnabled != nil { + in, out := &in.PerformanceInsightsEnabled, &out.PerformanceInsightsEnabled + *out = new(bool) + **out = **in + } + if in.PerformanceInsightsKMSKeyID != nil { + in, out := &in.PerformanceInsightsKMSKeyID, &out.PerformanceInsightsKMSKeyID + *out = new(string) + **out = **in + } + if in.PerformanceInsightsRetentionPeriod != nil { + in, out := &in.PerformanceInsightsRetentionPeriod, &out.PerformanceInsightsRetentionPeriod + *out = new(float64) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.PubliclyAccessible != nil { + in, out := &in.PubliclyAccessible, &out.PubliclyAccessible + *out = new(bool) + **out = **in + } + if in.ReplicaMode != nil { + in, out := &in.ReplicaMode, &out.ReplicaMode + *out = new(string) + **out = **in + } + if in.RestoreToPointInTime != nil { + in, out := &in.RestoreToPointInTime, &out.RestoreToPointInTime + *out = make([]RestoreToPointInTimeInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.S3Import != nil { + in, out := &in.S3Import, &out.S3Import + *out = make([]S3ImportInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.SkipFinalSnapshot != nil { + in, out := &in.SkipFinalSnapshot, &out.SkipFinalSnapshot + *out = new(bool) + **out = **in + } + if in.SnapshotIdentifier != nil { + in, out := &in.SnapshotIdentifier, &out.SnapshotIdentifier + *out = new(string) + **out = **in + } + if in.StorageEncrypted != nil { + in, out := &in.StorageEncrypted, &out.StorageEncrypted *out = new(bool) **out = **in } - if in.Region != nil { - in, out := &in.Region, &out.Region + if in.StorageThroughput != nil { + in, out := &in.StorageThroughput, &out.StorageThroughput + *out = new(float64) + **out = **in + } + if in.StorageType != nil { + in, out := &in.StorageType, &out.StorageType + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.Timezone != nil { + in, out := &in.Timezone, &out.Timezone *out = new(string) **out = **in } - if in.SourceDBClusterIdentifier != nil { - in, out := &in.SourceDBClusterIdentifier, &out.SourceDBClusterIdentifier + if in.Username != nil { + in, out := &in.Username, &out.Username *out = new(string) **out = **in } - if in.SourceDBClusterIdentifierRef != nil { - in, out := &in.SourceDBClusterIdentifierRef, &out.SourceDBClusterIdentifierRef - *out = new(v1.Reference) - (*in).DeepCopyInto(*out) - } - if in.SourceDBClusterIdentifierSelector != nil { - in, out := &in.SourceDBClusterIdentifierSelector, &out.SourceDBClusterIdentifierSelector - *out = new(v1.Selector) - (*in).DeepCopyInto(*out) - } - if in.StorageEncrypted != nil { - in, out := &in.StorageEncrypted, &out.StorageEncrypted - *out = new(bool) - **out = **in - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterParameters. -func (in *GlobalClusterParameters) DeepCopy() *GlobalClusterParameters { - if in == nil { - return nil - } - out := new(GlobalClusterParameters) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterSpec) DeepCopyInto(out *GlobalClusterSpec) { - *out = *in - in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) - in.ForProvider.DeepCopyInto(&out.ForProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterSpec. -func (in *GlobalClusterSpec) DeepCopy() *GlobalClusterSpec { - if in == nil { - return nil - } - out := new(GlobalClusterSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GlobalClusterStatus) DeepCopyInto(out *GlobalClusterStatus) { - *out = *in - in.ResourceStatus.DeepCopyInto(&out.ResourceStatus) - in.AtProvider.DeepCopyInto(&out.AtProvider) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalClusterStatus. -func (in *GlobalClusterStatus) DeepCopy() *GlobalClusterStatus { - if in == nil { - return nil - } - out := new(GlobalClusterStatus) - in.DeepCopyInto(out) - return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *Instance) DeepCopyInto(out *Instance) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Instance. -func (in *Instance) DeepCopy() *Instance { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceInitParameters. +func (in *InstanceInitParameters) DeepCopy() *InstanceInitParameters { if in == nil { return nil } - out := new(Instance) + out := new(InstanceInitParameters) in.DeepCopyInto(out) return out } -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *Instance) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *InstanceList) DeepCopyInto(out *InstanceList) { *out = *in @@ -4445,7 +5909,8 @@ func (in *InstanceObservation) DeepCopyInto(out *InstanceObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -4460,7 +5925,8 @@ func (in *InstanceObservation) DeepCopyInto(out *InstanceObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -4843,7 +6309,8 @@ func (in *InstanceParameters) DeepCopyInto(out *InstanceParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -4858,7 +6325,8 @@ func (in *InstanceParameters) DeepCopyInto(out *InstanceParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -4937,6 +6405,31 @@ func (in *InstanceRoleAssociation) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *InstanceRoleAssociationInitParameters) DeepCopyInto(out *InstanceRoleAssociationInitParameters) { + *out = *in + if in.FeatureName != nil { + in, out := &in.FeatureName, &out.FeatureName + *out = new(string) + **out = **in + } + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceRoleAssociationInitParameters. +func (in *InstanceRoleAssociationInitParameters) DeepCopy() *InstanceRoleAssociationInitParameters { + if in == nil { + return nil + } + out := new(InstanceRoleAssociationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *InstanceRoleAssociationList) DeepCopyInto(out *InstanceRoleAssociationList) { *out = *in @@ -5054,6 +6547,7 @@ func (in *InstanceRoleAssociationSpec) DeepCopyInto(out *InstanceRoleAssociation *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceRoleAssociationSpec. @@ -5088,6 +6582,7 @@ func (in *InstanceSpec) DeepCopyInto(out *InstanceSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceSpec. @@ -5117,6 +6612,21 @@ func (in *InstanceStatus) DeepCopy() *InstanceStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ListenerEndpointInitParameters) DeepCopyInto(out *ListenerEndpointInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ListenerEndpointInitParameters. +func (in *ListenerEndpointInitParameters) DeepCopy() *ListenerEndpointInitParameters { + if in == nil { + return nil + } + out := new(ListenerEndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ListenerEndpointObservation) DeepCopyInto(out *ListenerEndpointObservation) { *out = *in @@ -5162,6 +6672,21 @@ func (in *ListenerEndpointParameters) DeepCopy() *ListenerEndpointParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MasterUserSecretInitParameters) DeepCopyInto(out *MasterUserSecretInitParameters) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MasterUserSecretInitParameters. +func (in *MasterUserSecretInitParameters) DeepCopy() *MasterUserSecretInitParameters { + if in == nil { + return nil + } + out := new(MasterUserSecretInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MasterUserSecretObservation) DeepCopyInto(out *MasterUserSecretObservation) { *out = *in @@ -5234,6 +6759,75 @@ func (in *OptionGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *OptionGroupInitParameters) DeepCopyInto(out *OptionGroupInitParameters) { + *out = *in + if in.EngineName != nil { + in, out := &in.EngineName, &out.EngineName + *out = new(string) + **out = **in + } + if in.MajorEngineVersion != nil { + in, out := &in.MajorEngineVersion, &out.MajorEngineVersion + *out = new(string) + **out = **in + } + if in.Option != nil { + in, out := &in.Option, &out.Option + *out = make([]OptionInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.OptionGroupDescription != nil { + in, out := &in.OptionGroupDescription, &out.OptionGroupDescription + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionGroupInitParameters. +func (in *OptionGroupInitParameters) DeepCopy() *OptionGroupInitParameters { + if in == nil { + return nil + } + out := new(OptionGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *OptionGroupList) DeepCopyInto(out *OptionGroupList) { *out = *in @@ -5309,7 +6903,8 @@ func (in *OptionGroupObservation) DeepCopyInto(out *OptionGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5324,7 +6919,8 @@ func (in *OptionGroupObservation) DeepCopyInto(out *OptionGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5381,7 +6977,8 @@ func (in *OptionGroupParameters) DeepCopyInto(out *OptionGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5396,7 +6993,8 @@ func (in *OptionGroupParameters) DeepCopyInto(out *OptionGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5420,6 +7018,7 @@ func (in *OptionGroupSpec) DeepCopyInto(out *OptionGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionGroupSpec. @@ -5439,12 +7038,71 @@ func (in *OptionGroupStatus) DeepCopyInto(out *OptionGroupStatus) { in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionGroupStatus. -func (in *OptionGroupStatus) DeepCopy() *OptionGroupStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionGroupStatus. +func (in *OptionGroupStatus) DeepCopy() *OptionGroupStatus { + if in == nil { + return nil + } + out := new(OptionGroupStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *OptionInitParameters) DeepCopyInto(out *OptionInitParameters) { + *out = *in + if in.DBSecurityGroupMemberships != nil { + in, out := &in.DBSecurityGroupMemberships, &out.DBSecurityGroupMemberships + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.OptionName != nil { + in, out := &in.OptionName, &out.OptionName + *out = new(string) + **out = **in + } + if in.OptionSettings != nil { + in, out := &in.OptionSettings, &out.OptionSettings + *out = make([]OptionSettingsInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(float64) + **out = **in + } + if in.VPCSecurityGroupMemberships != nil { + in, out := &in.VPCSecurityGroupMemberships, &out.VPCSecurityGroupMemberships + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Version != nil { + in, out := &in.Version, &out.Version + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionInitParameters. +func (in *OptionInitParameters) DeepCopy() *OptionInitParameters { if in == nil { return nil } - out := new(OptionGroupStatus) + out := new(OptionInitParameters) in.DeepCopyInto(out) return out } @@ -5567,6 +7225,31 @@ func (in *OptionParameters) DeepCopy() *OptionParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *OptionSettingsInitParameters) DeepCopyInto(out *OptionSettingsInitParameters) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OptionSettingsInitParameters. +func (in *OptionSettingsInitParameters) DeepCopy() *OptionSettingsInitParameters { + if in == nil { + return nil + } + out := new(OptionSettingsInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *OptionSettingsObservation) DeepCopyInto(out *OptionSettingsObservation) { *out = *in @@ -5644,6 +7327,70 @@ func (in *ParameterGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterGroupInitParameters) DeepCopyInto(out *ParameterGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Family != nil { + in, out := &in.Family, &out.Family + *out = new(string) + **out = **in + } + if in.Parameter != nil { + in, out := &in.Parameter, &out.Parameter + *out = make([]ParameterInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupInitParameters. +func (in *ParameterGroupInitParameters) DeepCopy() *ParameterGroupInitParameters { + if in == nil { + return nil + } + out := new(ParameterGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterGroupList) DeepCopyInto(out *ParameterGroupList) { *out = *in @@ -5714,7 +7461,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5729,7 +7477,8 @@ func (in *ParameterGroupObservation) DeepCopyInto(out *ParameterGroupObservation if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5781,7 +7530,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5796,7 +7546,8 @@ func (in *ParameterGroupParameters) DeepCopyInto(out *ParameterGroupParameters) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -5820,6 +7571,7 @@ func (in *ParameterGroupSpec) DeepCopyInto(out *ParameterGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterGroupSpec. @@ -5849,6 +7601,36 @@ func (in *ParameterGroupStatus) DeepCopy() *ParameterGroupStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ParameterInitParameters) DeepCopyInto(out *ParameterInitParameters) { + *out = *in + if in.ApplyMethod != nil { + in, out := &in.ApplyMethod, &out.ApplyMethod + *out = new(string) + **out = **in + } + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Value != nil { + in, out := &in.Value, &out.Value + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParameterInitParameters. +func (in *ParameterInitParameters) DeepCopy() *ParameterInitParameters { + if in == nil { + return nil + } + out := new(ParameterInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ParameterObservation) DeepCopyInto(out *ParameterObservation) { *out = *in @@ -5963,6 +7745,28 @@ func (in *ProxyDefaultTargetGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ProxyDefaultTargetGroupInitParameters) DeepCopyInto(out *ProxyDefaultTargetGroupInitParameters) { + *out = *in + if in.ConnectionPoolConfig != nil { + in, out := &in.ConnectionPoolConfig, &out.ConnectionPoolConfig + *out = make([]ConnectionPoolConfigInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyDefaultTargetGroupInitParameters. +func (in *ProxyDefaultTargetGroupInitParameters) DeepCopy() *ProxyDefaultTargetGroupInitParameters { + if in == nil { + return nil + } + out := new(ProxyDefaultTargetGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ProxyDefaultTargetGroupList) DeepCopyInto(out *ProxyDefaultTargetGroupList) { *out = *in @@ -6084,6 +7888,7 @@ func (in *ProxyDefaultTargetGroupSpec) DeepCopyInto(out *ProxyDefaultTargetGroup *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyDefaultTargetGroupSpec. @@ -6140,6 +7945,69 @@ func (in *ProxyEndpoint) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ProxyEndpointInitParameters) DeepCopyInto(out *ProxyEndpointInitParameters) { + *out = *in + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TargetRole != nil { + in, out := &in.TargetRole, &out.TargetRole + *out = new(string) + **out = **in + } + if in.VPCSubnetIds != nil { + in, out := &in.VPCSubnetIds, &out.VPCSubnetIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyEndpointInitParameters. +func (in *ProxyEndpointInitParameters) DeepCopy() *ProxyEndpointInitParameters { + if in == nil { + return nil + } + out := new(ProxyEndpointInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ProxyEndpointList) DeepCopyInto(out *ProxyEndpointList) { *out = *in @@ -6208,7 +8076,8 @@ func (in *ProxyEndpointObservation) DeepCopyInto(out *ProxyEndpointObservation) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6223,7 +8092,8 @@ func (in *ProxyEndpointObservation) DeepCopyInto(out *ProxyEndpointObservation) if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6305,7 +8175,8 @@ func (in *ProxyEndpointParameters) DeepCopyInto(out *ProxyEndpointParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6320,7 +8191,8 @@ func (in *ProxyEndpointParameters) DeepCopyInto(out *ProxyEndpointParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6383,6 +8255,7 @@ func (in *ProxyEndpointSpec) DeepCopyInto(out *ProxyEndpointSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyEndpointSpec. @@ -6402,12 +8275,102 @@ func (in *ProxyEndpointStatus) DeepCopyInto(out *ProxyEndpointStatus) { in.AtProvider.DeepCopyInto(&out.AtProvider) } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyEndpointStatus. -func (in *ProxyEndpointStatus) DeepCopy() *ProxyEndpointStatus { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyEndpointStatus. +func (in *ProxyEndpointStatus) DeepCopy() *ProxyEndpointStatus { + if in == nil { + return nil + } + out := new(ProxyEndpointStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ProxyInitParameters) DeepCopyInto(out *ProxyInitParameters) { + *out = *in + if in.Auth != nil { + in, out := &in.Auth, &out.Auth + *out = make([]AuthInitParameters, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + if in.DebugLogging != nil { + in, out := &in.DebugLogging, &out.DebugLogging + *out = new(bool) + **out = **in + } + if in.EngineFamily != nil { + in, out := &in.EngineFamily, &out.EngineFamily + *out = new(string) + **out = **in + } + if in.IdleClientTimeout != nil { + in, out := &in.IdleClientTimeout, &out.IdleClientTimeout + *out = new(float64) + **out = **in + } + if in.RequireTLS != nil { + in, out := &in.RequireTLS, &out.RequireTLS + *out = new(bool) + **out = **in + } + if in.RoleArn != nil { + in, out := &in.RoleArn, &out.RoleArn + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.VPCSubnetIds != nil { + in, out := &in.VPCSubnetIds, &out.VPCSubnetIds + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyInitParameters. +func (in *ProxyInitParameters) DeepCopy() *ProxyInitParameters { if in == nil { return nil } - out := new(ProxyEndpointStatus) + out := new(ProxyInitParameters) in.DeepCopyInto(out) return out } @@ -6502,7 +8465,8 @@ func (in *ProxyObservation) DeepCopyInto(out *ProxyObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6517,7 +8481,8 @@ func (in *ProxyObservation) DeepCopyInto(out *ProxyObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6606,7 +8571,8 @@ func (in *ProxyParameters) DeepCopyInto(out *ProxyParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6621,7 +8587,8 @@ func (in *ProxyParameters) DeepCopyInto(out *ProxyParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -6679,6 +8646,7 @@ func (in *ProxySpec) DeepCopyInto(out *ProxySpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxySpec. @@ -6735,6 +8703,31 @@ func (in *ProxyTarget) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ProxyTargetInitParameters) DeepCopyInto(out *ProxyTargetInitParameters) { + *out = *in + if in.DBClusterIdentifier != nil { + in, out := &in.DBClusterIdentifier, &out.DBClusterIdentifier + *out = new(string) + **out = **in + } + if in.TargetGroupName != nil { + in, out := &in.TargetGroupName, &out.TargetGroupName + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyTargetInitParameters. +func (in *ProxyTargetInitParameters) DeepCopy() *ProxyTargetInitParameters { + if in == nil { + return nil + } + out := new(ProxyTargetInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ProxyTargetList) DeepCopyInto(out *ProxyTargetList) { *out = *in @@ -6902,6 +8895,7 @@ func (in *ProxyTargetSpec) DeepCopyInto(out *ProxyTargetSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProxyTargetSpec. @@ -6931,6 +8925,46 @@ func (in *ProxyTargetStatus) DeepCopy() *ProxyTargetStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestoreToPointInTimeInitParameters) DeepCopyInto(out *RestoreToPointInTimeInitParameters) { + *out = *in + if in.RestoreTime != nil { + in, out := &in.RestoreTime, &out.RestoreTime + *out = new(string) + **out = **in + } + if in.SourceDBInstanceAutomatedBackupsArn != nil { + in, out := &in.SourceDBInstanceAutomatedBackupsArn, &out.SourceDBInstanceAutomatedBackupsArn + *out = new(string) + **out = **in + } + if in.SourceDBInstanceIdentifier != nil { + in, out := &in.SourceDBInstanceIdentifier, &out.SourceDBInstanceIdentifier + *out = new(string) + **out = **in + } + if in.SourceDbiResourceID != nil { + in, out := &in.SourceDbiResourceID, &out.SourceDbiResourceID + *out = new(string) + **out = **in + } + if in.UseLatestRestorableTime != nil { + in, out := &in.UseLatestRestorableTime, &out.UseLatestRestorableTime + *out = new(bool) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestoreToPointInTimeInitParameters. +func (in *RestoreToPointInTimeInitParameters) DeepCopy() *RestoreToPointInTimeInitParameters { + if in == nil { + return nil + } + out := new(RestoreToPointInTimeInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RestoreToPointInTimeObservation) DeepCopyInto(out *RestoreToPointInTimeObservation) { *out = *in @@ -7011,6 +9045,46 @@ func (in *RestoreToPointInTimeParameters) DeepCopy() *RestoreToPointInTimeParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *S3ImportInitParameters) DeepCopyInto(out *S3ImportInitParameters) { + *out = *in + if in.BucketName != nil { + in, out := &in.BucketName, &out.BucketName + *out = new(string) + **out = **in + } + if in.BucketPrefix != nil { + in, out := &in.BucketPrefix, &out.BucketPrefix + *out = new(string) + **out = **in + } + if in.IngestionRole != nil { + in, out := &in.IngestionRole, &out.IngestionRole + *out = new(string) + **out = **in + } + if in.SourceEngine != nil { + in, out := &in.SourceEngine, &out.SourceEngine + *out = new(string) + **out = **in + } + if in.SourceEngineVersion != nil { + in, out := &in.SourceEngineVersion, &out.SourceEngineVersion + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new S3ImportInitParameters. +func (in *S3ImportInitParameters) DeepCopy() *S3ImportInitParameters { + if in == nil { + return nil + } + out := new(S3ImportInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *S3ImportObservation) DeepCopyInto(out *S3ImportObservation) { *out = *in @@ -7091,6 +9165,46 @@ func (in *S3ImportParameters) DeepCopy() *S3ImportParameters { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ScalingConfigurationInitParameters) DeepCopyInto(out *ScalingConfigurationInitParameters) { + *out = *in + if in.AutoPause != nil { + in, out := &in.AutoPause, &out.AutoPause + *out = new(bool) + **out = **in + } + if in.MaxCapacity != nil { + in, out := &in.MaxCapacity, &out.MaxCapacity + *out = new(float64) + **out = **in + } + if in.MinCapacity != nil { + in, out := &in.MinCapacity, &out.MinCapacity + *out = new(float64) + **out = **in + } + if in.SecondsUntilAutoPause != nil { + in, out := &in.SecondsUntilAutoPause, &out.SecondsUntilAutoPause + *out = new(float64) + **out = **in + } + if in.TimeoutAction != nil { + in, out := &in.TimeoutAction, &out.TimeoutAction + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScalingConfigurationInitParameters. +func (in *ScalingConfigurationInitParameters) DeepCopy() *ScalingConfigurationInitParameters { + if in == nil { + return nil + } + out := new(ScalingConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ScalingConfigurationObservation) DeepCopyInto(out *ScalingConfigurationObservation) { *out = *in @@ -7171,6 +9285,31 @@ func (in *ScalingConfigurationParameters) DeepCopy() *ScalingConfigurationParame return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *Serverlessv2ScalingConfigurationInitParameters) DeepCopyInto(out *Serverlessv2ScalingConfigurationInitParameters) { + *out = *in + if in.MaxCapacity != nil { + in, out := &in.MaxCapacity, &out.MaxCapacity + *out = new(float64) + **out = **in + } + if in.MinCapacity != nil { + in, out := &in.MinCapacity, &out.MinCapacity + *out = new(float64) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Serverlessv2ScalingConfigurationInitParameters. +func (in *Serverlessv2ScalingConfigurationInitParameters) DeepCopy() *Serverlessv2ScalingConfigurationInitParameters { + if in == nil { + return nil + } + out := new(Serverlessv2ScalingConfigurationInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Serverlessv2ScalingConfigurationObservation) DeepCopyInto(out *Serverlessv2ScalingConfigurationObservation) { *out = *in @@ -7248,6 +9387,64 @@ func (in *Snapshot) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SnapshotInitParameters) DeepCopyInto(out *SnapshotInitParameters) { + *out = *in + if in.SharedAccounts != nil { + in, out := &in.SharedAccounts, &out.SharedAccounts + *out = make([]*string, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(string) + **out = **in + } + } + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotInitParameters. +func (in *SnapshotInitParameters) DeepCopy() *SnapshotInitParameters { + if in == nil { + return nil + } + out := new(SnapshotInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SnapshotList) DeepCopyInto(out *SnapshotList) { *out = *in @@ -7392,7 +9589,8 @@ func (in *SnapshotObservation) DeepCopyInto(out *SnapshotObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7407,7 +9605,8 @@ func (in *SnapshotObservation) DeepCopyInto(out *SnapshotObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7473,7 +9672,8 @@ func (in *SnapshotParameters) DeepCopyInto(out *SnapshotParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7488,7 +9688,8 @@ func (in *SnapshotParameters) DeepCopyInto(out *SnapshotParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7512,6 +9713,7 @@ func (in *SnapshotSpec) DeepCopyInto(out *SnapshotSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotSpec. @@ -7568,6 +9770,58 @@ func (in *SubnetGroup) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SubnetGroupInitParameters) DeepCopyInto(out *SubnetGroupInitParameters) { + *out = *in + if in.Description != nil { + in, out := &in.Description, &out.Description + *out = new(string) + **out = **in + } + if in.Tags != nil { + in, out := &in.Tags, &out.Tags + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } + if in.TagsAll != nil { + in, out := &in.TagsAll, &out.TagsAll + *out = make(map[string]*string, len(*in)) + for key, val := range *in { + var outVal *string + if val == nil { + (*out)[key] = nil + } else { + inVal := (*in)[key] + in, out := &inVal, &outVal + *out = new(string) + **out = **in + } + (*out)[key] = outVal + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupInitParameters. +func (in *SubnetGroupInitParameters) DeepCopy() *SubnetGroupInitParameters { + if in == nil { + return nil + } + out := new(SubnetGroupInitParameters) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SubnetGroupList) DeepCopyInto(out *SubnetGroupList) { *out = *in @@ -7648,7 +9902,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7663,7 +9918,8 @@ func (in *SubnetGroupObservation) DeepCopyInto(out *SubnetGroupObservation) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7731,7 +9987,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7746,7 +10003,8 @@ func (in *SubnetGroupParameters) DeepCopyInto(out *SubnetGroupParameters) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = new(string) **out = **in } @@ -7770,6 +10028,7 @@ func (in *SubnetGroupSpec) DeepCopyInto(out *SubnetGroupSpec) { *out = *in in.ResourceSpec.DeepCopyInto(&out.ResourceSpec) in.ForProvider.DeepCopyInto(&out.ForProvider) + in.InitProvider.DeepCopyInto(&out.InitProvider) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SubnetGroupSpec. diff --git a/apis/rds/v1alpha1/zz_generated.managed.go b/apis/rds/v1alpha1/zz_generated.managed.go index b2e32b8..ac020ce 100644 --- a/apis/rds/v1alpha1/zz_generated.managed.go +++ b/apis/rds/v1alpha1/zz_generated.managed.go @@ -17,9 +17,9 @@ func (mg *Cluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Cluster. -func (mg *Cluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Cluster. +func (mg *Cluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Cluster. @@ -27,14 +27,6 @@ func (mg *Cluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Cluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Cluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -55,9 +47,9 @@ func (mg *Cluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Cluster. -func (mg *Cluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Cluster. +func (mg *Cluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Cluster. @@ -65,14 +57,6 @@ func (mg *Cluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Cluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Cluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Cluster. func (mg *Cluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -93,9 +77,9 @@ func (mg *ClusterActivityStream) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterActivityStream. -func (mg *ClusterActivityStream) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterActivityStream. +func (mg *ClusterActivityStream) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterActivityStream. @@ -103,14 +87,6 @@ func (mg *ClusterActivityStream) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterActivityStream. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterActivityStream) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterActivityStream. func (mg *ClusterActivityStream) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -131,9 +107,9 @@ func (mg *ClusterActivityStream) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterActivityStream. -func (mg *ClusterActivityStream) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterActivityStream. +func (mg *ClusterActivityStream) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterActivityStream. @@ -141,14 +117,6 @@ func (mg *ClusterActivityStream) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterActivityStream. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterActivityStream) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterActivityStream. func (mg *ClusterActivityStream) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -169,9 +137,9 @@ func (mg *ClusterEndpoint) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterEndpoint. -func (mg *ClusterEndpoint) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterEndpoint. +func (mg *ClusterEndpoint) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterEndpoint. @@ -179,14 +147,6 @@ func (mg *ClusterEndpoint) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterEndpoint. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterEndpoint) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterEndpoint. func (mg *ClusterEndpoint) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -207,9 +167,9 @@ func (mg *ClusterEndpoint) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterEndpoint. -func (mg *ClusterEndpoint) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterEndpoint. +func (mg *ClusterEndpoint) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterEndpoint. @@ -217,14 +177,6 @@ func (mg *ClusterEndpoint) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterEndpoint. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterEndpoint) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterEndpoint. func (mg *ClusterEndpoint) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -245,9 +197,9 @@ func (mg *ClusterInstance) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterInstance. -func (mg *ClusterInstance) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterInstance. +func (mg *ClusterInstance) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterInstance. @@ -255,14 +207,6 @@ func (mg *ClusterInstance) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterInstance. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterInstance) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterInstance. func (mg *ClusterInstance) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -283,9 +227,9 @@ func (mg *ClusterInstance) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterInstance. -func (mg *ClusterInstance) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterInstance. +func (mg *ClusterInstance) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterInstance. @@ -293,14 +237,6 @@ func (mg *ClusterInstance) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterInstance. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterInstance) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterInstance. func (mg *ClusterInstance) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -321,9 +257,9 @@ func (mg *ClusterParameterGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterParameterGroup. -func (mg *ClusterParameterGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterParameterGroup. +func (mg *ClusterParameterGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterParameterGroup. @@ -331,14 +267,6 @@ func (mg *ClusterParameterGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterParameterGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterParameterGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterParameterGroup. func (mg *ClusterParameterGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -359,9 +287,9 @@ func (mg *ClusterParameterGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterParameterGroup. -func (mg *ClusterParameterGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterParameterGroup. +func (mg *ClusterParameterGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterParameterGroup. @@ -369,14 +297,6 @@ func (mg *ClusterParameterGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterParameterGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterParameterGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterParameterGroup. func (mg *ClusterParameterGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -397,9 +317,9 @@ func (mg *ClusterRoleAssociation) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterRoleAssociation. -func (mg *ClusterRoleAssociation) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterRoleAssociation. +func (mg *ClusterRoleAssociation) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterRoleAssociation. @@ -407,14 +327,6 @@ func (mg *ClusterRoleAssociation) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterRoleAssociation. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterRoleAssociation) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterRoleAssociation. func (mg *ClusterRoleAssociation) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -435,9 +347,9 @@ func (mg *ClusterRoleAssociation) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterRoleAssociation. -func (mg *ClusterRoleAssociation) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterRoleAssociation. +func (mg *ClusterRoleAssociation) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterRoleAssociation. @@ -445,14 +357,6 @@ func (mg *ClusterRoleAssociation) SetProviderConfigReference(r *xpv1.Reference) mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterRoleAssociation. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterRoleAssociation) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterRoleAssociation. func (mg *ClusterRoleAssociation) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -473,9 +377,9 @@ func (mg *ClusterSnapshot) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ClusterSnapshot. -func (mg *ClusterSnapshot) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ClusterSnapshot. +func (mg *ClusterSnapshot) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ClusterSnapshot. @@ -483,14 +387,6 @@ func (mg *ClusterSnapshot) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ClusterSnapshot. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ClusterSnapshot) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ClusterSnapshot. func (mg *ClusterSnapshot) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -511,9 +407,9 @@ func (mg *ClusterSnapshot) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ClusterSnapshot. -func (mg *ClusterSnapshot) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ClusterSnapshot. +func (mg *ClusterSnapshot) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ClusterSnapshot. @@ -521,14 +417,6 @@ func (mg *ClusterSnapshot) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ClusterSnapshot. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ClusterSnapshot) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ClusterSnapshot. func (mg *ClusterSnapshot) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -549,9 +437,9 @@ func (mg *DBInstanceAutomatedBackupsReplication) GetDeletionPolicy() xpv1.Deleti return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this DBInstanceAutomatedBackupsReplication. -func (mg *DBInstanceAutomatedBackupsReplication) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this DBInstanceAutomatedBackupsReplication. +func (mg *DBInstanceAutomatedBackupsReplication) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this DBInstanceAutomatedBackupsReplication. @@ -559,14 +447,6 @@ func (mg *DBInstanceAutomatedBackupsReplication) GetProviderConfigReference() *x return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this DBInstanceAutomatedBackupsReplication. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *DBInstanceAutomatedBackupsReplication) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this DBInstanceAutomatedBackupsReplication. func (mg *DBInstanceAutomatedBackupsReplication) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -587,9 +467,9 @@ func (mg *DBInstanceAutomatedBackupsReplication) SetDeletionPolicy(r xpv1.Deleti mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this DBInstanceAutomatedBackupsReplication. -func (mg *DBInstanceAutomatedBackupsReplication) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this DBInstanceAutomatedBackupsReplication. +func (mg *DBInstanceAutomatedBackupsReplication) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this DBInstanceAutomatedBackupsReplication. @@ -597,14 +477,6 @@ func (mg *DBInstanceAutomatedBackupsReplication) SetProviderConfigReference(r *x mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this DBInstanceAutomatedBackupsReplication. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *DBInstanceAutomatedBackupsReplication) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this DBInstanceAutomatedBackupsReplication. func (mg *DBInstanceAutomatedBackupsReplication) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -625,9 +497,9 @@ func (mg *DBSnapshotCopy) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this DBSnapshotCopy. -func (mg *DBSnapshotCopy) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this DBSnapshotCopy. +func (mg *DBSnapshotCopy) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this DBSnapshotCopy. @@ -635,14 +507,6 @@ func (mg *DBSnapshotCopy) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this DBSnapshotCopy. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *DBSnapshotCopy) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this DBSnapshotCopy. func (mg *DBSnapshotCopy) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -663,9 +527,9 @@ func (mg *DBSnapshotCopy) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this DBSnapshotCopy. -func (mg *DBSnapshotCopy) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this DBSnapshotCopy. +func (mg *DBSnapshotCopy) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this DBSnapshotCopy. @@ -673,14 +537,6 @@ func (mg *DBSnapshotCopy) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this DBSnapshotCopy. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *DBSnapshotCopy) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this DBSnapshotCopy. func (mg *DBSnapshotCopy) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -701,9 +557,9 @@ func (mg *EventSubscription) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this EventSubscription. -func (mg *EventSubscription) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this EventSubscription. +func (mg *EventSubscription) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this EventSubscription. @@ -711,14 +567,6 @@ func (mg *EventSubscription) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this EventSubscription. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *EventSubscription) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this EventSubscription. func (mg *EventSubscription) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -739,9 +587,9 @@ func (mg *EventSubscription) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this EventSubscription. -func (mg *EventSubscription) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this EventSubscription. +func (mg *EventSubscription) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this EventSubscription. @@ -749,14 +597,6 @@ func (mg *EventSubscription) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this EventSubscription. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *EventSubscription) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this EventSubscription. func (mg *EventSubscription) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -777,9 +617,9 @@ func (mg *GlobalCluster) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this GlobalCluster. -func (mg *GlobalCluster) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this GlobalCluster. +func (mg *GlobalCluster) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this GlobalCluster. @@ -787,14 +627,6 @@ func (mg *GlobalCluster) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this GlobalCluster. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *GlobalCluster) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this GlobalCluster. func (mg *GlobalCluster) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -815,9 +647,9 @@ func (mg *GlobalCluster) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this GlobalCluster. -func (mg *GlobalCluster) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this GlobalCluster. +func (mg *GlobalCluster) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this GlobalCluster. @@ -825,14 +657,6 @@ func (mg *GlobalCluster) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this GlobalCluster. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *GlobalCluster) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this GlobalCluster. func (mg *GlobalCluster) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -853,9 +677,9 @@ func (mg *Instance) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Instance. -func (mg *Instance) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Instance. +func (mg *Instance) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Instance. @@ -863,14 +687,6 @@ func (mg *Instance) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Instance. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Instance) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Instance. func (mg *Instance) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -891,9 +707,9 @@ func (mg *Instance) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Instance. -func (mg *Instance) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Instance. +func (mg *Instance) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Instance. @@ -901,14 +717,6 @@ func (mg *Instance) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Instance. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Instance) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Instance. func (mg *Instance) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -929,9 +737,9 @@ func (mg *InstanceRoleAssociation) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this InstanceRoleAssociation. -func (mg *InstanceRoleAssociation) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this InstanceRoleAssociation. +func (mg *InstanceRoleAssociation) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this InstanceRoleAssociation. @@ -939,14 +747,6 @@ func (mg *InstanceRoleAssociation) GetProviderConfigReference() *xpv1.Reference return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this InstanceRoleAssociation. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *InstanceRoleAssociation) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this InstanceRoleAssociation. func (mg *InstanceRoleAssociation) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -967,9 +767,9 @@ func (mg *InstanceRoleAssociation) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this InstanceRoleAssociation. -func (mg *InstanceRoleAssociation) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this InstanceRoleAssociation. +func (mg *InstanceRoleAssociation) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this InstanceRoleAssociation. @@ -977,14 +777,6 @@ func (mg *InstanceRoleAssociation) SetProviderConfigReference(r *xpv1.Reference) mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this InstanceRoleAssociation. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *InstanceRoleAssociation) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this InstanceRoleAssociation. func (mg *InstanceRoleAssociation) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1005,9 +797,9 @@ func (mg *OptionGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this OptionGroup. -func (mg *OptionGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this OptionGroup. +func (mg *OptionGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this OptionGroup. @@ -1015,14 +807,6 @@ func (mg *OptionGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this OptionGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *OptionGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this OptionGroup. func (mg *OptionGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1043,9 +827,9 @@ func (mg *OptionGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this OptionGroup. -func (mg *OptionGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this OptionGroup. +func (mg *OptionGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this OptionGroup. @@ -1053,14 +837,6 @@ func (mg *OptionGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this OptionGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *OptionGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this OptionGroup. func (mg *OptionGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1081,9 +857,9 @@ func (mg *ParameterGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ParameterGroup. @@ -1091,14 +867,6 @@ func (mg *ParameterGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ParameterGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ParameterGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1119,9 +887,9 @@ func (mg *ParameterGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ParameterGroup. -func (mg *ParameterGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ParameterGroup. +func (mg *ParameterGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ParameterGroup. @@ -1129,14 +897,6 @@ func (mg *ParameterGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ParameterGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ParameterGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ParameterGroup. func (mg *ParameterGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1157,9 +917,9 @@ func (mg *Proxy) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Proxy. -func (mg *Proxy) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Proxy. +func (mg *Proxy) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Proxy. @@ -1167,14 +927,6 @@ func (mg *Proxy) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Proxy. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Proxy) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Proxy. func (mg *Proxy) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1195,9 +947,9 @@ func (mg *Proxy) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Proxy. -func (mg *Proxy) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Proxy. +func (mg *Proxy) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Proxy. @@ -1205,14 +957,6 @@ func (mg *Proxy) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Proxy. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Proxy) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Proxy. func (mg *Proxy) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1233,9 +977,9 @@ func (mg *ProxyDefaultTargetGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ProxyDefaultTargetGroup. -func (mg *ProxyDefaultTargetGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ProxyDefaultTargetGroup. +func (mg *ProxyDefaultTargetGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ProxyDefaultTargetGroup. @@ -1243,14 +987,6 @@ func (mg *ProxyDefaultTargetGroup) GetProviderConfigReference() *xpv1.Reference return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ProxyDefaultTargetGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ProxyDefaultTargetGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ProxyDefaultTargetGroup. func (mg *ProxyDefaultTargetGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1271,9 +1007,9 @@ func (mg *ProxyDefaultTargetGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ProxyDefaultTargetGroup. -func (mg *ProxyDefaultTargetGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ProxyDefaultTargetGroup. +func (mg *ProxyDefaultTargetGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ProxyDefaultTargetGroup. @@ -1281,14 +1017,6 @@ func (mg *ProxyDefaultTargetGroup) SetProviderConfigReference(r *xpv1.Reference) mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ProxyDefaultTargetGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ProxyDefaultTargetGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ProxyDefaultTargetGroup. func (mg *ProxyDefaultTargetGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1309,9 +1037,9 @@ func (mg *ProxyEndpoint) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ProxyEndpoint. -func (mg *ProxyEndpoint) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ProxyEndpoint. +func (mg *ProxyEndpoint) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ProxyEndpoint. @@ -1319,14 +1047,6 @@ func (mg *ProxyEndpoint) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ProxyEndpoint. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ProxyEndpoint) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ProxyEndpoint. func (mg *ProxyEndpoint) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1347,9 +1067,9 @@ func (mg *ProxyEndpoint) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ProxyEndpoint. -func (mg *ProxyEndpoint) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ProxyEndpoint. +func (mg *ProxyEndpoint) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ProxyEndpoint. @@ -1357,14 +1077,6 @@ func (mg *ProxyEndpoint) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ProxyEndpoint. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ProxyEndpoint) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ProxyEndpoint. func (mg *ProxyEndpoint) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1385,9 +1097,9 @@ func (mg *ProxyTarget) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this ProxyTarget. -func (mg *ProxyTarget) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this ProxyTarget. +func (mg *ProxyTarget) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this ProxyTarget. @@ -1395,14 +1107,6 @@ func (mg *ProxyTarget) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this ProxyTarget. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *ProxyTarget) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this ProxyTarget. func (mg *ProxyTarget) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1423,9 +1127,9 @@ func (mg *ProxyTarget) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this ProxyTarget. -func (mg *ProxyTarget) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this ProxyTarget. +func (mg *ProxyTarget) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this ProxyTarget. @@ -1433,14 +1137,6 @@ func (mg *ProxyTarget) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this ProxyTarget. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *ProxyTarget) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this ProxyTarget. func (mg *ProxyTarget) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1461,9 +1157,9 @@ func (mg *Snapshot) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this Snapshot. -func (mg *Snapshot) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this Snapshot. +func (mg *Snapshot) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this Snapshot. @@ -1471,14 +1167,6 @@ func (mg *Snapshot) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this Snapshot. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *Snapshot) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this Snapshot. func (mg *Snapshot) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1499,9 +1187,9 @@ func (mg *Snapshot) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this Snapshot. -func (mg *Snapshot) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this Snapshot. +func (mg *Snapshot) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this Snapshot. @@ -1509,14 +1197,6 @@ func (mg *Snapshot) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this Snapshot. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *Snapshot) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this Snapshot. func (mg *Snapshot) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r @@ -1537,9 +1217,9 @@ func (mg *SubnetGroup) GetDeletionPolicy() xpv1.DeletionPolicy { return mg.Spec.DeletionPolicy } -// GetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) GetManagementPolicy() xpv1.ManagementPolicy { - return mg.Spec.ManagementPolicy +// GetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) GetManagementPolicies() xpv1.ManagementPolicies { + return mg.Spec.ManagementPolicies } // GetProviderConfigReference of this SubnetGroup. @@ -1547,14 +1227,6 @@ func (mg *SubnetGroup) GetProviderConfigReference() *xpv1.Reference { return mg.Spec.ProviderConfigReference } -/* -GetProviderReference of this SubnetGroup. -Deprecated: Use GetProviderConfigReference. -*/ -func (mg *SubnetGroup) GetProviderReference() *xpv1.Reference { - return mg.Spec.ProviderReference -} - // GetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) GetPublishConnectionDetailsTo() *xpv1.PublishConnectionDetailsTo { return mg.Spec.PublishConnectionDetailsTo @@ -1575,9 +1247,9 @@ func (mg *SubnetGroup) SetDeletionPolicy(r xpv1.DeletionPolicy) { mg.Spec.DeletionPolicy = r } -// SetManagementPolicy of this SubnetGroup. -func (mg *SubnetGroup) SetManagementPolicy(r xpv1.ManagementPolicy) { - mg.Spec.ManagementPolicy = r +// SetManagementPolicies of this SubnetGroup. +func (mg *SubnetGroup) SetManagementPolicies(r xpv1.ManagementPolicies) { + mg.Spec.ManagementPolicies = r } // SetProviderConfigReference of this SubnetGroup. @@ -1585,14 +1257,6 @@ func (mg *SubnetGroup) SetProviderConfigReference(r *xpv1.Reference) { mg.Spec.ProviderConfigReference = r } -/* -SetProviderReference of this SubnetGroup. -Deprecated: Use SetProviderConfigReference. -*/ -func (mg *SubnetGroup) SetProviderReference(r *xpv1.Reference) { - mg.Spec.ProviderReference = r -} - // SetPublishConnectionDetailsTo of this SubnetGroup. func (mg *SubnetGroup) SetPublishConnectionDetailsTo(r *xpv1.PublishConnectionDetailsTo) { mg.Spec.PublishConnectionDetailsTo = r diff --git a/apis/rds/v1alpha1/zz_generated.resolvers.go b/apis/rds/v1alpha1/zz_generated.resolvers.go index 02ab6d4..5eae73b 100644 --- a/apis/rds/v1alpha1/zz_generated.resolvers.go +++ b/apis/rds/v1alpha1/zz_generated.resolvers.go @@ -8,8 +8,8 @@ package v1alpha1 import ( "context" reference "github.com/crossplane/crossplane-runtime/pkg/reference" + resource "github.com/crossplane/upjet/pkg/resource" errors "github.com/pkg/errors" - resource "github.com/upbound/upjet/pkg/resource" v1alpha11 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" v1alpha1 "kubedb.dev/provider-aws/apis/kms/v1alpha1" common "kubedb.dev/provider-aws/config/common" diff --git a/apis/rds/v1alpha1/zz_generated_terraformed.go b/apis/rds/v1alpha1/zz_generated_terraformed.go index a22550f..938363d 100755 --- a/apis/rds/v1alpha1/zz_generated_terraformed.go +++ b/apis/rds/v1alpha1/zz_generated_terraformed.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -7,10 +11,11 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "dario.cat/mergo" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/resource" - "github.com/upbound/upjet/pkg/resource/json" + "github.com/crossplane/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource/json" ) // GetTerraformResourceType returns Terraform resource type for this ClusterSnapshot @@ -69,6 +74,46 @@ func (tr *ClusterSnapshot) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterSnapshot +func (tr *ClusterSnapshot) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterSnapshot +func (tr *ClusterSnapshot) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterSnapshot using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterSnapshot) LateInitialize(attrs []byte) (bool, error) { @@ -143,6 +188,46 @@ func (tr *EventSubscription) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this EventSubscription +func (tr *EventSubscription) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this EventSubscription +func (tr *EventSubscription) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this EventSubscription using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *EventSubscription) LateInitialize(attrs []byte) (bool, error) { @@ -217,6 +302,46 @@ func (tr *Instance) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Instance +func (tr *Instance) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Instance +func (tr *Instance) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Instance using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Instance) LateInitialize(attrs []byte) (bool, error) { @@ -292,6 +417,46 @@ func (tr *DBInstanceAutomatedBackupsReplication) SetParameters(params map[string return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this DBInstanceAutomatedBackupsReplication +func (tr *DBInstanceAutomatedBackupsReplication) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this DBInstanceAutomatedBackupsReplication +func (tr *DBInstanceAutomatedBackupsReplication) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this DBInstanceAutomatedBackupsReplication using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *DBInstanceAutomatedBackupsReplication) LateInitialize(attrs []byte) (bool, error) { @@ -366,6 +531,46 @@ func (tr *InstanceRoleAssociation) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this InstanceRoleAssociation +func (tr *InstanceRoleAssociation) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this InstanceRoleAssociation +func (tr *InstanceRoleAssociation) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this InstanceRoleAssociation using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *InstanceRoleAssociation) LateInitialize(attrs []byte) (bool, error) { @@ -440,6 +645,46 @@ func (tr *OptionGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this OptionGroup +func (tr *OptionGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this OptionGroup +func (tr *OptionGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this OptionGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *OptionGroup) LateInitialize(attrs []byte) (bool, error) { @@ -514,6 +759,46 @@ func (tr *ParameterGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ParameterGroup +func (tr *ParameterGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ParameterGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ParameterGroup) LateInitialize(attrs []byte) (bool, error) { @@ -588,6 +873,46 @@ func (tr *Proxy) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Proxy +func (tr *Proxy) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Proxy +func (tr *Proxy) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Proxy using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Proxy) LateInitialize(attrs []byte) (bool, error) { @@ -662,6 +987,46 @@ func (tr *ProxyDefaultTargetGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ProxyDefaultTargetGroup +func (tr *ProxyDefaultTargetGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ProxyDefaultTargetGroup +func (tr *ProxyDefaultTargetGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ProxyDefaultTargetGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ProxyDefaultTargetGroup) LateInitialize(attrs []byte) (bool, error) { @@ -736,6 +1101,46 @@ func (tr *ProxyEndpoint) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ProxyEndpoint +func (tr *ProxyEndpoint) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ProxyEndpoint +func (tr *ProxyEndpoint) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ProxyEndpoint using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ProxyEndpoint) LateInitialize(attrs []byte) (bool, error) { @@ -810,6 +1215,46 @@ func (tr *ProxyTarget) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ProxyTarget +func (tr *ProxyTarget) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ProxyTarget +func (tr *ProxyTarget) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ProxyTarget using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ProxyTarget) LateInitialize(attrs []byte) (bool, error) { @@ -884,6 +1329,46 @@ func (tr *Snapshot) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Snapshot +func (tr *Snapshot) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Snapshot +func (tr *Snapshot) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Snapshot using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Snapshot) LateInitialize(attrs []byte) (bool, error) { @@ -958,6 +1443,46 @@ func (tr *DBSnapshotCopy) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this DBSnapshotCopy +func (tr *DBSnapshotCopy) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this DBSnapshotCopy +func (tr *DBSnapshotCopy) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this DBSnapshotCopy using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *DBSnapshotCopy) LateInitialize(attrs []byte) (bool, error) { @@ -1032,6 +1557,46 @@ func (tr *SubnetGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this SubnetGroup +func (tr *SubnetGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this SubnetGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *SubnetGroup) LateInitialize(attrs []byte) (bool, error) { @@ -1106,6 +1671,46 @@ func (tr *Cluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this Cluster +func (tr *Cluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this Cluster +func (tr *Cluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this Cluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *Cluster) LateInitialize(attrs []byte) (bool, error) { @@ -1180,6 +1785,46 @@ func (tr *ClusterActivityStream) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterActivityStream +func (tr *ClusterActivityStream) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterActivityStream +func (tr *ClusterActivityStream) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterActivityStream using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterActivityStream) LateInitialize(attrs []byte) (bool, error) { @@ -1254,6 +1899,46 @@ func (tr *ClusterEndpoint) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterEndpoint +func (tr *ClusterEndpoint) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterEndpoint +func (tr *ClusterEndpoint) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterEndpoint using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterEndpoint) LateInitialize(attrs []byte) (bool, error) { @@ -1328,6 +2013,46 @@ func (tr *ClusterInstance) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterInstance +func (tr *ClusterInstance) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterInstance +func (tr *ClusterInstance) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterInstance using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterInstance) LateInitialize(attrs []byte) (bool, error) { @@ -1402,6 +2127,46 @@ func (tr *ClusterParameterGroup) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterParameterGroup +func (tr *ClusterParameterGroup) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterParameterGroup +func (tr *ClusterParameterGroup) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterParameterGroup using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterParameterGroup) LateInitialize(attrs []byte) (bool, error) { @@ -1476,6 +2241,46 @@ func (tr *ClusterRoleAssociation) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this ClusterRoleAssociation +func (tr *ClusterRoleAssociation) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this ClusterRoleAssociation +func (tr *ClusterRoleAssociation) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this ClusterRoleAssociation using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *ClusterRoleAssociation) LateInitialize(attrs []byte) (bool, error) { @@ -1550,6 +2355,46 @@ func (tr *GlobalCluster) SetParameters(params map[string]any) error { return json.TFParser.Unmarshal(p, &tr.Spec.ForProvider) } +// GetInitParameters of this GlobalCluster +func (tr *GlobalCluster) GetInitParameters() (map[string]any, error) { + p, err := json.TFParser.Marshal(tr.Spec.InitProvider) + if err != nil { + return nil, err + } + base := map[string]any{} + return base, json.TFParser.Unmarshal(p, &base) +} + +// GetInitParameters of this GlobalCluster +func (tr *GlobalCluster) GetMergedParameters(shouldMergeInitProvider bool) (map[string]any, error) { + params, err := tr.GetParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get parameters for resource '%q'", tr.GetName()) + } + if !shouldMergeInitProvider { + return params, nil + } + + initParams, err := tr.GetInitParameters() + if err != nil { + return nil, errors.Wrapf(err, "cannot get init parameters for resource '%q'", tr.GetName()) + } + + // Note(lsviben): mergo.WithSliceDeepCopy is needed to merge the + // slices from the initProvider to forProvider. As it also sets + // overwrite to true, we need to set it back to false, we don't + // want to overwrite the forProvider fields with the initProvider + // fields. + err = mergo.Merge(¶ms, initParams, mergo.WithSliceDeepCopy, func(c *mergo.Config) { + c.Overwrite = false + }) + if err != nil { + return nil, errors.Wrapf(err, "cannot merge spec.initProvider and spec.forProvider parameters for resource '%q'", tr.GetName()) + } + + return params, nil +} + // LateInitialize this GlobalCluster using its observed tfState. // returns True if there are any spec changes for the resource. func (tr *GlobalCluster) LateInitialize(attrs []byte) (bool, error) { diff --git a/apis/rds/v1alpha1/zz_globalcluster_types.go b/apis/rds/v1alpha1/zz_globalcluster_types.go index ce4e451..5be9fd0 100755 --- a/apis/rds/v1alpha1/zz_globalcluster_types.go +++ b/apis/rds/v1alpha1/zz_globalcluster_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,30 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type GlobalClusterInitParameters struct { + + // Name for an automatically created database on cluster creation. + DatabaseName *string `json:"databaseName,omitempty" tf:"database_name,omitempty"` + + // If the Global Cluster should have deletion protection enabled. The database can't be deleted when this value is set to true. The default is false. + DeletionProtection *bool `json:"deletionProtection,omitempty" tf:"deletion_protection,omitempty"` + + // Name of the database engine to be used for this DB cluster. Valid values: aurora, aurora-mysql, aurora-postgresql. Defaults to aurora. Conflicts with source_db_cluster_identifier. + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // Engine version of the Aurora global database. The engine, engine_version, and instance_class (on the aws_rds_cluster_instance) must together support global databases. See Using Amazon Aurora global databases for more information. NOTE: To avoid an inconsistent final plan error while upgrading, use the lifecycle ignore_changes for engine_version meta argument on the associated aws_rds_cluster resource as shown above in Upgrading Engine Versions example. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // Enable to remove DB Cluster members from Global Cluster on destroy. Required with source_db_cluster_identifier. + ForceDestroy *bool `json:"forceDestroy,omitempty" tf:"force_destroy,omitempty"` + + // Specifies whether the DB cluster is encrypted. The default is false unless source_db_cluster_identifier is specified and encrypted. + StorageEncrypted *bool `json:"storageEncrypted,omitempty" tf:"storage_encrypted,omitempty"` +} + +type GlobalClusterMembersInitParameters struct { +} + type GlobalClusterMembersObservation struct { // Amazon Resource Name (ARN) of member DB Cluster @@ -92,7 +120,7 @@ type GlobalClusterParameters struct { // Amazon Resource Name (ARN) to use as the primary DB Cluster of the Global Cluster on creation. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/rds/v1alpha1.Cluster - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("arn",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("arn",true) // +kubebuilder:validation:Optional SourceDBClusterIdentifier *string `json:"sourceDbClusterIdentifier,omitempty" tf:"source_db_cluster_identifier,omitempty"` @@ -113,6 +141,17 @@ type GlobalClusterParameters struct { type GlobalClusterSpec struct { v1.ResourceSpec `json:",inline"` ForProvider GlobalClusterParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider GlobalClusterInitParameters `json:"initProvider,omitempty"` } // GlobalClusterStatus defines the observed state of GlobalCluster. @@ -133,7 +172,7 @@ type GlobalClusterStatus struct { type GlobalCluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec GlobalClusterSpec `json:"spec"` Status GlobalClusterStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_groupversion_info.go b/apis/rds/v1alpha1/zz_groupversion_info.go index 3d0d2f5..829f4b4 100755 --- a/apis/rds/v1alpha1/zz_groupversion_info.go +++ b/apis/rds/v1alpha1/zz_groupversion_info.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/apis/rds/v1alpha1/zz_instance_types.go b/apis/rds/v1alpha1/zz_instance_types.go index 30d84f9..508439c 100755 --- a/apis/rds/v1alpha1/zz_instance_types.go +++ b/apis/rds/v1alpha1/zz_instance_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,13 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type BlueGreenUpdateInitParameters struct { + + // Enables [low-downtime updates](#Low-Downtime Updates) when true. + // Default is false. + Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` +} + type BlueGreenUpdateObservation struct { // Enables [low-downtime updates](#Low-Downtime Updates) when true. @@ -28,6 +39,222 @@ type BlueGreenUpdateParameters struct { Enabled *bool `json:"enabled,omitempty" tf:"enabled,omitempty"` } +type InstanceInitParameters struct { + + // The allocated storage in gibibytes. If max_allocated_storage is configured, this argument represents the initial storage allocation and differences from the configuration will be ignored automatically when Storage Autoscaling occurs. If replicate_source_db is set, the value is ignored during the creation of the instance. + AllocatedStorage *float64 `json:"allocatedStorage,omitempty" tf:"allocated_storage,omitempty"` + + // Indicates that major version + // upgrades are allowed. Changing this parameter does not result in an outage and + // the change is asynchronously applied as soon as possible. + AllowMajorVersionUpgrade *bool `json:"allowMajorVersionUpgrade,omitempty" tf:"allow_major_version_upgrade,omitempty"` + + // Specifies whether any database modifications + // are applied immediately, or during the next maintenance window. Default is + // false. See Amazon RDS Documentation for more + // information. + ApplyImmediately *bool `json:"applyImmediately,omitempty" tf:"apply_immediately,omitempty"` + + // Indicates that minor engine upgrades + // will be applied automatically to the DB instance during the maintenance window. + // Defaults to true. + AutoMinorVersionUpgrade *bool `json:"autoMinorVersionUpgrade,omitempty" tf:"auto_minor_version_upgrade,omitempty"` + + // The AZ for the RDS instance. + AvailabilityZone *string `json:"availabilityZone,omitempty" tf:"availability_zone,omitempty"` + + // The days to retain backups for. + // Must be between 0 and 35. + // Default is 0. + // Must be greater than 0 if the database is used as a source for a Read Replica, + // uses low-downtime updates, + // or will use RDS Blue/Green deployments. + BackupRetentionPeriod *float64 `json:"backupRetentionPeriod,omitempty" tf:"backup_retention_period,omitempty"` + + // The daily time range (in UTC) during which automated backups are created if they are enabled. + // Example: "09:46-10:16". Must not overlap with maintenance_window. + BackupWindow *string `json:"backupWindow,omitempty" tf:"backup_window,omitempty"` + + // Enables low-downtime updates using RDS Blue/Green deployments. + // See blue_green_update below + BlueGreenUpdate []BlueGreenUpdateInitParameters `json:"blueGreenUpdate,omitempty" tf:"blue_green_update,omitempty"` + + // The identifier of the CA certificate for the DB instance. + CACertIdentifier *string `json:"caCertIdentifier,omitempty" tf:"ca_cert_identifier,omitempty"` + + // The character set name to use for DB + // encoding in Oracle and Microsoft SQL instances (collation). This can't be changed. See Oracle Character Sets + // Supported in Amazon RDS + // or Server-Level Collation for Microsoft SQL Server for more information. + CharacterSetName *string `json:"characterSetName,omitempty" tf:"character_set_name,omitempty"` + + // – Copy all Instance tags to snapshots. Default is false. + CopyTagsToSnapshot *bool `json:"copyTagsToSnapshot,omitempty" tf:"copy_tags_to_snapshot,omitempty"` + + // The instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance. + CustomIAMInstanceProfile *string `json:"customIamInstanceProfile,omitempty" tf:"custom_iam_instance_profile,omitempty"` + + // Indicates whether to enable a customer-owned IP address (CoIP) for an RDS on Outposts DB instance. See CoIP for RDS on Outposts for more information. + CustomerOwnedIPEnabled *bool `json:"customerOwnedIpEnabled,omitempty" tf:"customer_owned_ip_enabled,omitempty"` + + // The name of the database to create when the DB instance is created. If this parameter is not specified, no database is created in the DB instance. Note that this does not apply for Oracle or SQL Server engines. See the AWS documentation for more details on what applies for those engines. If you are providing an Oracle db name, it needs to be in all upper case. Cannot be specified for a replica. + DBName *string `json:"dbName,omitempty" tf:"db_name,omitempty"` + + // Specifies whether to remove automated backups immediately after the DB instance is deleted. Default is true. + DeleteAutomatedBackups *bool `json:"deleteAutomatedBackups,omitempty" tf:"delete_automated_backups,omitempty"` + + // If the DB instance should have deletion protection enabled. The database can't be deleted when this value is set to true. The default is false. + DeletionProtection *bool `json:"deletionProtection,omitempty" tf:"deletion_protection,omitempty"` + + // The ID of the Directory Service Active Directory domain to create the instance in. + Domain *string `json:"domain,omitempty" tf:"domain,omitempty"` + + // The name of the IAM role to be used when making API calls to the Directory Service. + DomainIAMRoleName *string `json:"domainIamRoleName,omitempty" tf:"domain_iam_role_name,omitempty"` + + // Set of log types to enable for exporting to CloudWatch logs. If omitted, no logs will be exported. Valid values (depending on engine). MySQL and MariaDB: audit, error, general, slowquery. PostgreSQL: postgresql, upgrade. MSSQL: agent , error. Oracle: alert, audit, listener, trace. + EnabledCloudwatchLogsExports []*string `json:"enabledCloudwatchLogsExports,omitempty" tf:"enabled_cloudwatch_logs_exports,omitempty"` + + // The database engine to use. For supported values, see the Engine parameter in [API action CreateDBInstance](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html). Note that for Amazon Aurora instances the engine must match the [DB Cluster](https://marketplace.upbound.io/providers/kubedb.dev/provider-aws/latest/resources/rds.aws.upbound.io/Cluster/v1alpha1)'s engine'. For information on the difference between the available Aurora MySQL engines see Comparison in the [Amazon RDS Release Notes](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraMySQLReleaseNotes/Welcome.html). + Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` + + // The engine version to use. If `autoMinorVersionUpgrade` is enabled, you can provide a prefix of the version such as 5.7 (for 5.7.10). The actual engine version used is returned in the attribute `status.atProvider.engineVersionActual`. For supported values, see the EngineVersion parameter in [API action CreateDBInstance](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html). Note that for Amazon Aurora instances the engine version must match the [DB Cluster](https://marketplace.upbound.io/providers/kubedb.dev/provider-aws/latest/resources/rds.aws.upbound.io/Cluster/v1alpha1)'s engine version'. + EngineVersion *string `json:"engineVersion,omitempty" tf:"engine_version,omitempty"` + + // The name of your final DB snapshot + // when this DB instance is deleted. Must be provided if skip_final_snapshot is + // set to false. The value must begin with a letter, only contain alphanumeric characters and hyphens, and not end with a hyphen or contain two consecutive hyphens. Must not be provided when deleting a read replica. + FinalSnapshotIdentifier *string `json:"finalSnapshotIdentifier,omitempty" tf:"final_snapshot_identifier,omitempty"` + + // Specifies whether mappings of AWS Identity and Access Management (IAM) accounts to database + // accounts is enabled. + IAMDatabaseAuthenticationEnabled *bool `json:"iamDatabaseAuthenticationEnabled,omitempty" tf:"iam_database_authentication_enabled,omitempty"` + + // The instance type of the RDS instance. + InstanceClass *string `json:"instanceClass,omitempty" tf:"instance_class,omitempty"` + + // The amount of provisioned IOPS. Setting this implies a + // storage_type of "io1". Can only be set when storage_type is "io1" or "gp3". + // Cannot be specified for gp3 storage if the allocated_storage value is below a per-engine threshold. + // See the RDS User Guide for details. + Iops *float64 `json:"iops,omitempty" tf:"iops,omitempty"` + + // License model information for this DB instance. + LicenseModel *string `json:"licenseModel,omitempty" tf:"license_model,omitempty"` + + // The window to perform maintenance in. + // Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00". See RDS + // Maintenance Window + // docs + // for more information. + MaintenanceWindow *string `json:"maintenanceWindow,omitempty" tf:"maintenance_window,omitempty"` + + // Set to true to allow RDS to manage the master user password in Secrets Manager. Cannot be set if password is provided. + ManageMasterUserPassword *bool `json:"manageMasterUserPassword,omitempty" tf:"manage_master_user_password,omitempty"` + + // When configured, the upper limit to which Amazon RDS can automatically scale the storage of the DB instance. Configuring this will automatically ignore differences to allocated_storage. Must be greater than or equal to allocated_storage or 0 to disable Storage Autoscaling. + MaxAllocatedStorage *float64 `json:"maxAllocatedStorage,omitempty" tf:"max_allocated_storage,omitempty"` + + // The interval, in seconds, between points + // when Enhanced Monitoring metrics are collected for the DB instance. To disable + // collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid + // Values: 0, 1, 5, 10, 15, 30, 60. + MonitoringInterval *float64 `json:"monitoringInterval,omitempty" tf:"monitoring_interval,omitempty"` + + // The ARN for the IAM role that permits RDS + // to send enhanced monitoring metrics to CloudWatch Logs. You can find more + // information on the AWS + // Documentation + // what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances. + MonitoringRoleArn *string `json:"monitoringRoleArn,omitempty" tf:"monitoring_role_arn,omitempty"` + + // Specifies if the RDS instance is multi-AZ + MultiAz *bool `json:"multiAz,omitempty" tf:"multi_az,omitempty"` + + // The national character set is used in the NCHAR, NVARCHAR2, and NCLOB data types for Oracle instances. This can't be changed. See Oracle Character Sets + // Supported in Amazon RDS. + NcharCharacterSetName *string `json:"ncharCharacterSetName,omitempty" tf:"nchar_character_set_name,omitempty"` + + // The network type of the DB instance. Valid values: IPV4, DUAL. + NetworkType *string `json:"networkType,omitempty" tf:"network_type,omitempty"` + + // Name of the DB option group to associate. + OptionGroupName *string `json:"optionGroupName,omitempty" tf:"option_group_name,omitempty"` + + // Name of the DB parameter group to + // associate. + ParameterGroupName *string `json:"parameterGroupName,omitempty" tf:"parameter_group_name,omitempty"` + + // Specifies whether Performance Insights are enabled. Defaults to false. + PerformanceInsightsEnabled *bool `json:"performanceInsightsEnabled,omitempty" tf:"performance_insights_enabled,omitempty"` + + // The ARN for the KMS key to encrypt Performance Insights data. When specifying performance_insights_kms_key_id, performance_insights_enabled needs to be set to true. Once KMS key is set, it can never be changed. + PerformanceInsightsKMSKeyID *string `json:"performanceInsightsKmsKeyId,omitempty" tf:"performance_insights_kms_key_id,omitempty"` + + // Amount of time in days to retain Performance Insights data. Valid values are 7, 731 (2 years) or a multiple of 31. When specifying performance_insights_retention_period, performance_insights_enabled needs to be set to true. Defaults to '7'. + PerformanceInsightsRetentionPeriod *float64 `json:"performanceInsightsRetentionPeriod,omitempty" tf:"performance_insights_retention_period,omitempty"` + + // The port on which the DB accepts connections. + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // Bool to control if instance is publicly + // accessible. Default is false. + PubliclyAccessible *bool `json:"publiclyAccessible,omitempty" tf:"publicly_accessible,omitempty"` + + // Specifies whether the replica is in either mounted or open-read-only mode. This attribute + // is only supported by Oracle instances. Oracle replicas operate in open-read-only mode unless otherwise specified. See Working with Oracle Read Replicas for more information. + ReplicaMode *string `json:"replicaMode,omitempty" tf:"replica_mode,omitempty"` + + // A configuration block for restoring a DB instance to an arbitrary point in time. Requires the identifier argument to be set with the name of the new DB instance to be created. See Restore To Point In Time below for details. + RestoreToPointInTime []RestoreToPointInTimeInitParameters `json:"restoreToPointInTime,omitempty" tf:"restore_to_point_in_time,omitempty"` + + // Restore from a Percona Xtrabackup in S3. See Importing Data into an Amazon RDS MySQL DB Instance + S3Import []S3ImportInitParameters `json:"s3Import,omitempty" tf:"s3_import,omitempty"` + + // Determines whether a final DB snapshot is + // created before the DB instance is deleted. If true is specified, no DBSnapshot + // is created. If false is specified, a DB snapshot is created before the DB + // instance is deleted, using the value from final_snapshot_identifier. Default + // is false. + SkipFinalSnapshot *bool `json:"skipFinalSnapshot,omitempty" tf:"skip_final_snapshot,omitempty"` + + // Specifies whether or not to create this + // database from a snapshot. This correlates to the snapshot ID you'd find in the + // RDS console, e.g: rds:production-2015-06-26-06-05. + SnapshotIdentifier *string `json:"snapshotIdentifier,omitempty" tf:"snapshot_identifier,omitempty"` + + // Specifies whether the DB instance is + // encrypted. Note that if you are creating a cross-region read replica this field + // is ignored and you should instead declare kms_key_id with a valid ARN. The + // default is false if not specified. + StorageEncrypted *bool `json:"storageEncrypted,omitempty" tf:"storage_encrypted,omitempty"` + + // The storage throughput value for the DB instance. Can only be set when storage_type is "gp3". Cannot be specified if the allocated_storage value is below a per-engine threshold. See the RDS User Guide for details. + StorageThroughput *float64 `json:"storageThroughput,omitempty" tf:"storage_throughput,omitempty"` + + // One of "standard" (magnetic), "gp2" (general + // purpose SSD), "gp3" (general purpose SSD that needs iops independently) + // or "io1" (provisioned IOPS SSD). The default is "io1" if iops is specified, + // "gp2" if not. + StorageType *string `json:"storageType,omitempty" tf:"storage_type,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Time zone of the DB instance. timezone is currently + // only supported by Microsoft SQL Server. The timezone can only be set on + // creation. See MSSQL User + // Guide + // for more information. + Timezone *string `json:"timezone,omitempty" tf:"timezone,omitempty"` + + // Username for the master DB user. Cannot be specified for a replica. + Username *string `json:"username,omitempty" tf:"username,omitempty"` +} + type InstanceObservation struct { // The hostname of the RDS instance. See also endpoint and port. @@ -495,7 +722,7 @@ type InstanceParameters struct { // The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. To use a KMS key in a different Amazon Web Services account, specify the key ARN or alias ARN. If not specified, the default KMS key for your Amazon Web Services account is used. // +crossplane:generate:reference:type=kubedb.dev/provider-aws/apis/kms/v1alpha1.Key - // +crossplane:generate:reference:extractor=github.com/upbound/upjet/pkg/resource.ExtractParamPath("key_id",true) + // +crossplane:generate:reference:extractor=github.com/crossplane/upjet/pkg/resource.ExtractParamPath("key_id",true) // +kubebuilder:validation:Optional MasterUserSecretKMSKeyID *string `json:"masterUserSecretKmsKeyId,omitempty" tf:"master_user_secret_kms_key_id,omitempty"` @@ -683,6 +910,9 @@ type InstanceParameters struct { VPCSecurityGroupIds []*string `json:"vpcSecurityGroupIds,omitempty" tf:"vpc_security_group_ids,omitempty"` } +type ListenerEndpointInitParameters struct { +} + type ListenerEndpointObservation struct { // The hostname of the RDS instance. See also endpoint and port. @@ -699,6 +929,9 @@ type ListenerEndpointObservation struct { type ListenerEndpointParameters struct { } +type MasterUserSecretInitParameters struct { +} + type MasterUserSecretObservation struct { // The Amazon Web Services KMS key identifier that is used to encrypt the secret. @@ -714,6 +947,24 @@ type MasterUserSecretObservation struct { type MasterUserSecretParameters struct { } +type RestoreToPointInTimeInitParameters struct { + + // The date and time to restore from. Value must be a time in Universal Coordinated Time (UTC) format and must be before the latest restorable time for the DB instance. Cannot be specified with use_latest_restorable_time. + RestoreTime *string `json:"restoreTime,omitempty" tf:"restore_time,omitempty"` + + // The ARN of the automated backup from which to restore. Required if source_db_instance_identifier or source_dbi_resource_id is not specified. + SourceDBInstanceAutomatedBackupsArn *string `json:"sourceDbInstanceAutomatedBackupsArn,omitempty" tf:"source_db_instance_automated_backups_arn,omitempty"` + + // The identifier of the source DB instance from which to restore. Must match the identifier of an existing DB instance. Required if source_db_instance_automated_backups_arn or source_dbi_resource_id is not specified. + SourceDBInstanceIdentifier *string `json:"sourceDbInstanceIdentifier,omitempty" tf:"source_db_instance_identifier,omitempty"` + + // The resource ID of the source DB instance from which to restore. Required if source_db_instance_identifier or source_db_instance_automated_backups_arn is not specified. + SourceDbiResourceID *string `json:"sourceDbiResourceId,omitempty" tf:"source_dbi_resource_id,omitempty"` + + // A boolean value that indicates whether the DB instance is restored from the latest backup time. Defaults to false. Cannot be specified with restore_time. + UseLatestRestorableTime *bool `json:"useLatestRestorableTime,omitempty" tf:"use_latest_restorable_time,omitempty"` +} + type RestoreToPointInTimeObservation struct { // The date and time to restore from. Value must be a time in Universal Coordinated Time (UTC) format and must be before the latest restorable time for the DB instance. Cannot be specified with use_latest_restorable_time. @@ -755,6 +1006,24 @@ type RestoreToPointInTimeParameters struct { UseLatestRestorableTime *bool `json:"useLatestRestorableTime,omitempty" tf:"use_latest_restorable_time,omitempty"` } +type S3ImportInitParameters struct { + + // The bucket name where your backup is stored + BucketName *string `json:"bucketName,omitempty" tf:"bucket_name,omitempty"` + + // Can be blank, but is the path to your backup + BucketPrefix *string `json:"bucketPrefix,omitempty" tf:"bucket_prefix,omitempty"` + + // Role applied to load the data. + IngestionRole *string `json:"ingestionRole,omitempty" tf:"ingestion_role,omitempty"` + + // Source engine for the backup + SourceEngine *string `json:"sourceEngine,omitempty" tf:"source_engine,omitempty"` + + // Version of the source engine used to make the backup + SourceEngineVersion *string `json:"sourceEngineVersion,omitempty" tf:"source_engine_version,omitempty"` +} + type S3ImportObservation struct { // The bucket name where your backup is stored @@ -776,7 +1045,7 @@ type S3ImportObservation struct { type S3ImportParameters struct { // The bucket name where your backup is stored - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional BucketName *string `json:"bucketName" tf:"bucket_name,omitempty"` // Can be blank, but is the path to your backup @@ -784,15 +1053,15 @@ type S3ImportParameters struct { BucketPrefix *string `json:"bucketPrefix,omitempty" tf:"bucket_prefix,omitempty"` // Role applied to load the data. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional IngestionRole *string `json:"ingestionRole" tf:"ingestion_role,omitempty"` // Source engine for the backup - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional SourceEngine *string `json:"sourceEngine" tf:"source_engine,omitempty"` // Version of the source engine used to make the backup - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional SourceEngineVersion *string `json:"sourceEngineVersion" tf:"source_engine_version,omitempty"` } @@ -800,6 +1069,17 @@ type S3ImportParameters struct { type InstanceSpec struct { v1.ResourceSpec `json:",inline"` ForProvider InstanceParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider InstanceInitParameters `json:"initProvider,omitempty"` } // InstanceStatus defines the observed state of Instance. @@ -820,8 +1100,8 @@ type InstanceStatus struct { type Instance struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass)",message="instanceClass is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.instanceClass) || (has(self.initProvider) && has(self.initProvider.instanceClass))",message="spec.forProvider.instanceClass is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec InstanceSpec `json:"spec"` Status InstanceStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_instanceroleassociation_types.go b/apis/rds/v1alpha1/zz_instanceroleassociation_types.go index db844ba..2dd7b80 100755 --- a/apis/rds/v1alpha1/zz_instanceroleassociation_types.go +++ b/apis/rds/v1alpha1/zz_instanceroleassociation_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type InstanceRoleAssociationInitParameters struct { + + // Name of the feature for association. This can be found in the AWS documentation relevant to the integration or a full list is available in the SupportedFeatureNames list returned by AWS CLI rds describe-db-engine-versions. + FeatureName *string `json:"featureName,omitempty" tf:"feature_name,omitempty"` + + // Amazon Resource Name (ARN) of the IAM Role to associate with the DB Instance. + RoleArn *string `json:"roleArn,omitempty" tf:"role_arn,omitempty"` +} + type InstanceRoleAssociationObservation struct { // DB Instance Identifier to associate with the IAM Role. @@ -61,6 +74,17 @@ type InstanceRoleAssociationParameters struct { type InstanceRoleAssociationSpec struct { v1.ResourceSpec `json:",inline"` ForProvider InstanceRoleAssociationParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider InstanceRoleAssociationInitParameters `json:"initProvider,omitempty"` } // InstanceRoleAssociationStatus defines the observed state of InstanceRoleAssociation. @@ -81,9 +105,9 @@ type InstanceRoleAssociationStatus struct { type InstanceRoleAssociation struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.featureName)",message="featureName is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn)",message="roleArn is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.featureName) || (has(self.initProvider) && has(self.initProvider.featureName))",message="spec.forProvider.featureName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.roleArn) || (has(self.initProvider) && has(self.initProvider.roleArn))",message="spec.forProvider.roleArn is a required parameter" Spec InstanceRoleAssociationSpec `json:"spec"` Status InstanceRoleAssociationStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_optiongroup_types.go b/apis/rds/v1alpha1/zz_optiongroup_types.go index 24b7b3c..956b44d 100755 --- a/apis/rds/v1alpha1/zz_optiongroup_types.go +++ b/apis/rds/v1alpha1/zz_optiongroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,27 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type OptionGroupInitParameters struct { + + // Specifies the name of the engine that this option group should be associated with. + EngineName *string `json:"engineName,omitempty" tf:"engine_name,omitempty"` + + // Specifies the major version of the engine that this option group should be associated with. + MajorEngineVersion *string `json:"majorEngineVersion,omitempty" tf:"major_engine_version,omitempty"` + + // A list of Options to apply. + Option []OptionInitParameters `json:"option,omitempty" tf:"option,omitempty"` + + // The description of the option group. + OptionGroupDescription *string `json:"optionGroupDescription,omitempty" tf:"option_group_description,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type OptionGroupObservation struct { // The ARN of the db option group. @@ -72,6 +97,27 @@ type OptionGroupParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type OptionInitParameters struct { + + // A list of DB Security Groups for which the option is enabled. + DBSecurityGroupMemberships []*string `json:"dbSecurityGroupMemberships,omitempty" tf:"db_security_group_memberships,omitempty"` + + // The Name of the Option (e.g., MEMCACHED). + OptionName *string `json:"optionName,omitempty" tf:"option_name,omitempty"` + + // A list of option settings to apply. + OptionSettings []OptionSettingsInitParameters `json:"optionSettings,omitempty" tf:"option_settings,omitempty"` + + // The Port number when connecting to the Option (e.g., 11211). + Port *float64 `json:"port,omitempty" tf:"port,omitempty"` + + // A list of VPC Security Groups for which the option is enabled. + VPCSecurityGroupMemberships []*string `json:"vpcSecurityGroupMemberships,omitempty" tf:"vpc_security_group_memberships,omitempty"` + + // The version of the option (e.g., 13.1.0.0). + Version *string `json:"version,omitempty" tf:"version,omitempty"` +} + type OptionObservation struct { // A list of DB Security Groups for which the option is enabled. @@ -100,7 +146,7 @@ type OptionParameters struct { DBSecurityGroupMemberships []*string `json:"dbSecurityGroupMemberships,omitempty" tf:"db_security_group_memberships,omitempty"` // The Name of the Option (e.g., MEMCACHED). - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional OptionName *string `json:"optionName" tf:"option_name,omitempty"` // A list of option settings to apply. @@ -120,6 +166,15 @@ type OptionParameters struct { Version *string `json:"version,omitempty" tf:"version,omitempty"` } +type OptionSettingsInitParameters struct { + + // The name of the option group. Must be lowercase, to match as it is stored in AWS. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The Value of the setting. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type OptionSettingsObservation struct { // The name of the option group. Must be lowercase, to match as it is stored in AWS. @@ -132,11 +187,11 @@ type OptionSettingsObservation struct { type OptionSettingsParameters struct { // The name of the option group. Must be lowercase, to match as it is stored in AWS. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The Value of the setting. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -144,6 +199,17 @@ type OptionSettingsParameters struct { type OptionGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider OptionGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider OptionGroupInitParameters `json:"initProvider,omitempty"` } // OptionGroupStatus defines the observed state of OptionGroup. @@ -164,9 +230,9 @@ type OptionGroupStatus struct { type OptionGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engineName)",message="engineName is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.majorEngineVersion)",message="majorEngineVersion is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engineName) || (has(self.initProvider) && has(self.initProvider.engineName))",message="spec.forProvider.engineName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.majorEngineVersion) || (has(self.initProvider) && has(self.initProvider.majorEngineVersion))",message="spec.forProvider.majorEngineVersion is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec OptionGroupSpec `json:"spec"` Status OptionGroupStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_parametergroup_types.go b/apis/rds/v1alpha1/zz_parametergroup_types.go index b57d922..bba6e14 100755 --- a/apis/rds/v1alpha1/zz_parametergroup_types.go +++ b/apis/rds/v1alpha1/zz_parametergroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ParameterGroupInitParameters struct { + + // The description of the DB parameter group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // The family of the DB parameter group. + Family *string `json:"family,omitempty" tf:"family,omitempty"` + + // A list of DB parameters to apply. Note that parameters may differ from a family to an other. Full list of all parameters can be discovered via aws rds describe-db-parameters after initial creation of the group. + Parameter []ParameterInitParameters `json:"parameter,omitempty" tf:"parameter,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type ParameterGroupObservation struct { // The ARN of the db parameter group. @@ -65,6 +87,20 @@ type ParameterGroupParameters struct { TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` } +type ParameterInitParameters struct { + + // "immediate" (default), or "pending-reboot". Some + // engines can't apply some parameters without a reboot, and you will need to + // specify "pending-reboot" here. + ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` + + // The name of the DB parameter group. + Name *string `json:"name,omitempty" tf:"name,omitempty"` + + // The value of the DB parameter. + Value *string `json:"value,omitempty" tf:"value,omitempty"` +} + type ParameterObservation struct { // "immediate" (default), or "pending-reboot". Some @@ -88,11 +124,11 @@ type ParameterParameters struct { ApplyMethod *string `json:"applyMethod,omitempty" tf:"apply_method,omitempty"` // The name of the DB parameter group. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Name *string `json:"name" tf:"name,omitempty"` // The value of the DB parameter. - // +kubebuilder:validation:Required + // +kubebuilder:validation:Optional Value *string `json:"value" tf:"value,omitempty"` } @@ -100,6 +136,17 @@ type ParameterParameters struct { type ParameterGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ParameterGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ParameterGroupInitParameters `json:"initProvider,omitempty"` } // ParameterGroupStatus defines the observed state of ParameterGroup. @@ -120,8 +167,8 @@ type ParameterGroupStatus struct { type ParameterGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family)",message="family is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.family) || (has(self.initProvider) && has(self.initProvider.family))",message="spec.forProvider.family is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ParameterGroupSpec `json:"spec"` Status ParameterGroupStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_proxy_types.go b/apis/rds/v1alpha1/zz_proxy_types.go index ef05432..af45845 100755 --- a/apis/rds/v1alpha1/zz_proxy_types.go +++ b/apis/rds/v1alpha1/zz_proxy_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,27 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type AuthInitParameters struct { + + // The type of authentication that the proxy uses for connections from the proxy to the underlying database. One of SECRETS. + AuthScheme *string `json:"authScheme,omitempty" tf:"auth_scheme,omitempty"` + + // The type of authentication the proxy uses for connections from clients. Valid values are MYSQL_NATIVE_PASSWORD, POSTGRES_SCRAM_SHA_256, POSTGRES_MD5, and SQL_SERVER_AUTHENTICATION. + ClientPasswordAuthType *string `json:"clientPasswordAuthType,omitempty" tf:"client_password_auth_type,omitempty"` + + // A user-specified description about the authentication used by a proxy to log in as a specific database user. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // Whether to require or disallow AWS Identity and Access Management (IAM) authentication for connections to the proxy. One of DISABLED, REQUIRED. + IAMAuth *string `json:"iamAuth,omitempty" tf:"iam_auth,omitempty"` + + // The Amazon Resource Name (ARN) representing the secret that the proxy uses to authenticate to the RDS DB instance or Aurora DB cluster. These secrets are stored within Amazon Secrets Manager. + SecretArn *string `json:"secretArn,omitempty" tf:"secret_arn,omitempty"` + + // The name of the database user to which the proxy connects. + Username *string `json:"username,omitempty" tf:"username,omitempty"` +} + type AuthObservation struct { // The type of authentication that the proxy uses for connections from the proxy to the underlying database. One of SECRETS. @@ -61,6 +86,36 @@ type AuthParameters struct { Username *string `json:"username,omitempty" tf:"username,omitempty"` } +type ProxyInitParameters struct { + + // Configuration block(s) with authorization mechanisms to connect to the associated instances or clusters. Described below. + Auth []AuthInitParameters `json:"auth,omitempty" tf:"auth,omitempty"` + + // Whether the proxy includes detailed information about SQL statements in its logs. This information helps you to debug issues involving SQL behavior or the performance and scalability of the proxy connections. The debug information includes the text of SQL statements that you submit through the proxy. Thus, only enable this setting when needed for debugging, and only when you have security measures in place to safeguard any sensitive information that appears in the logs. + DebugLogging *bool `json:"debugLogging,omitempty" tf:"debug_logging,omitempty"` + + // The kinds of databases that the proxy can connect to. This value determines which database network protocol the proxy recognizes when it interprets network traffic to and from the database. The engine family applies to MySQL and PostgreSQL for both RDS and Aurora. Valid values are MYSQL and POSTGRESQL. + EngineFamily *string `json:"engineFamily,omitempty" tf:"engine_family,omitempty"` + + // The number of seconds that a connection to the proxy can be inactive before the proxy disconnects it. You can set this value higher or lower than the connection timeout limit for the associated database. + IdleClientTimeout *float64 `json:"idleClientTimeout,omitempty" tf:"idle_client_timeout,omitempty"` + + // A Boolean parameter that specifies whether Transport Layer Security (TLS) encryption is required for connections to the proxy. By enabling this setting, you can enforce encrypted TLS connections to the proxy. + RequireTLS *bool `json:"requireTls,omitempty" tf:"require_tls,omitempty"` + + // The Amazon Resource Name (ARN) of the IAM role that the proxy uses to access secrets in AWS Secrets Manager. + RoleArn *string `json:"roleArn,omitempty" tf:"role_arn,omitempty"` + + // A mapping of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // One or more VPC subnet IDs to associate with the new proxy. + VPCSubnetIds []*string `json:"vpcSubnetIds,omitempty" tf:"vpc_subnet_ids,omitempty"` +} + type ProxyObservation struct { // The Amazon Resource Name (ARN) for the proxy. @@ -166,6 +221,17 @@ type ProxyParameters struct { type ProxySpec struct { v1.ResourceSpec `json:",inline"` ForProvider ProxyParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ProxyInitParameters `json:"initProvider,omitempty"` } // ProxyStatus defines the observed state of Proxy. @@ -186,11 +252,11 @@ type ProxyStatus struct { type Proxy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.auth)",message="auth is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engineFamily)",message="engineFamily is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn)",message="roleArn is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.vpcSubnetIds)",message="vpcSubnetIds is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.auth) || (has(self.initProvider) && has(self.initProvider.auth))",message="spec.forProvider.auth is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engineFamily) || (has(self.initProvider) && has(self.initProvider.engineFamily))",message="spec.forProvider.engineFamily is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.roleArn) || (has(self.initProvider) && has(self.initProvider.roleArn))",message="spec.forProvider.roleArn is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.vpcSubnetIds) || (has(self.initProvider) && has(self.initProvider.vpcSubnetIds))",message="spec.forProvider.vpcSubnetIds is a required parameter" Spec ProxySpec `json:"spec"` Status ProxyStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_proxydefaulttargetgroup_types.go b/apis/rds/v1alpha1/zz_proxydefaulttargetgroup_types.go index 706a567..4bf2937 100755 --- a/apis/rds/v1alpha1/zz_proxydefaulttargetgroup_types.go +++ b/apis/rds/v1alpha1/zz_proxydefaulttargetgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,24 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ConnectionPoolConfigInitParameters struct { + + // The number of seconds for a proxy to wait for a connection to become available in the connection pool. Only applies when the proxy has opened its maximum number of connections and all connections are busy with client sessions. + ConnectionBorrowTimeout *float64 `json:"connectionBorrowTimeout,omitempty" tf:"connection_borrow_timeout,omitempty"` + + // One or more SQL statements for the proxy to run when opening each new database connection. Typically used with SET statements to make sure that each connection has identical settings such as time zone and character set. This setting is empty by default. For multiple statements, use semicolons as the separator. You can also include multiple variables in a single SET statement, such as SET x=1, y=2. + InitQuery *string `json:"initQuery,omitempty" tf:"init_query,omitempty"` + + // The maximum size of the connection pool for each target in a target group. For Aurora MySQL, it is expressed as a percentage of the max_connections setting for the RDS DB instance or Aurora DB cluster used by the target group. + MaxConnectionsPercent *float64 `json:"maxConnectionsPercent,omitempty" tf:"max_connections_percent,omitempty"` + + // Controls how actively the proxy closes idle database connections in the connection pool. A high value enables the proxy to leave a high percentage of idle connections open. A low value causes the proxy to close idle client connections and return the underlying database connections to the connection pool. For Aurora MySQL, it is expressed as a percentage of the max_connections setting for the RDS DB instance or Aurora DB cluster used by the target group. + MaxIdleConnectionsPercent *float64 `json:"maxIdleConnectionsPercent,omitempty" tf:"max_idle_connections_percent,omitempty"` + + // Each item in the list represents a class of SQL operations that normally cause all later statements in a session using a proxy to be pinned to the same underlying database connection. Including an item in the list exempts that class of SQL operations from the pinning behavior. Currently, the only allowed value is EXCLUDE_VARIABLE_SETS. + SessionPinningFilters []*string `json:"sessionPinningFilters,omitempty" tf:"session_pinning_filters,omitempty"` +} + type ConnectionPoolConfigObservation struct { // The number of seconds for a proxy to wait for a connection to become available in the connection pool. Only applies when the proxy has opened its maximum number of connections and all connections are busy with client sessions. @@ -54,6 +76,12 @@ type ConnectionPoolConfigParameters struct { SessionPinningFilters []*string `json:"sessionPinningFilters,omitempty" tf:"session_pinning_filters,omitempty"` } +type ProxyDefaultTargetGroupInitParameters struct { + + // The settings that determine the size and behavior of the connection pool for the target group. + ConnectionPoolConfig []ConnectionPoolConfigInitParameters `json:"connectionPoolConfig,omitempty" tf:"connection_pool_config,omitempty"` +} + type ProxyDefaultTargetGroupObservation struct { // The Amazon Resource Name (ARN) representing the target group. @@ -101,6 +129,17 @@ type ProxyDefaultTargetGroupParameters struct { type ProxyDefaultTargetGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ProxyDefaultTargetGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ProxyDefaultTargetGroupInitParameters `json:"initProvider,omitempty"` } // ProxyDefaultTargetGroupStatus defines the observed state of ProxyDefaultTargetGroup. @@ -121,7 +160,7 @@ type ProxyDefaultTargetGroupStatus struct { type ProxyDefaultTargetGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec ProxyDefaultTargetGroupSpec `json:"spec"` Status ProxyDefaultTargetGroupStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_proxyendpoint_types.go b/apis/rds/v1alpha1/zz_proxyendpoint_types.go index f407803..45f47ec 100755 --- a/apis/rds/v1alpha1/zz_proxyendpoint_types.go +++ b/apis/rds/v1alpha1/zz_proxyendpoint_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,20 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ProxyEndpointInitParameters struct { + + // A mapping of tags to assign to the resource. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` + + // Indicates whether the DB proxy endpoint can be used for read/write or read-only operations. The default is READ_WRITE. Valid values are READ_WRITE and READ_ONLY. + TargetRole *string `json:"targetRole,omitempty" tf:"target_role,omitempty"` + + // One or more VPC subnet IDs to associate with the new proxy. + VPCSubnetIds []*string `json:"vpcSubnetIds,omitempty" tf:"vpc_subnet_ids,omitempty"` +} + type ProxyEndpointObservation struct { // The Amazon Resource Name (ARN) for the proxy endpoint. @@ -103,6 +121,17 @@ type ProxyEndpointParameters struct { type ProxyEndpointSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ProxyEndpointParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ProxyEndpointInitParameters `json:"initProvider,omitempty"` } // ProxyEndpointStatus defines the observed state of ProxyEndpoint. @@ -123,8 +152,8 @@ type ProxyEndpointStatus struct { type ProxyEndpoint struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.vpcSubnetIds)",message="vpcSubnetIds is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.vpcSubnetIds) || (has(self.initProvider) && has(self.initProvider.vpcSubnetIds))",message="spec.forProvider.vpcSubnetIds is a required parameter" Spec ProxyEndpointSpec `json:"spec"` Status ProxyEndpointStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_proxytarget_types.go b/apis/rds/v1alpha1/zz_proxytarget_types.go index 80db2db..f0e2488 100755 --- a/apis/rds/v1alpha1/zz_proxytarget_types.go +++ b/apis/rds/v1alpha1/zz_proxytarget_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,15 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type ProxyTargetInitParameters struct { + + // DB cluster identifier. + DBClusterIdentifier *string `json:"dbClusterIdentifier,omitempty" tf:"db_cluster_identifier,omitempty"` + + // The name of the target group. + TargetGroupName *string `json:"targetGroupName,omitempty" tf:"target_group_name,omitempty"` +} + type ProxyTargetObservation struct { // DB cluster identifier. @@ -95,6 +108,17 @@ type ProxyTargetParameters struct { type ProxyTargetSpec struct { v1.ResourceSpec `json:",inline"` ForProvider ProxyTargetParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider ProxyTargetInitParameters `json:"initProvider,omitempty"` } // ProxyTargetStatus defines the observed state of ProxyTarget. @@ -115,8 +139,8 @@ type ProxyTargetStatus struct { type ProxyTarget struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.targetGroupName)",message="targetGroupName is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.targetGroupName) || (has(self.initProvider) && has(self.initProvider.targetGroupName))",message="spec.forProvider.targetGroupName is a required parameter" Spec ProxyTargetSpec `json:"spec"` Status ProxyTargetStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_snapshot_types.go b/apis/rds/v1alpha1/zz_snapshot_types.go index 9b8dd69..8a977c8 100755 --- a/apis/rds/v1alpha1/zz_snapshot_types.go +++ b/apis/rds/v1alpha1/zz_snapshot_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SnapshotInitParameters struct { + + // List of AWS Account ids to share snapshot with, use all to make snaphot public. + SharedAccounts []*string `json:"sharedAccounts,omitempty" tf:"shared_accounts,omitempty"` + + // Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SnapshotObservation struct { // Specifies the allocated storage size in gigabytes (GB). @@ -116,6 +132,17 @@ type SnapshotParameters struct { type SnapshotSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SnapshotParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SnapshotInitParameters `json:"initProvider,omitempty"` } // SnapshotStatus defines the observed state of Snapshot. @@ -136,7 +163,7 @@ type SnapshotStatus struct { type Snapshot struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SnapshotSpec `json:"spec"` Status SnapshotStatus `json:"status,omitempty"` } diff --git a/apis/rds/v1alpha1/zz_subnetgroup_types.go b/apis/rds/v1alpha1/zz_subnetgroup_types.go index 3ba0f21..ed4a411 100755 --- a/apis/rds/v1alpha1/zz_subnetgroup_types.go +++ b/apis/rds/v1alpha1/zz_subnetgroup_types.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -13,6 +17,18 @@ import ( v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" ) +type SubnetGroupInitParameters struct { + + // The description of the DB subnet group. + Description *string `json:"description,omitempty" tf:"description,omitempty"` + + // A map of tags to assign to the resource. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. + Tags map[string]*string `json:"tags,omitempty" tf:"tags,omitempty"` + + // A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block. + TagsAll map[string]*string `json:"tagsAll,omitempty" tf:"tags_all,omitempty"` +} + type SubnetGroupObservation struct { // The ARN of the db subnet group. @@ -79,6 +95,17 @@ type SubnetGroupParameters struct { type SubnetGroupSpec struct { v1.ResourceSpec `json:",inline"` ForProvider SubnetGroupParameters `json:"forProvider"` + // THIS IS A BETA FIELD. It will be honored + // unless the Management Policies feature flag is disabled. + // InitProvider holds the same fields as ForProvider, with the exception + // of Identifier and other resource reference fields. The fields that are + // in InitProvider are merged into ForProvider when the resource is created. + // The same fields are also added to the terraform ignore_changes hook, to + // avoid updating them after creation. This is useful for fields that are + // required on creation, but we do not desire to update them after creation, + // for example because of an external controller is managing them, like an + // autoscaler. + InitProvider SubnetGroupInitParameters `json:"initProvider,omitempty"` } // SubnetGroupStatus defines the observed state of SubnetGroup. @@ -99,7 +126,7 @@ type SubnetGroupStatus struct { type SubnetGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region)",message="region is a required parameter" + // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.region)",message="spec.forProvider.region is a required parameter" Spec SubnetGroupSpec `json:"spec"` Status SubnetGroupStatus `json:"status,omitempty"` } diff --git a/apis/v1alpha1/zz_generated.deepcopy.go b/apis/v1alpha1/zz_generated.deepcopy.go index 9d284ba..86f2d29 100644 --- a/apis/v1alpha1/zz_generated.deepcopy.go +++ b/apis/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. diff --git a/apis/v1beta1/zz_generated.deepcopy.go b/apis/v1beta1/zz_generated.deepcopy.go index ae71405..09df2c1 100644 --- a/apis/v1beta1/zz_generated.deepcopy.go +++ b/apis/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2022 Upbound Inc. diff --git a/apis/zz_register.go b/apis/zz_register.go index fd52511..01b6637 100755 --- a/apis/zz_register.go +++ b/apis/zz_register.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ diff --git a/cmd/generator/main.go b/cmd/generator/main.go index 0672a46..ce77a54 100644 --- a/cmd/generator/main.go +++ b/cmd/generator/main.go @@ -9,7 +9,7 @@ import ( "os" "path/filepath" - "github.com/upbound/upjet/pkg/pipeline" + "github.com/crossplane/upjet/pkg/pipeline" "kubedb.dev/provider-aws/config" ) diff --git a/cmd/provider/main.go b/cmd/provider/main.go index 1403ee6..0a16a56 100644 --- a/cmd/provider/main.go +++ b/cmd/provider/main.go @@ -6,8 +6,11 @@ package main import ( "context" + "github.com/crossplane/crossplane-runtime/pkg/feature" + "gopkg.in/alecthomas/kingpin.v2" "os" "path/filepath" + "sigs.k8s.io/controller-runtime/pkg/cache" "time" xpv1 "github.com/crossplane/crossplane-runtime/apis/common/v1" @@ -15,9 +18,8 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/logging" "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" - "gopkg.in/alecthomas/kingpin.v2" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/terraform" kerrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/tools/leaderelection/resourcelock" @@ -34,18 +36,20 @@ import ( func main() { var ( - app = kingpin.New(filepath.Base(os.Args[0]), "Terraform based Crossplane provider for AWS").DefaultEnvars() + app = kingpin.New(filepath.Base(os.Args[0]), "Terraform based Crossplane provider for Aws").DefaultEnvars() debug = app.Flag("debug", "Run with debug logging.").Short('d').Bool() syncPeriod = app.Flag("sync", "Controller manager sync period such as 300ms, 1.5h, or 2h45m").Short('s').Default("1h").Duration() + pollInterval = app.Flag("poll", "Poll interval controls how often an individual resource should be checked for drift.").Default("10m").Duration() leaderElection = app.Flag("leader-election", "Use leader election for the controller manager.").Short('l').Default("false").OverrideDefaultFromEnvar("LEADER_ELECTION").Bool() + maxReconcileRate = app.Flag("max-reconcile-rate", "The global maximum rate per second at which resources may be checked for drift from the desired state.").Default("10").Int() + terraformVersion = app.Flag("terraform-version", "Terraform version.").Required().Envar("TERRAFORM_VERSION").String() providerSource = app.Flag("terraform-provider-source", "Terraform provider source.").Required().Envar("TERRAFORM_PROVIDER_SOURCE").String() providerVersion = app.Flag("terraform-provider-version", "Terraform provider version.").Required().Envar("TERRAFORM_PROVIDER_VERSION").String() - maxReconcileRate = app.Flag("max-reconcile-rate", "The global maximum rate per second at which resources may checked for drift from the desired state.").Default("10").Int() namespace = app.Flag("namespace", "Namespace used to set as default scope in default secret store config.").Default("crossplane-system").Envar("POD_NAMESPACE").String() enableExternalSecretStores = app.Flag("enable-external-secret-stores", "Enable support for ExternalSecretStores.").Default("false").Envar("ENABLE_EXTERNAL_SECRET_STORES").Bool() - enableManagementPolicies = app.Flag("enable-management-policies", "Enable support for Management Policies.").Default("false").Envar("ENABLE_MANAGEMENT_POLICIES").Bool() + enableManagementPolicies = app.Flag("enable-management-policies", "Enable support for Management Policies.").Default("true").Envar("ENABLE_MANAGEMENT_POLICIES").Bool() ) kingpin.MustParse(app.Parse(os.Args[1:])) @@ -59,27 +63,30 @@ func main() { ctrl.SetLogger(zl) } - log.Debug("Starting", "sync-period", syncPeriod.String()) + log.Debug("Starting", "sync-period", syncPeriod.String(), "poll-interval", pollInterval.String(), "max-reconcile-rate", *maxReconcileRate) cfg, err := ctrl.GetConfig() kingpin.FatalIfError(err, "Cannot get API server rest config") mgr, err := ctrl.NewManager(cfg, ctrl.Options{ - LeaderElection: *leaderElection, - LeaderElectionID: "crossplane-leader-election-provider-aws", - SyncPeriod: syncPeriod, + LeaderElection: *leaderElection, + LeaderElectionID: "crossplane-leader-election-provider-aws", + Cache: cache.Options{ + SyncPeriod: syncPeriod, + }, LeaderElectionResourceLock: resourcelock.LeasesResourceLock, LeaseDuration: func() *time.Duration { d := 60 * time.Second; return &d }(), RenewDeadline: func() *time.Duration { d := 50 * time.Second; return &d }(), }) kingpin.FatalIfError(err, "Cannot create controller manager") - kingpin.FatalIfError(apis.AddToScheme(mgr.GetScheme()), "Cannot add AWS APIs to scheme") + kingpin.FatalIfError(apis.AddToScheme(mgr.GetScheme()), "Cannot add Aws APIs to scheme") o := tjcontroller.Options{ Options: xpcontroller.Options{ Logger: log, GlobalRateLimiter: ratelimiter.NewGlobal(*maxReconcileRate), - PollInterval: 1 * time.Minute, - MaxConcurrentReconciles: 1, + PollInterval: *pollInterval, + MaxConcurrentReconciles: *maxReconcileRate, + Features: &feature.Flags{}, }, Provider: config.GetProvider(), // use the following WorkspaceStoreOption to enable the shared gRPC mode @@ -108,10 +115,10 @@ func main() { } if *enableManagementPolicies { - o.Features.Enable(features.EnableAlphaManagementPolicies) - log.Info("Alpha feature enabled", "flag", features.EnableAlphaManagementPolicies) + o.Features.Enable(features.EnableBetaManagementPolicies) + log.Info("Beta feature enabled", "flag", features.EnableBetaManagementPolicies) } - kingpin.FatalIfError(controller.Setup(mgr, o), "Cannot setup AWS controllers") + kingpin.FatalIfError(controller.Setup(mgr, o), "Cannot setup Aws controllers") kingpin.FatalIfError(mgr.Start(ctrl.SetupSignalHandler()), "Cannot start controller manager") } diff --git a/config/common/config.go b/config/common/config.go index c441949..ad8d1c8 100644 --- a/config/common/config.go +++ b/config/common/config.go @@ -8,7 +8,7 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/fieldpath" "github.com/crossplane/crossplane-runtime/pkg/reference" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - "github.com/upbound/upjet/pkg/resource" + "github.com/crossplane/upjet/pkg/resource" ) const ( diff --git a/config/docdb/config.go b/config/docdb/config.go index e187050..255e98a 100644 --- a/config/docdb/config.go +++ b/config/docdb/config.go @@ -1,6 +1,6 @@ package docdb -import "github.com/upbound/upjet/pkg/config" +import "github.com/crossplane/upjet/pkg/config" // Configure adds configurations for docdb group. func Configure(p *config.Provider) { diff --git a/config/dynamodb/config.go b/config/dynamodb/config.go index 074dfe0..4c8cd9c 100644 --- a/config/dynamodb/config.go +++ b/config/dynamodb/config.go @@ -5,7 +5,7 @@ Copyright 2022 Upbound Inc. package dynamodb import ( - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" "kubedb.dev/provider-aws/config/common" ) diff --git a/config/ec2/config.go b/config/ec2/config.go index 7e2a047..3b0b334 100644 --- a/config/ec2/config.go +++ b/config/ec2/config.go @@ -1,6 +1,6 @@ package ec2 -import "github.com/upbound/upjet/pkg/config" +import "github.com/crossplane/upjet/pkg/config" // Configure configures individual resources by adding custom ResourceConfigurators. func Configure(p *config.Provider) { diff --git a/config/elasticache/config.go b/config/elasticache/config.go index 33e730d..b6ad6e2 100644 --- a/config/elasticache/config.go +++ b/config/elasticache/config.go @@ -5,7 +5,7 @@ Copyright 2021 Upbound Inc. package elasticache import ( - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" ) // Configure adds configurations for elasticache group. diff --git a/config/external_name.go b/config/external_name.go index 4e64967..82328f5 100644 --- a/config/external_name.go +++ b/config/external_name.go @@ -7,8 +7,8 @@ package config import ( "context" "fmt" + "github.com/crossplane/upjet/pkg/config" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/config" "kubedb.dev/provider-aws/config/common" "strings" ) diff --git a/config/groups.go b/config/groups.go index c026637..0c250bf 100644 --- a/config/groups.go +++ b/config/groups.go @@ -1,7 +1,7 @@ package config import ( - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" ) var KindMap = map[string]string{ diff --git a/config/kafka/config.go b/config/kafka/config.go index b63feac..9db8ed8 100644 --- a/config/kafka/config.go +++ b/config/kafka/config.go @@ -1,7 +1,7 @@ package kafka import ( - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" "kubedb.dev/provider-aws/config/common" ) diff --git a/config/kinesis/config.go b/config/kinesis/config.go index 511b0da..b190b05 100644 --- a/config/kinesis/config.go +++ b/config/kinesis/config.go @@ -1,7 +1,7 @@ package kinesis import ( - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" ) // Configure adds configurations for kinesis group. diff --git a/config/memorydb/config.go b/config/memorydb/config.go index 7c88cd4..3afdc75 100644 --- a/config/memorydb/config.go +++ b/config/memorydb/config.go @@ -7,7 +7,7 @@ package memorydb import ( "fmt" - "github.com/upbound/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/config" ) // Configure adds configurations for memorydb group. diff --git a/config/overrides.go b/config/overrides.go index db7179e..272f325 100644 --- a/config/overrides.go +++ b/config/overrides.go @@ -1,11 +1,11 @@ package config import ( + "github.com/crossplane/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/types/comments" + "github.com/crossplane/upjet/pkg/types/name" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" "github.com/pkg/errors" - "github.com/upbound/upjet/pkg/config" - "github.com/upbound/upjet/pkg/types/comments" - "github.com/upbound/upjet/pkg/types/name" "strings" ) diff --git a/config/provider-metadata.yaml b/config/provider-metadata.yaml index 68acd97..0fa13df 100644 --- a/config/provider-metadata.yaml +++ b/config/provider-metadata.yaml @@ -33840,11 +33840,40 @@ resources: id: '- GuardDuty member detector ID' master_account_id: '- (Required) AWS account ID for primary account.' importStatements: [] - aws_guardduty_ipset': + aws_guardduty_ipset: subCategory: GuardDuty description: Provides a resource to manage a GuardDuty IPSet - name: aws_guardduty_ipset' + name: aws_guardduty_ipset title: aws_guardduty_ipset' + examples: + - name: example + manifest: |- + { + "activate": true, + "detector_id": "${aws_guardduty_detector.primary.id}", + "format": "TXT", + "location": "https://s3.amazonaws.com/${aws_s3_object.MyIPSet.bucket}/${aws_s3_object.MyIPSet.key}", + "name": "MyIPSet" + } + references: + detector_id: aws_guardduty_detector.primary.id + dependencies: + aws_guardduty_detector.primary: |- + { + "enable": true + } + aws_s3_bucket.bucket: '{}' + aws_s3_bucket_acl.bucket_acl: |- + { + "acl": "private", + "bucket": "${aws_s3_bucket.bucket.id}" + } + aws_s3_object.MyIPSet: |- + { + "bucket": "${aws_s3_bucket.bucket.id}", + "content": "10.0.0.0/8\n", + "key": "MyIPSet" + } argumentDocs: activate: '- (Required) Specifies whether GuardDuty is to start using the uploaded IPSet.' arn: '- Amazon Resource Name (ARN) of the GuardDuty IPSet.' @@ -33999,11 +34028,52 @@ resources: s3_logs: '- (Optional) Enable S3 Protection automatically for new member accounts.' s3_logs.auto_enable: '- (Optional) Set to true if you want S3 data event logs to be automatically enabled for new members of the organization. Default: false' importStatements: [] - aws_guardduty_publishing_destination': + aws_guardduty_publishing_destination: subCategory: GuardDuty description: Provides a resource to manage a GuardDuty PublishingDestination - name: aws_guardduty_publishing_destination' + name: aws_guardduty_publishing_destination title: aws_guardduty_publishing_destination' + examples: + - name: test + manifest: |- + { + "depends_on": [ + "${aws_s3_bucket_policy.gd_bucket_policy}" + ], + "destination_arn": "${aws_s3_bucket.gd_bucket.arn}", + "detector_id": "${aws_guardduty_detector.test_gd.id}", + "kms_key_arn": "${aws_kms_key.gd_key.arn}" + } + references: + destination_arn: aws_s3_bucket.gd_bucket.arn + detector_id: aws_guardduty_detector.test_gd.id + kms_key_arn: aws_kms_key.gd_key.arn + dependencies: + aws_guardduty_detector.test_gd: |- + { + "enable": true + } + aws_kms_key.gd_key: |- + { + "deletion_window_in_days": 7, + "description": "Temporary key for AccTest of TF", + "policy": "${data.aws_iam_policy_document.kms_pol.json}" + } + aws_s3_bucket.gd_bucket: |- + { + "bucket": "example", + "force_destroy": true + } + aws_s3_bucket_acl.gd_bucket_acl: |- + { + "acl": "private", + "bucket": "${aws_s3_bucket.gd_bucket.id}" + } + aws_s3_bucket_policy.gd_bucket_policy: |- + { + "bucket": "${aws_s3_bucket.gd_bucket.id}", + "policy": "${data.aws_iam_policy_document.bucket_pol.json}" + } argumentDocs: destination_arn: '- (Required) The bucket arn and prefix under which the findings get exported. Bucket-ARN is required, the prefix is optional and will be AWSLogs/[Account-ID]/GuardDuty/[Region]/ if not provided' destination_type: '- (Optional) Currently there is only "S3" available as destination type which is also the default value' @@ -34011,11 +34081,41 @@ resources: id: '- The ID of the GuardDuty PublishingDestination and the detector ID. Format: :' kms_key_arn: '- (Required) The ARN of the KMS key used to encrypt GuardDuty findings. GuardDuty enforces this to be encrypted.' importStatements: [] - aws_guardduty_threatintelset': + aws_guardduty_threatintelset: subCategory: GuardDuty description: Provides a resource to manage a GuardDuty ThreatIntelSet - name: aws_guardduty_threatintelset' + name: aws_guardduty_threatintelset title: aws_guardduty_threatintelset' + examples: + - name: MyThreatIntelSet + manifest: |- + { + "activate": true, + "detector_id": "${aws_guardduty_detector.primary.id}", + "format": "TXT", + "location": "https://s3.amazonaws.com/${aws_s3_object.MyThreatIntelSet.bucket}/${aws_s3_object.MyThreatIntelSet.key}", + "name": "MyThreatIntelSet" + } + references: + detector_id: aws_guardduty_detector.primary.id + dependencies: + aws_guardduty_detector.primary: |- + { + "enable": true + } + aws_s3_bucket.bucket: '{}' + aws_s3_bucket_acl.bucket_acl: |- + { + "acl": "private", + "bucket": "${aws_s3_bucket.bucket.id}" + } + aws_s3_object.MyThreatIntelSet: |- + { + "acl": "public-read", + "bucket": "${aws_s3_bucket.bucket.id}", + "content": "10.0.0.0/8\n", + "key": "MyThreatIntelSet" + } argumentDocs: activate: '- (Required) Specifies whether GuardDuty is to start using the uploaded ThreatIntelSet.' arn: '- Amazon Resource Name (ARN) of the GuardDuty ThreatIntelSet.' diff --git a/config/provider.go b/config/provider.go index 3def13b..6d2b7d7 100644 --- a/config/provider.go +++ b/config/provider.go @@ -7,8 +7,8 @@ package config import ( // Note(turkenh): we are importing this to embed provider schema document _ "embed" - ujconfig "github.com/upbound/upjet/pkg/config" - "github.com/upbound/upjet/pkg/registry/reference" + ujconfig "github.com/crossplane/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/registry/reference" "kubedb.dev/provider-aws/config/docdb" "kubedb.dev/provider-aws/config/dynamodb" "kubedb.dev/provider-aws/config/ec2" diff --git a/config/rds/config.go b/config/rds/config.go index ae272cf..0b1f562 100644 --- a/config/rds/config.go +++ b/config/rds/config.go @@ -20,8 +20,8 @@ import ( "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" - "github.com/upbound/upjet/pkg/config" - "github.com/upbound/upjet/pkg/types/comments" + "github.com/crossplane/upjet/pkg/config" + "github.com/crossplane/upjet/pkg/types/comments" "kubedb.dev/provider-aws/config/common" ) diff --git a/examples-generated/docdb/cluster.yaml b/examples-generated/docdb/cluster.yaml index abd0f12..d6d91aa 100644 --- a/examples-generated/docdb/cluster.yaml +++ b/examples-generated/docdb/cluster.yaml @@ -18,6 +18,3 @@ spec: preferredBackupWindow: 07:00-09:00 region: us-west-1 skipFinalSnapshot: true - ---- - diff --git a/examples-generated/docdb/clusterinstance.yaml b/examples-generated/docdb/clusterinstance.yaml index 7d28c98..c408b77 100644 --- a/examples-generated/docdb/clusterinstance.yaml +++ b/examples-generated/docdb/clusterinstance.yaml @@ -37,6 +37,3 @@ spec: namespace: upbound-system masterUsername: foo region: us-west-1 - ---- - diff --git a/examples-generated/docdb/clusterparametergroup.yaml b/examples-generated/docdb/clusterparametergroup.yaml index 7fffe27..7199d26 100644 --- a/examples-generated/docdb/clusterparametergroup.yaml +++ b/examples-generated/docdb/clusterparametergroup.yaml @@ -14,6 +14,3 @@ spec: - name: tls value: enabled region: us-west-1 - ---- - diff --git a/examples-generated/docdb/clustersnapshot.yaml b/examples-generated/docdb/clustersnapshot.yaml index b31a523..2b8f1e5 100644 --- a/examples-generated/docdb/clustersnapshot.yaml +++ b/examples-generated/docdb/clustersnapshot.yaml @@ -12,6 +12,3 @@ spec: matchLabels: testing.upbound.io/example-name: example region: us-west-1 - ---- - diff --git a/examples-generated/docdb/eventsubscription.yaml b/examples-generated/docdb/eventsubscription.yaml index 336262b..3748a49 100644 --- a/examples-generated/docdb/eventsubscription.yaml +++ b/examples-generated/docdb/eventsubscription.yaml @@ -41,6 +41,3 @@ spec: masterUsername: foo region: us-west-1 skipFinalSnapshot: true - ---- - diff --git a/examples-generated/docdb/globalcluster.yaml b/examples-generated/docdb/globalcluster.yaml index 423ef74..30fda54 100644 --- a/examples-generated/docdb/globalcluster.yaml +++ b/examples-generated/docdb/globalcluster.yaml @@ -95,6 +95,3 @@ spec: instanceClass: db.r5.large provider: ${aws.secondary} region: us-west-1 - ---- - diff --git a/examples-generated/docdb/subnetgroup.yaml b/examples-generated/docdb/subnetgroup.yaml index de0b362..e3c3c73 100644 --- a/examples-generated/docdb/subnetgroup.yaml +++ b/examples-generated/docdb/subnetgroup.yaml @@ -14,6 +14,3 @@ spec: - name: backend tags: Name: My docdb subnet group - ---- - diff --git a/examples-generated/dynamodb/contributorinsights.yaml b/examples-generated/dynamodb/contributorinsights.yaml index 47e4208..fcc875f 100644 --- a/examples-generated/dynamodb/contributorinsights.yaml +++ b/examples-generated/dynamodb/contributorinsights.yaml @@ -12,6 +12,3 @@ spec: tableNameSelector: matchLabels: testing.upbound.io/example-name: example - ---- - diff --git a/examples-generated/dynamodb/globaltable.yaml b/examples-generated/dynamodb/globaltable.yaml index 2a96b44..319c781 100644 --- a/examples-generated/dynamodb/globaltable.yaml +++ b/examples-generated/dynamodb/globaltable.yaml @@ -59,6 +59,3 @@ spec: streamEnabled: true streamViewType: NEW_AND_OLD_IMAGES writeCapacity: 1 - ---- - diff --git a/examples-generated/dynamodb/kinesisstreamingdestination.yaml b/examples-generated/dynamodb/kinesisstreamingdestination.yaml index 3e197a1..9fb1a9f 100644 --- a/examples-generated/dynamodb/kinesisstreamingdestination.yaml +++ b/examples-generated/dynamodb/kinesisstreamingdestination.yaml @@ -48,6 +48,3 @@ spec: forProvider: region: us-west-1 shardCount: 1 - ---- - diff --git a/examples-generated/dynamodb/table.yaml b/examples-generated/dynamodb/table.yaml index acf3289..8b78f10 100644 --- a/examples-generated/dynamodb/table.yaml +++ b/examples-generated/dynamodb/table.yaml @@ -36,6 +36,3 @@ spec: - attributeName: TimeToExist enabled: false writeCapacity: 20 - ---- - diff --git a/examples-generated/dynamodb/tableitem.yaml b/examples-generated/dynamodb/tableitem.yaml index 21d8e6c..c80532b 100644 --- a/examples-generated/dynamodb/tableitem.yaml +++ b/examples-generated/dynamodb/tableitem.yaml @@ -41,6 +41,3 @@ spec: readCapacity: 10 region: us-west-1 writeCapacity: 10 - ---- - diff --git a/examples-generated/dynamodb/tablereplica.yaml b/examples-generated/dynamodb/tablereplica.yaml index 20707d5..d096897 100644 --- a/examples-generated/dynamodb/tablereplica.yaml +++ b/examples-generated/dynamodb/tablereplica.yaml @@ -38,6 +38,3 @@ spec: region: us-west-1 streamEnabled: true streamViewType: NEW_AND_OLD_IMAGES - ---- - diff --git a/examples-generated/dynamodb/tag.yaml b/examples-generated/dynamodb/tag.yaml index d5730ab..5b6fe41 100644 --- a/examples-generated/dynamodb/tag.yaml +++ b/examples-generated/dynamodb/tag.yaml @@ -30,6 +30,3 @@ spec: region: us-west-1 replica: - regionName: ${data.aws_region.replica.name} - ---- - diff --git a/examples-generated/ec2/route.yaml b/examples-generated/ec2/route.yaml index 0727c89..71e8659 100644 --- a/examples-generated/ec2/route.yaml +++ b/examples-generated/ec2/route.yaml @@ -12,6 +12,3 @@ spec: region: us-west-1 routeTableId: rtb-4fbb3ac4 vpcPeeringConnectionId: pcx-45ff3dc1 - ---- - diff --git a/examples-generated/ec2/securitygroup.yaml b/examples-generated/ec2/securitygroup.yaml index d382d5d..d9383ee 100644 --- a/examples-generated/ec2/securitygroup.yaml +++ b/examples-generated/ec2/securitygroup.yaml @@ -33,6 +33,3 @@ spec: vpcIdSelector: matchLabels: testing.upbound.io/example-name: main - ---- - diff --git a/examples-generated/ec2/securitygrouprule.yaml b/examples-generated/ec2/securitygrouprule.yaml index a4cc034..a7c11f5 100644 --- a/examples-generated/ec2/securitygrouprule.yaml +++ b/examples-generated/ec2/securitygrouprule.yaml @@ -20,6 +20,3 @@ spec: testing.upbound.io/example-name: example toPort: 65535 type: ingress - ---- - diff --git a/examples-generated/ec2/subnet.yaml b/examples-generated/ec2/subnet.yaml index 1412561..6fff147 100644 --- a/examples-generated/ec2/subnet.yaml +++ b/examples-generated/ec2/subnet.yaml @@ -15,6 +15,3 @@ spec: vpcIdSelector: matchLabels: testing.upbound.io/example-name: main - ---- - diff --git a/examples-generated/ec2/vpc.yaml b/examples-generated/ec2/vpc.yaml index ab7d49b..2cbafbc 100644 --- a/examples-generated/ec2/vpc.yaml +++ b/examples-generated/ec2/vpc.yaml @@ -10,6 +10,3 @@ spec: forProvider: cidrBlock: 10.0.0.0/16 region: us-west-1 - ---- - diff --git a/examples-generated/ec2/vpcendpoint.yaml b/examples-generated/ec2/vpcendpoint.yaml index e906fd1..f002bf9 100644 --- a/examples-generated/ec2/vpcendpoint.yaml +++ b/examples-generated/ec2/vpcendpoint.yaml @@ -13,6 +13,3 @@ spec: vpcIdSelector: matchLabels: testing.upbound.io/example-name: main - ---- - diff --git a/examples-generated/ec2/vpcpeeringconnection.yaml b/examples-generated/ec2/vpcpeeringconnection.yaml index f09e9fa..a3c3970 100644 --- a/examples-generated/ec2/vpcpeeringconnection.yaml +++ b/examples-generated/ec2/vpcpeeringconnection.yaml @@ -16,6 +16,3 @@ spec: vpcIdSelector: matchLabels: testing.upbound.io/example-name: foo - ---- - diff --git a/examples-generated/elasticache/cluster.yaml b/examples-generated/elasticache/cluster.yaml index 3afa440..9787bb4 100644 --- a/examples-generated/elasticache/cluster.yaml +++ b/examples-generated/elasticache/cluster.yaml @@ -16,6 +16,3 @@ spec: testing.upbound.io/example-name: example port: 11211 region: us-west-1 - ---- - diff --git a/examples-generated/elasticache/parametergroup.yaml b/examples-generated/elasticache/parametergroup.yaml index 6a59206..243d3ca 100644 --- a/examples-generated/elasticache/parametergroup.yaml +++ b/examples-generated/elasticache/parametergroup.yaml @@ -16,6 +16,3 @@ spec: - name: min-slaves-to-write value: "2" region: us-west-1 - ---- - diff --git a/examples-generated/elasticache/replicationgroup.yaml b/examples-generated/elasticache/replicationgroup.yaml index 129c097..21ab3b1 100644 --- a/examples-generated/elasticache/replicationgroup.yaml +++ b/examples-generated/elasticache/replicationgroup.yaml @@ -18,6 +18,3 @@ spec: - us-west-2a - us-west-2b region: us-west-1 - ---- - diff --git a/examples-generated/elasticache/subnetgroup.yaml b/examples-generated/elasticache/subnetgroup.yaml index a4b3af9..f5493da 100644 --- a/examples-generated/elasticache/subnetgroup.yaml +++ b/examples-generated/elasticache/subnetgroup.yaml @@ -49,6 +49,3 @@ spec: region: us-west-1 tags: Name: tf-test - ---- - diff --git a/examples-generated/elasticache/user.yaml b/examples-generated/elasticache/user.yaml index 500784c..d48fb8b 100644 --- a/examples-generated/elasticache/user.yaml +++ b/examples-generated/elasticache/user.yaml @@ -18,6 +18,3 @@ spec: namespace: upbound-system region: us-west-1 userName: testUserName - ---- - diff --git a/examples-generated/elasticache/usergroup.yaml b/examples-generated/elasticache/usergroup.yaml index ca5fe0d..a973f76 100644 --- a/examples-generated/elasticache/usergroup.yaml +++ b/examples-generated/elasticache/usergroup.yaml @@ -35,6 +35,3 @@ spec: namespace: upbound-system region: us-west-1 userName: default - ---- - diff --git a/examples-generated/elasticsearch/domain.yaml b/examples-generated/elasticsearch/domain.yaml index 118f56d..829a579 100644 --- a/examples-generated/elasticsearch/domain.yaml +++ b/examples-generated/elasticsearch/domain.yaml @@ -14,6 +14,3 @@ spec: region: us-west-1 tags: Domain: TestDomain - ---- - diff --git a/examples-generated/elasticsearch/domainpolicy.yaml b/examples-generated/elasticsearch/domainpolicy.yaml index f1cf71e..0da4d2d 100644 --- a/examples-generated/elasticsearch/domainpolicy.yaml +++ b/examples-generated/elasticsearch/domainpolicy.yaml @@ -42,6 +42,3 @@ spec: forProvider: elasticsearchVersion: "2.3" region: us-west-1 - ---- - diff --git a/examples-generated/elasticsearch/domainsamloptions.yaml b/examples-generated/elasticsearch/domainsamloptions.yaml index 5472537..8756786 100644 --- a/examples-generated/elasticsearch/domainsamloptions.yaml +++ b/examples-generated/elasticsearch/domainsamloptions.yaml @@ -35,6 +35,3 @@ spec: - automatedSnapshotStartHour: 23 tags: Domain: TestDomain - ---- - diff --git a/examples-generated/kafka/cluster.yaml b/examples-generated/kafka/cluster.yaml index 664d286..007a338 100644 --- a/examples-generated/kafka/cluster.yaml +++ b/examples-generated/kafka/cluster.yaml @@ -151,6 +151,3 @@ spec: forProvider: cidrBlock: 192.168.0.0/22 region: us-west-1 - ---- - diff --git a/examples-generated/kafka/configuration.yaml b/examples-generated/kafka/configuration.yaml index e4d745d..00a30a0 100644 --- a/examples-generated/kafka/configuration.yaml +++ b/examples-generated/kafka/configuration.yaml @@ -15,6 +15,3 @@ spec: serverProperties: | auto.create.topics.enable = true delete.topic.enable = true - ---- - diff --git a/examples-generated/kinesis/stream.yaml b/examples-generated/kinesis/stream.yaml index febfa4b..25db4df 100644 --- a/examples-generated/kinesis/stream.yaml +++ b/examples-generated/kinesis/stream.yaml @@ -18,6 +18,3 @@ spec: - streamMode: PROVISIONED tags: Environment: test - ---- - diff --git a/examples-generated/kms/key.yaml b/examples-generated/kms/key.yaml index 5f5cd7a..37d0885 100644 --- a/examples-generated/kms/key.yaml +++ b/examples-generated/kms/key.yaml @@ -11,6 +11,3 @@ spec: deletionWindowInDays: 10 description: KMS key 1 region: us-west-1 - ---- - diff --git a/examples-generated/memorydb/acl.yaml b/examples-generated/memorydb/acl.yaml index c3effb0..8ab4401 100644 --- a/examples-generated/memorydb/acl.yaml +++ b/examples-generated/memorydb/acl.yaml @@ -12,6 +12,3 @@ spec: userNames: - my-user-1 - my-user-2 - ---- - diff --git a/examples-generated/memorydb/cluster.yaml b/examples-generated/memorydb/cluster.yaml index 40fd699..357a032 100644 --- a/examples-generated/memorydb/cluster.yaml +++ b/examples-generated/memorydb/cluster.yaml @@ -18,6 +18,3 @@ spec: subnetGroupNameSelector: matchLabels: testing.upbound.io/example-name: example - ---- - diff --git a/examples-generated/memorydb/parametergroup.yaml b/examples-generated/memorydb/parametergroup.yaml index 8e5b9e1..b240bb1 100644 --- a/examples-generated/memorydb/parametergroup.yaml +++ b/examples-generated/memorydb/parametergroup.yaml @@ -13,6 +13,3 @@ spec: - name: activedefrag value: "yes" region: us-west-1 - ---- - diff --git a/examples-generated/memorydb/snapshot.yaml b/examples-generated/memorydb/snapshot.yaml index d83e3db..d37635c 100644 --- a/examples-generated/memorydb/snapshot.yaml +++ b/examples-generated/memorydb/snapshot.yaml @@ -12,6 +12,3 @@ spec: matchLabels: testing.upbound.io/example-name: example region: us-west-1 - ---- - diff --git a/examples-generated/memorydb/subnetgroup.yaml b/examples-generated/memorydb/subnetgroup.yaml index ceb3abc..40b354b 100644 --- a/examples-generated/memorydb/subnetgroup.yaml +++ b/examples-generated/memorydb/subnetgroup.yaml @@ -45,6 +45,3 @@ spec: forProvider: cidrBlock: 10.0.0.0/16 region: us-west-1 - ---- - diff --git a/examples-generated/rds/cluster.yaml b/examples-generated/rds/cluster.yaml index 7c39a3b..37c3836 100644 --- a/examples-generated/rds/cluster.yaml +++ b/examples-generated/rds/cluster.yaml @@ -23,6 +23,3 @@ spec: masterUsername: foo preferredBackupWindow: 07:00-09:00 region: us-west-1 - ---- - diff --git a/examples-generated/rds/clusteractivitystream.yaml b/examples-generated/rds/clusteractivitystream.yaml index b868600..4560f4a 100644 --- a/examples-generated/rds/clusteractivitystream.yaml +++ b/examples-generated/rds/clusteractivitystream.yaml @@ -76,6 +76,3 @@ spec: engine: aurora-postgresql instanceClass: db.r6g.large region: us-west-1 - ---- - diff --git a/examples-generated/rds/clusterendpoint.yaml b/examples-generated/rds/clusterendpoint.yaml index 6dd44e3..c3ff357 100644 --- a/examples-generated/rds/clusterendpoint.yaml +++ b/examples-generated/rds/clusterendpoint.yaml @@ -105,6 +105,3 @@ spec: engineVersion: ${aws_rds_cluster.default.engine_version} instanceClass: db.t2.small region: us-west-1 - ---- - diff --git a/examples-generated/rds/clusterinstance.yaml b/examples-generated/rds/clusterinstance.yaml index aee67e6..ee48014 100644 --- a/examples-generated/rds/clusterinstance.yaml +++ b/examples-generated/rds/clusterinstance.yaml @@ -40,6 +40,3 @@ spec: namespace: upbound-system masterUsername: foo region: us-west-1 - ---- - diff --git a/examples-generated/rds/clusterparametergroup.yaml b/examples-generated/rds/clusterparametergroup.yaml index a2c13ba..ed19d68 100644 --- a/examples-generated/rds/clusterparametergroup.yaml +++ b/examples-generated/rds/clusterparametergroup.yaml @@ -16,6 +16,3 @@ spec: - name: character_set_client value: utf8 region: us-west-1 - ---- - diff --git a/examples-generated/rds/clusterroleassociation.yaml b/examples-generated/rds/clusterroleassociation.yaml index e045b3f..1a09794 100644 --- a/examples-generated/rds/clusterroleassociation.yaml +++ b/examples-generated/rds/clusterroleassociation.yaml @@ -14,6 +14,3 @@ spec: featureName: S3_INTEGRATION region: us-west-1 roleArn: ${aws_iam_role.example.arn} - ---- - diff --git a/examples-generated/rds/clustersnapshot.yaml b/examples-generated/rds/clustersnapshot.yaml index 9c53b6b..93ef57b 100644 --- a/examples-generated/rds/clustersnapshot.yaml +++ b/examples-generated/rds/clustersnapshot.yaml @@ -13,6 +13,3 @@ spec: testing.upbound.io/example-name: example dbClusterSnapshotIdentifier: resourcetestsnapshot1234 region: us-west-1 - ---- - diff --git a/examples-generated/rds/dbinstanceautomatedbackupsreplication.yaml b/examples-generated/rds/dbinstanceautomatedbackupsreplication.yaml index 65dcbb1..ddc63b7 100644 --- a/examples-generated/rds/dbinstanceautomatedbackupsreplication.yaml +++ b/examples-generated/rds/dbinstanceautomatedbackupsreplication.yaml @@ -13,6 +13,3 @@ spec: sourceDbInstanceArnSelector: matchLabels: testing.upbound.io/example-name: example - ---- - diff --git a/examples-generated/rds/dbsnapshotcopy.yaml b/examples-generated/rds/dbsnapshotcopy.yaml index 9da75b5..6bde48d 100644 --- a/examples-generated/rds/dbsnapshotcopy.yaml +++ b/examples-generated/rds/dbsnapshotcopy.yaml @@ -57,6 +57,3 @@ spec: matchLabels: testing.upbound.io/example-name: example region: us-west-1 - ---- - diff --git a/examples-generated/rds/eventsubscription.yaml b/examples-generated/rds/eventsubscription.yaml index f4519a1..9ddf814 100644 --- a/examples-generated/rds/eventsubscription.yaml +++ b/examples-generated/rds/eventsubscription.yaml @@ -52,6 +52,3 @@ spec: namespace: upbound-system region: us-west-1 username: foo - ---- - diff --git a/examples-generated/rds/globalcluster.yaml b/examples-generated/rds/globalcluster.yaml index 2813a27..8f27546 100644 --- a/examples-generated/rds/globalcluster.yaml +++ b/examples-generated/rds/globalcluster.yaml @@ -108,6 +108,3 @@ spec: instanceClass: db.r4.large provider: ${aws.secondary} region: us-west-1 - ---- - diff --git a/examples-generated/rds/instance.yaml b/examples-generated/rds/instance.yaml index 3c0c790..097bf33 100644 --- a/examples-generated/rds/instance.yaml +++ b/examples-generated/rds/instance.yaml @@ -21,6 +21,3 @@ spec: region: us-west-1 skipFinalSnapshot: true username: foo - ---- - diff --git a/examples-generated/rds/instanceroleassociation.yaml b/examples-generated/rds/instanceroleassociation.yaml index 6cbf7cb..a9d9044 100644 --- a/examples-generated/rds/instanceroleassociation.yaml +++ b/examples-generated/rds/instanceroleassociation.yaml @@ -14,6 +14,3 @@ spec: featureName: S3_INTEGRATION region: us-west-1 roleArn: ${aws_iam_role.example.arn} - ---- - diff --git a/examples-generated/rds/optiongroup.yaml b/examples-generated/rds/optiongroup.yaml index ffa8a15..a84f23e 100644 --- a/examples-generated/rds/optiongroup.yaml +++ b/examples-generated/rds/optiongroup.yaml @@ -22,6 +22,3 @@ spec: - optionName: TDE optionGroupDescription: Terraform Option Group region: us-west-1 - ---- - diff --git a/examples-generated/rds/parametergroup.yaml b/examples-generated/rds/parametergroup.yaml index b1cc577..fa5a8c2 100644 --- a/examples-generated/rds/parametergroup.yaml +++ b/examples-generated/rds/parametergroup.yaml @@ -15,6 +15,3 @@ spec: - name: character_set_client value: utf8 region: us-west-1 - ---- - diff --git a/examples-generated/rds/proxy.yaml b/examples-generated/rds/proxy.yaml index 6739f08..ebb6f3a 100644 --- a/examples-generated/rds/proxy.yaml +++ b/examples-generated/rds/proxy.yaml @@ -26,6 +26,3 @@ spec: - name: example vpcSubnetIds: - ${aws_subnet.example.id} - ---- - diff --git a/examples-generated/rds/proxydefaulttargetgroup.yaml b/examples-generated/rds/proxydefaulttargetgroup.yaml index 00758bb..edc8920 100644 --- a/examples-generated/rds/proxydefaulttargetgroup.yaml +++ b/examples-generated/rds/proxydefaulttargetgroup.yaml @@ -50,6 +50,3 @@ spec: - name: example vpcSubnetIds: - ${aws_subnet.example.id} - ---- - diff --git a/examples-generated/rds/proxyendpoint.yaml b/examples-generated/rds/proxyendpoint.yaml index a78e20a..83ea12e 100644 --- a/examples-generated/rds/proxyendpoint.yaml +++ b/examples-generated/rds/proxyendpoint.yaml @@ -14,6 +14,3 @@ spec: region: us-west-1 targetRole: READ_ONLY vpcSubnetIds: ${aws_subnet.test[*].id} - ---- - diff --git a/examples-generated/rds/proxytarget.yaml b/examples-generated/rds/proxytarget.yaml index e427e03..588d9a7 100644 --- a/examples-generated/rds/proxytarget.yaml +++ b/examples-generated/rds/proxytarget.yaml @@ -71,6 +71,3 @@ spec: matchLabels: testing.upbound.io/example-name: example region: us-west-1 - ---- - diff --git a/examples-generated/rds/snapshot.yaml b/examples-generated/rds/snapshot.yaml index 7a04041..2fb6cc3 100644 --- a/examples-generated/rds/snapshot.yaml +++ b/examples-generated/rds/snapshot.yaml @@ -39,6 +39,3 @@ spec: namespace: upbound-system region: us-west-1 username: foo - ---- - diff --git a/examples-generated/rds/subnetgroup.yaml b/examples-generated/rds/subnetgroup.yaml index d9039a6..9058cf1 100644 --- a/examples-generated/rds/subnetgroup.yaml +++ b/examples-generated/rds/subnetgroup.yaml @@ -14,6 +14,3 @@ spec: - name: backend tags: Name: My DB subnet group - ---- - diff --git a/go.mod b/go.mod index be297ef..6dcd62f 100644 --- a/go.mod +++ b/go.mod @@ -1,19 +1,20 @@ module kubedb.dev/provider-aws -go 1.19 +go 1.20 require ( - github.com/crossplane/crossplane-runtime v0.20.0-rc.0.0.20230406155702-4e1673b7141f - github.com/crossplane/crossplane-tools v0.0.0-20230327091744-4236bf732aa5 + dario.cat/mergo v1.0.0 + github.com/crossplane/crossplane-runtime v1.14.0-rc.0.0.20231011070344-cc691421c2e5 + github.com/crossplane/crossplane-tools v0.0.0-20230925130601-628280f8bf79 + github.com/crossplane/upjet v1.0.0 github.com/hashicorp/terraform-plugin-sdk/v2 v2.24.0 github.com/pkg/errors v0.9.1 - github.com/upbound/upjet v0.9.0-rc.0.0.20230502154751-645d7260d814 gopkg.in/alecthomas/kingpin.v2 v2.2.6 - k8s.io/api v0.26.3 - k8s.io/apimachinery v0.26.3 - k8s.io/client-go v0.26.3 - sigs.k8s.io/controller-runtime v0.14.6 - sigs.k8s.io/controller-tools v0.11.3 + k8s.io/api v0.28.2 + k8s.io/apimachinery v0.28.2 + k8s.io/client-go v0.28.2 + sigs.k8s.io/controller-runtime v0.16.2 + sigs.k8s.io/controller-tools v0.13.0 ) require ( @@ -23,69 +24,50 @@ require ( github.com/antchfx/htmlquery v1.2.4 // indirect github.com/antchfx/xpath v1.2.0 // indirect github.com/apparentlymart/go-textseg/v13 v13.0.0 // indirect - github.com/armon/go-metrics v0.3.9 // indirect - github.com/armon/go-radix v1.0.0 // indirect github.com/beorn7/perks v1.0.1 // indirect - github.com/cenkalti/backoff/v3 v3.0.0 // indirect - github.com/cespare/xxhash/v2 v2.1.2 // indirect + github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/dave/jennifer v1.4.1 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/emicklei/go-restful/v3 v3.9.0 // indirect + github.com/emicklei/go-restful/v3 v3.10.2 // indirect github.com/evanphx/json-patch/v5 v5.6.0 // indirect github.com/fatih/camelcase v1.0.0 // indirect - github.com/fatih/color v1.13.0 // indirect + github.com/fatih/color v1.15.0 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect - github.com/go-logr/logr v1.2.3 // indirect - github.com/go-logr/zapr v1.2.3 // indirect - github.com/go-openapi/jsonpointer v0.19.5 // indirect - github.com/go-openapi/jsonreference v0.20.0 // indirect - github.com/go-openapi/swag v0.21.1 // indirect - github.com/gobuffalo/flect v0.3.0 // indirect + github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/zapr v1.2.4 // indirect + github.com/go-openapi/jsonpointer v0.19.6 // indirect + github.com/go-openapi/jsonreference v0.20.2 // indirect + github.com/go-openapi/swag v0.22.3 // indirect + github.com/gobuffalo/flect v1.0.2 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/mock v1.6.0 // indirect - github.com/golang/protobuf v1.5.2 // indirect - github.com/golang/snappy v0.0.4 // indirect - github.com/google/gnostic v0.6.9 // indirect - github.com/google/go-cmp v0.5.9 // indirect + github.com/golang/protobuf v1.5.3 // indirect + github.com/google/gnostic-models v0.6.8 // indirect + github.com/google/go-cmp v0.6.0 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/uuid v1.3.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect - github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 // indirect github.com/hashicorp/go-hclog v1.2.1 // indirect - github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect - github.com/hashicorp/go-plugin v1.4.4 // indirect - github.com/hashicorp/go-retryablehttp v0.7.1 // indirect - github.com/hashicorp/go-rootcerts v1.0.2 // indirect - github.com/hashicorp/go-secure-stdlib/mlock v0.1.1 // indirect - github.com/hashicorp/go-secure-stdlib/parseutil v0.1.1 // indirect - github.com/hashicorp/go-secure-stdlib/strutil v0.1.1 // indirect - github.com/hashicorp/go-sockaddr v1.0.2 // indirect github.com/hashicorp/go-uuid v1.0.3 // indirect github.com/hashicorp/go-version v1.6.0 // indirect - github.com/hashicorp/golang-lru v0.5.4 // indirect - github.com/hashicorp/hcl v1.0.0 // indirect github.com/hashicorp/hcl/v2 v2.14.1 // indirect github.com/hashicorp/logutils v1.0.0 // indirect github.com/hashicorp/terraform-json v0.14.0 // indirect github.com/hashicorp/terraform-plugin-go v0.14.0 // indirect github.com/hashicorp/terraform-plugin-log v0.7.0 // indirect - github.com/hashicorp/vault/api v1.5.0 // indirect - github.com/hashicorp/vault/sdk v0.4.1 // indirect - github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d // indirect github.com/iancoleman/strcase v0.2.0 // indirect - github.com/imdario/mergo v0.3.12 // indirect - github.com/inconshreveable/mousetrap v1.0.1 // indirect + github.com/imdario/mergo v0.3.16 // indirect + github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/mailru/easyjson v0.7.7 // indirect - github.com/mattn/go-colorable v0.1.12 // indirect - github.com/mattn/go-isatty v0.0.16 // indirect + github.com/mattn/go-colorable v0.1.13 // indirect + github.com/mattn/go-isatty v0.0.17 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect github.com/mitchellh/copystructure v1.2.0 // indirect - github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-ps v1.0.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/go-wordwrap v1.0.1 // indirect @@ -95,15 +77,12 @@ require ( github.com/modern-go/reflect2 v1.0.2 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/muvaf/typewriter v0.0.0-20220131201631-921e94e8e8d7 // indirect - github.com/oklog/run v1.0.0 // indirect - github.com/pierrec/lz4 v2.5.2+incompatible // indirect - github.com/prometheus/client_golang v1.14.0 // indirect - github.com/prometheus/client_model v0.3.0 // indirect - github.com/prometheus/common v0.37.0 // indirect - github.com/prometheus/procfs v0.8.0 // indirect - github.com/ryanuber/go-glob v1.0.0 // indirect - github.com/spf13/afero v1.9.2 // indirect - github.com/spf13/cobra v1.6.1 // indirect + github.com/prometheus/client_golang v1.16.0 // indirect + github.com/prometheus/client_model v0.4.0 // indirect + github.com/prometheus/common v0.44.0 // indirect + github.com/prometheus/procfs v0.10.1 // indirect + github.com/spf13/afero v1.10.0 // indirect + github.com/spf13/cobra v1.7.0 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/tmccombs/hcl2json v0.3.3 // indirect github.com/vmihailenco/msgpack v4.0.4+incompatible // indirect @@ -111,33 +90,32 @@ require ( github.com/vmihailenco/tagparser v0.1.1 // indirect github.com/yuin/goldmark v1.4.13 // indirect github.com/zclconf/go-cty v1.11.0 // indirect - go.uber.org/atomic v1.10.0 // indirect - go.uber.org/multierr v1.8.0 // indirect - go.uber.org/zap v1.24.0 // indirect - golang.org/x/crypto v0.2.0 // indirect - golang.org/x/mod v0.7.0 // indirect - golang.org/x/net v0.7.0 // indirect - golang.org/x/oauth2 v0.1.0 // indirect - golang.org/x/sys v0.5.0 // indirect - golang.org/x/term v0.5.0 // indirect - golang.org/x/text v0.7.0 // indirect + github.com/zclconf/go-cty-yaml v1.0.3 // indirect + go.uber.org/multierr v1.11.0 // indirect + go.uber.org/zap v1.26.0 // indirect + golang.org/x/exp v0.0.0-20230905200255-921286631fa9 // indirect + golang.org/x/mod v0.12.0 // indirect + golang.org/x/net v0.15.0 // indirect + golang.org/x/oauth2 v0.10.0 // indirect + golang.org/x/sys v0.12.0 // indirect + golang.org/x/term v0.12.0 // indirect + golang.org/x/text v0.13.0 // indirect golang.org/x/time v0.3.0 // indirect - golang.org/x/tools v0.4.0 // indirect - gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect + golang.org/x/tools v0.13.0 // indirect + gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20221202195650-67e5cbc046fd // indirect - google.golang.org/grpc v1.50.1 // indirect - google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect + google.golang.org/grpc v1.58.3 // indirect + google.golang.org/protobuf v1.31.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect - gopkg.in/square/go-jose.v2 v2.5.1 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/apiextensions-apiserver v0.26.3 // indirect - k8s.io/component-base v0.26.3 // indirect - k8s.io/klog/v2 v2.80.1 // indirect - k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 // indirect - k8s.io/utils v0.0.0-20230313181309-38a27ef9d749 // indirect - sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect + k8s.io/apiextensions-apiserver v0.28.2 // indirect + k8s.io/component-base v0.28.2 // indirect + k8s.io/klog/v2 v2.100.1 // indirect + k8s.io/kube-openapi v0.0.0-20230717233707-2695361300d9 // indirect + k8s.io/utils v0.0.0-20230726121419-3b25d923346b // indirect + sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect sigs.k8s.io/yaml v1.3.0 // indirect ) diff --git a/go.sum b/go.sum index 3ae95e9..df44162 100644 --- a/go.sum +++ b/go.sum @@ -35,141 +35,93 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= +dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= +dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/agext/levenshtein v1.2.1/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki2W0IB5558= github.com/agext/levenshtein v1.2.3 h1:YB2fHEn0UJagG8T1rrWknE3ZQzWM06O8AMAatNn7lmo= github.com/agext/levenshtein v1.2.3/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki2W0IB5558= github.com/alecthomas/kong v0.2.16/go.mod h1:kQOmtJgV+Lb4aj+I2LEn40cbtawdWJ9Y8QLq+lElKxE= -github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 h1:s6gZFSlWYmbqAuRjVTiNNhvNRfY2Wxp9nhfyel4rklc= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= github.com/antchfx/htmlquery v1.2.4 h1:qLteofCMe/KGovBI6SQgmou2QNyedFUW+pE+BpeZ494= github.com/antchfx/htmlquery v1.2.4/go.mod h1:2xO6iu3EVWs7R2JYqBbp8YzG50gj/ofqs5/0VZoDZLc= github.com/antchfx/xpath v1.2.0 h1:mbwv7co+x0RwgeGAOHdrKy89GvHaGvxxBtPK0uF9Zr8= github.com/antchfx/xpath v1.2.0/go.mod h1:i54GszH55fYfBmoZXapTHN8T8tkcHfRgLyVwwqzXNcs= -github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/apparentlymart/go-dump v0.0.0-20180507223929-23540a00eaa3/go.mod h1:oL81AME2rN47vu18xqj1S1jPIPuN7afo62yKTNn3XMM= github.com/apparentlymart/go-dump v0.0.0-20190214190832-042adf3cf4a0 h1:MzVXffFUye+ZcSR6opIgz9Co7WcDx6ZcY+RjfFHoA0I= github.com/apparentlymart/go-textseg v1.0.0/go.mod h1:z96Txxhf3xSFMPmb5X/1W05FF/Nj9VFpLOpjS5yuumk= github.com/apparentlymart/go-textseg/v12 v12.0.0/go.mod h1:S/4uRK2UtaQttw1GenVJEynmyUenKwP++x/+DdGV/Ec= github.com/apparentlymart/go-textseg/v13 v13.0.0 h1:Y+KvPE1NYz0xl601PVImeQfFyEy6iT90AvPUL1NNfNw= github.com/apparentlymart/go-textseg/v13 v13.0.0/go.mod h1:ZK2fH7c4NqDTLtiYLvIkEghdlcqw7yxLeM89kiTRPUo= -github.com/armon/go-metrics v0.3.9 h1:O2sNqxBdvq8Eq5xmzljcYzAORli6RWCvEym4cJf9m18= -github.com/armon/go-metrics v0.3.9/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc= -github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= -github.com/armon/go-radix v1.0.0 h1:F4z6KzEeeQIMeLFa97iZU6vupzoecKdU5TX24SNppXI= -github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= -github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= -github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= -github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= -github.com/cenkalti/backoff/v3 v3.0.0 h1:ske+9nBpD9qZsTBoF41nW5L+AIuFBKMeze18XQ3eG1c= -github.com/cenkalti/backoff/v3 v3.0.0/go.mod h1:cIeZDE3IrqwwJl6VUwCN6trj1oXrTS4rc0ij+ULvLYs= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= -github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE= -github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= +github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= -github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/crossplane/crossplane-runtime v0.20.0-rc.0.0.20230406155702-4e1673b7141f h1:wDRr6gaoiQstEdddrn0B5SSSgzdXreOQAbdmRH+9JeI= -github.com/crossplane/crossplane-runtime v0.20.0-rc.0.0.20230406155702-4e1673b7141f/go.mod h1:ebtUpmconMy8RKUEhrCXTUFSOpfGQqbKM2E+rjCCYJo= -github.com/crossplane/crossplane-tools v0.0.0-20230327091744-4236bf732aa5 h1:K9H55wcwfXcGroZApIgPmIGRGuZLszsLDCYB12p2yMo= -github.com/crossplane/crossplane-tools v0.0.0-20230327091744-4236bf732aa5/go.mod h1:+e4OaFlOcmr0JvINHl/yvEYBrZawzTgj6pQumOH1SS0= +github.com/crossplane/crossplane-runtime v1.14.0-rc.0.0.20231011070344-cc691421c2e5 h1:K1Km6NCu9+VlZB3CmWSjrs09cDSbwQxJd2Qw2002dFs= +github.com/crossplane/crossplane-runtime v1.14.0-rc.0.0.20231011070344-cc691421c2e5/go.mod h1:kCS5576be8g++HhiDGEBUw+8nkW8p4jhURYeC0zx8jM= +github.com/crossplane/crossplane-tools v0.0.0-20230925130601-628280f8bf79 h1:HigXs5tEQxWz0fcj8hzbU2UAZgEM7wPe0XRFOsrtF8Y= +github.com/crossplane/crossplane-tools v0.0.0-20230925130601-628280f8bf79/go.mod h1:+e4OaFlOcmr0JvINHl/yvEYBrZawzTgj6pQumOH1SS0= +github.com/crossplane/upjet v1.0.0 h1:/R509m+c5XTLsd9oXTEaLj2yIbM/EUmG34XOou1dugM= +github.com/crossplane/upjet v1.0.0/go.mod h1:t9etxIdYaxgyvFPBToikm5zBHi8RIpX8N4mTH77lQFM= github.com/dave/jennifer v1.4.1 h1:XyqG6cn5RQsTj3qlWQTKlRGAyrTcsk1kUmWdZBzRjDw= github.com/dave/jennifer v1.4.1/go.mod h1:7jEdnm+qBcxl8PC0zyp7vxcpSRnzXSt9r39tpTVGlwA= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= -github.com/emicklei/go-restful/v3 v3.9.0 h1:XwGDlfxEnQZzuopoqxwSEllNcCOM9DhhFyhFIIGKwxE= -github.com/emicklei/go-restful/v3 v3.9.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/emicklei/go-restful/v3 v3.10.2 h1:hIovbnmBTLjHXkqEBUz3HGpXZdM7ZrE9fJIZIqlJLqE= +github.com/emicklei/go-restful/v3 v3.10.2/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= -github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/evanphx/json-patch v0.5.2/go.mod h1:ZWS5hhDbVDyob71nXKNL0+PWn6ToqBHMikGIFbs31qQ= -github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84= -github.com/evanphx/json-patch/v5 v5.5.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4= +github.com/evanphx/json-patch v5.6.0+incompatible h1:jBYDEEiFBPxA0v50tFdvOzQQTCvpL6mnFh5mB2/l16U= github.com/evanphx/json-patch/v5 v5.6.0 h1:b91NhWfaz02IuVxO9faSllyAtNXHMPkC5J8sJCLunww= github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4= github.com/fatih/camelcase v1.0.0 h1:hxNvNX/xYBp0ovncs8WyWZrOrpBNub/JfaMvbURyft8= github.com/fatih/camelcase v1.0.0/go.mod h1:yN2Sb0lFhZJUdVvtELVWefmrXpuZESvPmqwoZc+/fpc= -github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= -github.com/fatih/structs v1.1.0 h1:Q7juDM0QtcnhCpeyLGQKyg4TOIghuNXrkL32pHAUMxo= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= -github.com/flowstack/go-jsonschema v0.1.1/go.mod h1:yL7fNggx1o8rm9RlgXv7hTBWxdBM0rVwpMwimd3F3N0= -github.com/frankban/quicktest v1.10.0/go.mod h1:ui7WezCLWMWxVWr1GETZY3smRy0G4KWq9vcPtJmFl7Y= -github.com/frankban/quicktest v1.13.0 h1:yNZif1OkDfNoDfb9zZa9aXIpejNR4F23Wely0c+Qdqk= -github.com/frankban/quicktest v1.13.0/go.mod h1:qLE0fzW0VuyUAJgPU19zByoIr0HtCHN/r/VLSOOIySU= +github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= +github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= -github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/go-asn1-ber/asn1-ber v1.3.1/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= -github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= -github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= -github.com/go-ldap/ldap/v3 v3.1.10/go.mod h1:5Zun81jBTabRaI8lzN7E1JjyEl1g6zI6u9pd8luAK4Q= -github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= -github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= -github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.2.3 h1:2DntVwHkVopvECVRSlL5PSo9eG+cAkDCuckLubN+rq0= -github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/zapr v1.2.3 h1:a9vnzlIBPQBBkeaR9IuMUfmVOrQlkoC4YfPoFkX3T7A= -github.com/go-logr/zapr v1.2.3/go.mod h1:eIauM6P8qSvTw5o2ez6UEAfGjQKrxQTl5EoK+Qa2oG4= -github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonreference v0.20.0 h1:MYlu0sBgChmCfJxxUKZ8g1cPWFOB37YSZqewK7OKeyA= -github.com/go-openapi/jsonreference v0.20.0/go.mod h1:Ag74Ico3lPc+zR+qjn4XBUmXymS4zJbYVCZmcgkasdo= -github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= -github.com/go-openapi/swag v0.21.1 h1:wm0rhTb5z7qpJRHBdPOMuY4QjVUMbF6/kwoYeRAOrKU= -github.com/go-openapi/swag v0.21.1/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= -github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/go-test/deep v1.0.2/go.mod h1:wGDj63lr65AM2AQyKZd/NYHGb0R+1RLqB8NKt3aSFNA= +github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= +github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/zapr v1.2.4 h1:QHVo+6stLbfJmYGkQ7uGHUCu5hnAFAj6mDe6Ea0SeOo= +github.com/go-logr/zapr v1.2.4/go.mod h1:FyHWQIzQORZ0QVE1BtVHv3cKtNLuXsbNLtpuhNapBOA= +github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE= +github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs= +github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE= +github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= +github.com/go-openapi/swag v0.22.3 h1:yMBqmnQ0gyZvEb/+KzuWZOXgllrXT4SADYbvDaXHv/g= +github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= +github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-test/deep v1.0.3/go.mod h1:wGDj63lr65AM2AQyKZd/NYHGb0R+1RLqB8NKt3aSFNA= github.com/go-test/deep v1.0.7 h1:/VSMRlnY/JSyqxQUzQLKVMAskpY/NZKFA5j2P+0pP2M= github.com/go-test/deep v1.0.7/go.mod h1:QV8Hv/iy04NyLBxAdO9njL0iVPN1S4d/A3NVv1V36o8= -github.com/gobuffalo/flect v0.3.0 h1:erfPWM+K1rFNIQeRPdeEXxo8yFr/PO17lhRnS8FUrtk= -github.com/gobuffalo/flect v0.3.0/go.mod h1:5pf3aGnsvqvCj50AVni7mJJF8ICxGZ8HomberC3pXLE= -github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gobuffalo/flect v1.0.2 h1:eqjPGSo2WmjgY2XlpGwo2NXgL3RucAKo4k4qQMNA5sA= +github.com/gobuffalo/flect v1.0.2/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= @@ -203,15 +155,13 @@ github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QD github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= -github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= -github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= +github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/google/addlicense v0.0.0-20210428195630-6d92264d7170/go.mod h1:EMjYTRimagHs1FwlIqKyX3wAM0u3rA+McvlIIWmSamA= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/gnostic v0.6.9 h1:ZK/5VhkoX835RikCHpSUJV9a+S3e1zLh59YnyWeBW+0= -github.com/google/gnostic v0.6.9/go.mod h1:Nm8234We1lq6iB9OmlgNv3nH91XLLVZHCDayfA3xq+E= +github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= +github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -223,8 +173,8 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= @@ -241,6 +191,7 @@ github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20230926050212-f7f687d19a98 h1:pUa4ghanp6q4IJHwE9RwLgmVFfReJN+KbQ8ExNEUUoQ= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= @@ -248,62 +199,22 @@ github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I= github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= -github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 h1:1/D3zfFHttUKaCaGKZ/dR2roBXv0vKbSCnssIldfQdI= github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320/go.mod h1:EiZBMaudVLy8fmjf9Npq1dq9RalhveqZG5w/yz3mHWs= -github.com/hashicorp/go-hclog v0.9.2/go.mod h1:5CU+agLiy3J7N7QjHK5d05KxGsuXiQLrjA0H7acj2lQ= -github.com/hashicorp/go-hclog v0.14.1/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= -github.com/hashicorp/go-hclog v0.16.2/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= github.com/hashicorp/go-hclog v1.2.1 h1:YQsLlGDJgwhXFpucSPyVbCBviQtjlHv3jLTlp8YmtEw= github.com/hashicorp/go-hclog v1.2.1/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= -github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= -github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= -github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= -github.com/hashicorp/go-kms-wrapping/entropy v0.1.0/go.mod h1:d1g9WGtAunDNpek8jUIEJnBlbgKS1N2Q61QkHiZyR1g= -github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= -github.com/hashicorp/go-plugin v1.4.3/go.mod h1:5fGEH17QVwTTcR0zV7yhDPLLmFX9YSZ38b18Udy6vYQ= -github.com/hashicorp/go-plugin v1.4.4 h1:NVdrSdFRt3SkZtNckJ6tog7gbpRrcbOjQi/rgF7JYWQ= -github.com/hashicorp/go-plugin v1.4.4/go.mod h1:viDMjcLJuDui6pXb8U4HVfb8AamCWhHGUjr2IrTF67s= -github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= -github.com/hashicorp/go-retryablehttp v0.6.6/go.mod h1:vAew36LZh98gCBJNLH42IQ1ER/9wtLZZ8meHqQvEYWY= -github.com/hashicorp/go-retryablehttp v0.7.1 h1:sUiuQAnLlbvmExtFQs72iFW/HXeUn8Z1aJLQ4LJJbTQ= -github.com/hashicorp/go-retryablehttp v0.7.1/go.mod h1:vAew36LZh98gCBJNLH42IQ1ER/9wtLZZ8meHqQvEYWY= -github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5Oi2viEzc= -github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8= -github.com/hashicorp/go-secure-stdlib/base62 v0.1.1/go.mod h1:EdWO6czbmthiwZ3/PUsDV+UD1D5IRU4ActiaWGwt0Yw= -github.com/hashicorp/go-secure-stdlib/mlock v0.1.1 h1:cCRo8gK7oq6A2L6LICkUZ+/a5rLiRXFMf1Qd4xSwxTc= -github.com/hashicorp/go-secure-stdlib/mlock v0.1.1/go.mod h1:zq93CJChV6L9QTfGKtfBxKqD7BqqXx5O04A/ns2p5+I= -github.com/hashicorp/go-secure-stdlib/parseutil v0.1.1 h1:78ki3QBevHwYrVxnyVeaEz+7WtifHhauYF23es/0KlI= -github.com/hashicorp/go-secure-stdlib/parseutil v0.1.1/go.mod h1:QmrqtbKuxxSWTN3ETMPuB+VtEiBJ/A9XhoYGv8E1uD8= -github.com/hashicorp/go-secure-stdlib/password v0.1.1/go.mod h1:9hH302QllNwu1o2TGYtSk8I8kTAN0ca1EHpwhm5Mmzo= -github.com/hashicorp/go-secure-stdlib/strutil v0.1.1 h1:nd0HIW15E6FG1MsnArYaHfuw9C2zgzM8LxkG5Ty/788= -github.com/hashicorp/go-secure-stdlib/strutil v0.1.1/go.mod h1:gKOamz3EwoIoJq7mlMIRBpVTAUn8qPCrEclOKKWhD3U= -github.com/hashicorp/go-secure-stdlib/tlsutil v0.1.1/go.mod h1:l8slYwnJA26yBz+ErHpp2IRCLr0vuOMGBORIz4rRiAs= -github.com/hashicorp/go-sockaddr v1.0.2 h1:ztczhD1jLxIRjVejw8gFomI1BQZOe2WoVOu0SyteCQc= -github.com/hashicorp/go-sockaddr v1.0.2/go.mod h1:rB4wwRAUzs07qva3c5SdrY/NEtAUjGlgmH/UkBUC97A= -github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-uuid v1.0.2/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.3 h1:2gKiV6YVmrJ1i2CKKa9obLvRieoRGviZFL26PcT/Co8= github.com/hashicorp/go-uuid v1.0.3/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.5.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.6.0 h1:feTTfFNnjP967rlCxM/I9g701jU+RN74YKx2mOkIeek= github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc= -github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= -github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/hcl/v2 v2.9.1/go.mod h1:FwWsfWEjyV/CMj8s/gqAuiviY72rJ1/oayI9WftqcKg= github.com/hashicorp/hcl/v2 v2.14.1 h1:x0BpjfZ+CYdbiz+8yZTQ+gdLO7IXvOut7Da+XJayx34= github.com/hashicorp/hcl/v2 v2.14.1/go.mod h1:e4z5nxYlWNPdDSNYX+ph14EvWYMFm3eP0zIUqPc2jr0= @@ -317,47 +228,27 @@ github.com/hashicorp/terraform-plugin-log v0.7.0 h1:SDxJUyT8TwN4l5b5/VkiTIaQgY6R github.com/hashicorp/terraform-plugin-log v0.7.0/go.mod h1:p4R1jWBXRTvL4odmEkFfDdhUjHf9zcs/BCoNHAc7IK4= github.com/hashicorp/terraform-plugin-sdk/v2 v2.24.0 h1:FtCLTiTcykdsURXPt/ku7fYXm3y19nbzbZcUxHx9RbI= github.com/hashicorp/terraform-plugin-sdk/v2 v2.24.0/go.mod h1:80wf5oad1tW+oLnbXS4UTYmDCrl7BuN1Q+IA91X1a4Y= -github.com/hashicorp/vault/api v1.5.0 h1:Bp6yc2bn7CWkOrVIzFT/Qurzx528bdavF3nz590eu28= -github.com/hashicorp/vault/api v1.5.0/go.mod h1:LkMdrZnWNrFaQyYYazWVn7KshilfDidgVBq6YiTq/bM= -github.com/hashicorp/vault/sdk v0.4.1 h1:3SaHOJY687jY1fnB61PtL0cOkKItphrbLmux7T92HBo= -github.com/hashicorp/vault/sdk v0.4.1/go.mod h1:aZ3fNuL5VNydQk8GcLJ2TV8YCRVvyaakYkhZRoVuhj0= -github.com/hashicorp/yamux v0.0.0-20180604194846-3520598351bb/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM= -github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d h1:kJCB4vdITiW1eC1vq2e6IsrXKrZit1bv/TDYFGMp4BQ= -github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM= github.com/iancoleman/strcase v0.2.0 h1:05I4QRnGpI0m37iZQRuskXh+w77mr6Z41lwQzuHLwW0= github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= -github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= -github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= +github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= +github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= +github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jhump/protoreflect v1.6.0 h1:h5jfMVslIg6l29nsMs0D8Wj17RDVdNYti0vDN/PZZoE= -github.com/jhump/protoreflect v1.6.0/go.mod h1:eaTn3RZAmMBcV0fifFvlm6VHNz3wSkYyXYWUh7ymB74= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= -github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= @@ -365,151 +256,89 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v0.0.0-20170820004349-d65d576e9348/go.mod h1:B69LEHPfb2qLo0BaaOLcbitczOKLWTsrBG9LczfCD4k= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= -github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40= github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= -github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84= +github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= +github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= -github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= +github.com/mattn/go-isatty v0.0.17 h1:BTarxUcIeDqL27Mc+vyvdWYSL28zpIhv3RoTdsLMPng= +github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= -github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= github.com/mitchellh/copystructure v1.2.0 h1:vpKXTN4ewci03Vljg/q9QvCGUDttBOGBIa15WveJJGw= github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= -github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-ps v1.0.0 h1:i6ampVEEF4wQFF+bkYfwYgY+F/uYJDktmvLPf7qIgjc= github.com/mitchellh/go-ps v1.0.0/go.mod h1:J4lOc8z8yJs6vUwklHw2XEIiT4z4C40KtWVN3nvg8Pg= -github.com/mitchellh/go-testing-interface v0.0.0-20171004221916-a61a99592b77/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= -github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= github.com/mitchellh/go-testing-interface v1.14.1 h1:jrgshOhYAUVNMAJiKbEu7EqAwgJJ2JqpQmpLJOu07cU= github.com/mitchellh/go-testing-interface v1.14.1/go.mod h1:gfgS7OtZj6MA4U1UrDRp04twqAjfvlZyCfX3sDjEym8= github.com/mitchellh/go-wordwrap v0.0.0-20150314170334-ad45545899c7/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= -github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/go-wordwrap v1.0.1 h1:TLuKupo69TCn6TQSyGxwI1EblZZEsQ0vMlAFQflz0v0= github.com/mitchellh/go-wordwrap v1.0.1/go.mod h1:R62XHJLzvMFRBbcrT7m7WgmE1eOyTSsCt+hzestvNj0= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/mapstructure v1.4.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/muvaf/typewriter v0.0.0-20220131201631-921e94e8e8d7 h1:CxRHKnh1YJXgNKxcos9rrKL6AcmOl1AS/fygmxFDzh4= github.com/muvaf/typewriter v0.0.0-20220131201631-921e94e8e8d7/go.mod h1:SAAdeMEiFXR8LcHffvIdiLI1w243DCH2DuHq7UrA5YQ= -github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nsf/jsondiff v0.0.0-20200515183724-f29ed568f4ce h1:RPclfga2SEJmgMmz2k+Mg7cowZ8yv4Trqw9UsJby758= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= -github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= -github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= -github.com/onsi/ginkgo/v2 v2.6.0 h1:9t9b9vRUbFq3C4qKFCGkVuq/fIHji802N1nrtkh1mNc= -github.com/onsi/gomega v1.24.2 h1:J/tulyYK6JwBldPViHJReihxxZ+22FHs0piGjQAvoUE= -github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= -github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= -github.com/pierrec/lz4 v2.5.2+incompatible h1:WCjObylUIOlKy/+7Abdn34TLIkXiA4UWUMhxq9m9ZXI= -github.com/pierrec/lz4 v2.5.2+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= -github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/onsi/ginkgo/v2 v2.11.0 h1:WgqUCUt/lT6yXoQ8Wef0fsNn5cAuMK7+KT9UFRz2tcU= +github.com/onsi/gomega v1.27.10 h1:naR28SdDFlqrG6kScpT8VWpu1xWY5nJRCF3XaYyBjhI= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= -github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= -github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= -github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= -github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= -github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= -github.com/prometheus/client_golang v1.14.0 h1:nJdhIvne2eSX/XRAFV9PcvFFRbrjbcTUj0VP62TMhnw= -github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= -github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= +github.com/prometheus/client_golang v1.16.0 h1:yk/hx9hDbrGHovbci4BY+pRMfSuuat626eFsHb7tmT8= +github.com/prometheus/client_golang v1.16.0/go.mod h1:Zsulrv/L9oM40tJ7T815tM89lFEugiJ9HzIqaAx4LKc= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= -github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= -github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= -github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= -github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= -github.com/prometheus/common v0.37.0 h1:ccBbHCgIiT9uSoFY0vX8H3zsNR5eLt17/RQLUvn8pXE= -github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= -github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= -github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.8.0 h1:ODq8ZFEaYeCaZOJlZZdJA2AbQR98dSHSM1KW/You5mo= -github.com/prometheus/procfs v0.8.0/go.mod h1:z7EfXMXOkbkqb9IINtpCn86r/to3BnA0uaxHdg830/4= -github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= +github.com/prometheus/client_model v0.4.0 h1:5lQXD3cAg1OXBf4Wq03gTrXHeaV0TQvGfUooCfx1yqY= +github.com/prometheus/client_model v0.4.0/go.mod h1:oMQmHW1/JoDwqLtg57MGgP/Fb1CJEYF2imWWhWtMkYU= +github.com/prometheus/common v0.44.0 h1:+5BrQJwiBB9xsMygAB3TNvpQKOwlkc25LbISbrdOOfY= +github.com/prometheus/common v0.44.0/go.mod h1:ofAIvZbQ1e/nugmZGz4/qCb9Ap1VoSTIO7x0VV9VvuY= +github.com/prometheus/procfs v0.10.1 h1:kYK1Va/YMlutzCGazswoHKo//tZVlFpKYh+PymziUAg= +github.com/prometheus/procfs v0.10.1/go.mod h1:nwNm2aOCAYw8uTR/9bWRREkZFxAUcWzPHWJq+XBB/FM= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= +github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/ryanuber/go-glob v1.0.0 h1:iQh3xXAumdQ+4Ufa5b25cRpC5TYKlno6hsv6Cb3pkBk= -github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc= github.com/sebdah/goldie v1.0.0/go.mod h1:jXP4hmWywNEwZzhMuv2ccnqTSFpuq8iyQhtQdkkZBH4= +github.com/sergi/go-diff v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= -github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= -github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= -github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.9.2 h1:j49Hj62F0n+DaZ1dDCvhABaPNSGNkt32oRFxI33IEMw= -github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= -github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= -github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= +github.com/spf13/afero v1.10.0 h1:EaGW2JJh15aKOejeuJ+wpFSHnbd7GE6Wvp3TsNhb6LY= +github.com/spf13/afero v1.10.0/go.mod h1:UBogFpq8E9Hx+xc5CNTTEpTnuHVmXDwZcZcE1eb/UhQ= +github.com/spf13/cobra v1.7.0 h1:hyqWnYt1ZQShIddO5kBpj3vu05/++x6tJ6dg8EC572I= +github.com/spf13/cobra v1.7.0/go.mod h1:uLxZILRyS/50WlhOIKD7W6V5bgeIt+4sICxh6uRMrb0= github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.4.0 h1:M2gUjqZET1qApGOWNSnZ49BAIMX4F/1plDv3+l31EJ4= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= +github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= -github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= -github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= +github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= github.com/tmccombs/hcl2json v0.3.3 h1:+DLNYqpWE0CsOQiEZu+OZm5ZBImake3wtITYxQ8uLFQ= github.com/tmccombs/hcl2json v0.3.3/go.mod h1:Y2chtz2x9bAeRTvSibVRVgbLJhLJXKlUeIvjeVdnm4w= -github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/upbound/upjet v0.9.0-rc.0.0.20230502154751-645d7260d814 h1:lsVgo6tcAXmdHCoPgo0HT67rtYQ4DRzUeNJ2lh9Qhm0= -github.com/upbound/upjet v0.9.0-rc.0.0.20230502154751-645d7260d814/go.mod h1:CWxJ9YTMy7q+bDc2W504ocL/ZzBmWabwwcRjIaP7CKc= github.com/vmihailenco/msgpack v3.3.3+incompatible/go.mod h1:fy3FlTQTDXWkZ7Bh6AcGMlsjHatGryHQYUTf1ShIgkk= github.com/vmihailenco/msgpack v4.0.4+incompatible h1:dSLoQfGFAo3F6OoNhwUmLwVgaUXK79GlxNBwueZn0xI= github.com/vmihailenco/msgpack v4.0.4+incompatible/go.mod h1:fy3FlTQTDXWkZ7Bh6AcGMlsjHatGryHQYUTf1ShIgkk= @@ -517,9 +346,6 @@ github.com/vmihailenco/msgpack/v4 v4.3.12 h1:07s4sz9IReOgdikxLTKNbBdqDMLsjPKXwvC github.com/vmihailenco/msgpack/v4 v4.3.12/go.mod h1:gborTTJjAo/GWTqqRjrLCn9pgNN+NXzzngzBKDPIqw4= github.com/vmihailenco/tagparser v0.1.1 h1:quXMXlA39OCbd2wAdTsGDlK9RkOk6Wuw+x37wVyIuWY= github.com/vmihailenco/tagparser v0.1.1/go.mod h1:OeAg3pn3UbLjkWt+rN9oFYB6u/cQgqMEUPoW2WPyhdI= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -534,26 +360,23 @@ github.com/zclconf/go-cty v1.10.0/go.mod h1:vVKLxnk3puL4qRAv72AO+W99LUD4da90g3uU github.com/zclconf/go-cty v1.11.0 h1:726SxLdi2SDnjY+BStqB9J1hNp4+2WlzyXLuimibIe0= github.com/zclconf/go-cty v1.11.0/go.mod h1:s9IfD1LK5ccNMSWCVFCE2rJfHiZgi7JijgeWIMfhLvA= github.com/zclconf/go-cty-debug v0.0.0-20191215020915-b22d67c1ba0b/go.mod h1:ZRKQfBXbGkpdV6QMzT3rU1kSTAnfu1dO8dPKjYprgj8= +github.com/zclconf/go-cty-yaml v1.0.3 h1:og/eOQ7lvA/WWhHGFETVWNduJM7Rjsv2RRpx1sdFMLc= +github.com/zclconf/go-cty-yaml v1.0.3/go.mod h1:9YLUH4g7lOhVWqUbctnVlZ5KLpg7JAprQNgxSZ1Gyxs= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= -go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= -go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= -go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ= -go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= -go.uber.org/goleak v1.1.10/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A= -go.uber.org/goleak v1.2.0 h1:xqgm/S+aQvhWFTtR0XK3Jvg7z8kGV8P4X14IzwN3Eqk= +go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= +go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= -go.uber.org/multierr v1.8.0 h1:dg6GjLku4EH+249NNmoIciG9N/jURbDG+pFlTkhzIC8= -go.uber.org/multierr v1.8.0/go.mod h1:7EAYxJLBy9rStEaz58O2t4Uvip6FSURkq8/ppBp95ak= -go.uber.org/zap v1.19.0/go.mod h1:xg/QME4nWcxGxrpdeYfq7UvYrLh66cuVKdrbD1XF/NI= -go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= +go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= +go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= -golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= +go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190426145343-a29dc8fdc734/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -561,10 +384,7 @@ golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.2.0 h1:BRXPfhNivWL5Yq0BGQ39a2sW6t44aODpfxkWjYdzewE= -golang.org/x/crypto v0.2.0/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= +golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -575,6 +395,8 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= +golang.org/x/exp v0.0.0-20230905200255-921286631fa9 h1:GoHiUyI/Tp2nVkLI2mCxVkOjsbSXD66ic0XW0js0R9g= +golang.org/x/exp v0.0.0-20230905200255-921286631fa9/go.mod h1:S2oDrQGGwySpoQPVqRShND87VCbxmc6bL1Yd2oYrm6k= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -599,13 +421,11 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.7.0 h1:LapD9S96VoQRhi/GrNTqeBJFrUjs5UHCAtTlgwA5oZA= -golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/net v0.0.0-20180530234432-1e491301e022/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= +golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180811021610-c39426892332/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -613,7 +433,6 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= -golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -638,12 +457,9 @@ golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= -golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g= -golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= +golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.15.0 h1:ugBLEUaxABaB5AJqW9enI0ACdci2RUd4eP51NTBvuJ8= +golang.org/x/net v0.15.0/go.mod h1:idbUs1IY1+zTqbi8yxTbhexhEEk5ur9LInksu6HrEpk= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -653,10 +469,8 @@ golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= -golang.org/x/oauth2 v0.1.0 h1:isLCZuhj4v+tYv7eskaN4v/TM+A1begWWgyVJDdl1+Y= -golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= +golang.org/x/oauth2 v0.10.0 h1:zHCpF2Khkwy4mMB4bv0U37YtJdTGW8jI0glAApi0Kh8= +golang.org/x/oauth2 v0.10.0/go.mod h1:kTpgurOux7LqtuxjuyZa4Gj2gdezIt/jQtGnNFfypQI= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -668,16 +482,11 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= -golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sync v0.3.0 h1:ftCYgMx6zT/asHUrPw8BLLscYtGznsLAnjq5RH9P66E= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502175342-a43fa875dd82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -685,10 +494,8 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -702,8 +509,6 @@ golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -711,27 +516,22 @@ golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.12.0 h1:CM0HF96J0hcLAwsHPJZjfdNzs0gftsLfgKt57wWHJ0o= +golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.5.0 h1:n2a8QNdAb0sZNpU9R1ALUXBbY+w51fCQDN+7EdxNBsY= -golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= +golang.org/x/term v0.12.0 h1:/ZfYdc3zq+q02Rv9vGqTeSItdzZTSNDmfTi0mBAuidU= +golang.org/x/term v0.12.0/go.mod h1:owVbMEjm3cBLCHdkQu9b1opXd4ETQWc3BhuQGKgXgvU= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -741,12 +541,11 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= +golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20200416051211-89c76fbcd5d1/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -764,7 +563,6 @@ golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgw golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191108193012-7d206e10da11/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -800,14 +598,15 @@ golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.4.0 h1:7mTAgkunk3fr4GAloyyCasadO6h9zSsQZbwvcaIciV4= -golang.org/x/tools v0.4.0/go.mod h1:UE5sM2OK9E/d67R0ANs2xJizIymRP5gJU295PvKXxjQ= +golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.13.0 h1:Iey4qkscZuv0VvIt8E0neZjtPVQFSc870HQ448QgEmQ= +golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -gomodules.xyz/jsonpatch/v2 v2.2.0 h1:4pT439QV83L+G9FkcCriY6EkpcK6r6bK+A5FBUMI7qY= -gomodules.xyz/jsonpatch/v2 v2.2.0/go.mod h1:WXp+iVDkoLQqPudfQ9GBlwB2eZ5DKOnjQZCYdOS8GPY= +gomodules.xyz/jsonpatch/v2 v2.4.0 h1:Ci3iUJyx9UeRx7CeFN8ARgGbkESwJK+KB9lLcWxY/Zw= +gomodules.xyz/jsonpatch/v2 v2.4.0/go.mod h1:AH3dM2RI6uoBZxn3LVrfvJ3E0/9dG4cSrbuBJT4moAY= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -835,7 +634,6 @@ google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCID google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/genproto v0.0.0-20170818010345-ee236bd376b0/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= @@ -859,7 +657,6 @@ google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA= @@ -873,10 +670,8 @@ google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20220107163113-42d7afdf6368/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20221202195650-67e5cbc046fd h1:OjndDrsik+Gt+e6fs45z9AxiewiKyLKYpA45W5Kpkks= -google.golang.org/genproto v0.0.0-20221202195650-67e5cbc046fd/go.mod h1:cTsE614GARnxrLsqKREzmNYJACSWWpAWdNMwnD7c2BE= -google.golang.org/grpc v1.8.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= +google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 h1:bVf09lpb+OJbByTj913DRJioFFAjf/ZGxEz7MajTp2U= +google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98/go.mod h1:TUfxEVdsvPg18p6AslUXFoLdpED4oBnGwyqk3dV1XzM= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -890,15 +685,11 @@ google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3Iji google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= -google.golang.org/grpc v1.41.0/go.mod h1:U3l9uK9J0sini8mHphKoXyaqDA/8VyGnDee1zzIUK6k= -google.golang.org/grpc v1.50.1 h1:DS/BukOZWp8s6p4Dt/tOaJaTQyPyOoCcrjroHuCeLzY= -google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= +google.golang.org/grpc v1.58.3 h1:BjnpXut1btbtgN/6sp+brB2Kbm2LjNXnidYujAVbSoQ= +google.golang.org/grpc v1.58.3/go.mod h1:tgX3ZQDlNJGU96V6yHh1T/JeoBQ2TXdr43YbYSsCJk0= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -911,34 +702,23 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8 h1:KR8+MyP7/qOlV+8Af01LtjL04bu7on42eVsxT4EyBQk= -google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= -gopkg.in/square/go-jose.v2 v2.5.1 h1:7odma5RETjNHWJnR32wx8t+Io4djHE1PqxCFx3iiZ2w= -gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -948,31 +728,31 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -k8s.io/api v0.26.3 h1:emf74GIQMTik01Aum9dPP0gAypL8JTLl/lHa4V9RFSU= -k8s.io/api v0.26.3/go.mod h1:PXsqwPMXBSBcL1lJ9CYDKy7kIReUydukS5JiRlxC3qE= -k8s.io/apiextensions-apiserver v0.26.3 h1:5PGMm3oEzdB1W/FTMgGIDmm100vn7IaUP5er36dB+YE= -k8s.io/apiextensions-apiserver v0.26.3/go.mod h1:jdA5MdjNWGP+njw1EKMZc64xAT5fIhN6VJrElV3sfpQ= -k8s.io/apimachinery v0.26.3 h1:dQx6PNETJ7nODU3XPtrwkfuubs6w7sX0M8n61zHIV/k= -k8s.io/apimachinery v0.26.3/go.mod h1:ats7nN1LExKHvJ9TmwootT00Yz05MuYqPXEXaVeOy5I= -k8s.io/client-go v0.26.3 h1:k1UY+KXfkxV2ScEL3gilKcF7761xkYsSD6BC9szIu8s= -k8s.io/client-go v0.26.3/go.mod h1:ZPNu9lm8/dbRIPAgteN30RSXea6vrCpFvq+MateTUuQ= -k8s.io/component-base v0.26.3 h1:oC0WMK/ggcbGDTkdcqefI4wIZRYdK3JySx9/HADpV0g= -k8s.io/component-base v0.26.3/go.mod h1:5kj1kZYwSC6ZstHJN7oHBqcJC6yyn41eR+Sqa/mQc8E= -k8s.io/klog/v2 v2.80.1 h1:atnLQ121W371wYYFawwYx1aEY2eUfs4l3J72wtgAwV4= -k8s.io/klog/v2 v2.80.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 h1:+70TFaan3hfJzs+7VK2o+OGxg8HsuBr/5f6tVAjDu6E= -k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280/go.mod h1:+Axhij7bCpeqhklhUTe3xmOn6bWxolyZEeyaFpjGtl4= -k8s.io/utils v0.0.0-20230313181309-38a27ef9d749 h1:xMMXJlJbsU8w3V5N2FLDQ8YgU8s1EoULdbQBcAeNJkY= -k8s.io/utils v0.0.0-20230313181309-38a27ef9d749/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +k8s.io/api v0.28.2 h1:9mpl5mOb6vXZvqbQmankOfPIGiudghwCoLl1EYfUZbw= +k8s.io/api v0.28.2/go.mod h1:RVnJBsjU8tcMq7C3iaRSGMeaKt2TWEUXcpIt/90fjEg= +k8s.io/apiextensions-apiserver v0.28.2 h1:J6/QRWIKV2/HwBhHRVITMLYoypCoPY1ftigDM0Kn+QU= +k8s.io/apiextensions-apiserver v0.28.2/go.mod h1:5tnkxLGa9nefefYzWuAlWZ7RZYuN/765Au8cWLA6SRg= +k8s.io/apimachinery v0.28.2 h1:KCOJLrc6gu+wV1BYgwik4AF4vXOlVJPdiqn0yAWWwXQ= +k8s.io/apimachinery v0.28.2/go.mod h1:RdzF87y/ngqk9H4z3EL2Rppv5jj95vGS/HaFXrLDApU= +k8s.io/client-go v0.28.2 h1:DNoYI1vGq0slMBN/SWKMZMw0Rq+0EQW6/AK4v9+3VeY= +k8s.io/client-go v0.28.2/go.mod h1:sMkApowspLuc7omj1FOSUxSoqjr+d5Q0Yc0LOFnYFJY= +k8s.io/component-base v0.28.2 h1:Yc1yU+6AQSlpJZyvehm/NkJBII72rzlEsd6MkBQ+G0E= +k8s.io/component-base v0.28.2/go.mod h1:4IuQPQviQCg3du4si8GpMrhAIegxpsgPngPRR/zWpzc= +k8s.io/klog/v2 v2.100.1 h1:7WCHKK6K8fNhTqfBhISHQ97KrnJNFZMcQvKp7gP/tmg= +k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= +k8s.io/kube-openapi v0.0.0-20230717233707-2695361300d9 h1:LyMgNKD2P8Wn1iAwQU5OhxCKlKJy0sHc+PcDwFB24dQ= +k8s.io/kube-openapi v0.0.0-20230717233707-2695361300d9/go.mod h1:wZK2AVp1uHCp4VamDVgBP2COHZjqD1T68Rf0CM3YjSM= +k8s.io/utils v0.0.0-20230726121419-3b25d923346b h1:sgn3ZU783SCgtaSJjpcVVlRqd6GSnlTLKgpAAttJvpI= +k8s.io/utils v0.0.0-20230726121419-3b25d923346b/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= -sigs.k8s.io/controller-runtime v0.14.6 h1:oxstGVvXGNnMvY7TAESYk+lzr6S3V5VFxQ6d92KcwQA= -sigs.k8s.io/controller-runtime v0.14.6/go.mod h1:WqIdsAY6JBsjfc/CqO0CORmNtoCtE4S6qbPc9s68h+0= -sigs.k8s.io/controller-tools v0.11.3 h1:T1xzLkog9saiyQSLz1XOImu4OcbdXWytc5cmYsBeBiE= -sigs.k8s.io/controller-tools v0.11.3/go.mod h1:qcfX7jfcfYD/b7lAhvqAyTbt/px4GpvN88WKLFFv7p8= -sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 h1:iXTIw73aPyC+oRdyqqvVJuloN1p0AC/kzH07hu3NE+k= -sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +sigs.k8s.io/controller-runtime v0.16.2 h1:mwXAVuEk3EQf478PQwQ48zGOXvW27UJc8NHktQVuIPU= +sigs.k8s.io/controller-runtime v0.16.2/go.mod h1:vpMu3LpI5sYWtujJOa2uPK61nB5rbwlN7BAB8aSLvGU= +sigs.k8s.io/controller-tools v0.13.0 h1:NfrvuZ4bxyolhDBt/rCZhDnx3M2hzlhgo5n3Iv2RykI= +sigs.k8s.io/controller-tools v0.13.0/go.mod h1:5vw3En2NazbejQGCeWKRrE7q4P+CW8/klfVqP8QZkgA= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= sigs.k8s.io/structured-merge-diff/v4 v4.2.3 h1:PRbqxJClWWYMNV1dhaG4NsibJbArud9kFxnAMREiWFE= sigs.k8s.io/structured-merge-diff/v4 v4.2.3/go.mod h1:qjx8mGObPmV2aSZepjQjbmb2ihdVs8cGKBraizNC69E= sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= diff --git a/hack/embed.go b/hack/embed.go new file mode 100644 index 0000000..3163311 --- /dev/null +++ b/hack/embed.go @@ -0,0 +1,8 @@ +package hack + +import _ "embed" + +// MainTemplate is populated with provider main program template. +// +//go:embed main.go.tmpl +var MainTemplate string diff --git a/hack/main.go.tmpl b/hack/main.go.tmpl new file mode 100644 index 0000000..9c9f2ef --- /dev/null +++ b/hack/main.go.tmpl @@ -0,0 +1,117 @@ +/* +Copyright 2021 Upbound Inc. +*/ + +package main + +import ( + "context" + "os" + "path/filepath" + "time" + + xpv1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + xpcontroller "github.com/crossplane/crossplane-runtime/pkg/controller" + "github.com/crossplane/crossplane-runtime/pkg/logging" + "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" + "github.com/crossplane/crossplane-runtime/pkg/resource" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/terraform" + "gopkg.in/alecthomas/kingpin.v2" + kerrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/tools/leaderelection/resourcelock" + ctrl "sigs.k8s.io/controller-runtime" + "sigs.k8s.io/controller-runtime/pkg/log/zap" + + "kubedb.dev/provider-aws/apis" + "kubedb.dev/provider-aws/apis/v1alpha1" + "kubedb.dev/provider-aws/config" + "kubedb.dev/provider-aws/internal/clients" + "kubedb.dev/provider-aws/internal/controller" + "kubedb.dev/provider-aws/internal/features" +) + +func main() { + var ( + app = kingpin.New(filepath.Base(os.Args[0]), "Terraform based Crossplane provider for AWS").DefaultEnvars() + debug = app.Flag("debug", "Run with debug logging.").Short('d').Bool() + syncPeriod = app.Flag("sync", "Controller manager sync period such as 300ms, 1.5h, or 2h45m").Short('s').Default("1h").Duration() + leaderElection = app.Flag("leader-election", "Use leader election for the controller manager.").Short('l').Default("false").OverrideDefaultFromEnvar("LEADER_ELECTION").Bool() + terraformVersion = app.Flag("terraform-version", "Terraform version.").Required().Envar("TERRAFORM_VERSION").String() + providerSource = app.Flag("terraform-provider-source", "Terraform provider source.").Required().Envar("TERRAFORM_PROVIDER_SOURCE").String() + providerVersion = app.Flag("terraform-provider-version", "Terraform provider version.").Required().Envar("TERRAFORM_PROVIDER_VERSION").String() + maxReconcileRate = app.Flag("max-reconcile-rate", "The global maximum rate per second at which resources may checked for drift from the desired state.").Default("10").Int() + + namespace = app.Flag("namespace", "Namespace used to set as default scope in default secret store config.").Default("crossplane-system").Envar("POD_NAMESPACE").String() + enableExternalSecretStores = app.Flag("enable-external-secret-stores", "Enable support for ExternalSecretStores.").Default("false").Envar("ENABLE_EXTERNAL_SECRET_STORES").Bool() + enableManagementPolicies = app.Flag("enable-management-policies", "Enable support for Management Policies.").Default("false").Envar("ENABLE_MANAGEMENT_POLICIES").Bool() + ) + + kingpin.MustParse(app.Parse(os.Args[1:])) + + zl := zap.New(zap.UseDevMode(*debug)) + log := logging.NewLogrLogger(zl.WithName("provider-aws")) + if *debug { + // The controller-runtime runs with a no-op logger by default. It is + // *very* verbose even at info level, so we only provide it a real + // logger when we're running in debug mode. + ctrl.SetLogger(zl) + } + + log.Debug("Starting", "sync-period", syncPeriod.String()) + + cfg, err := ctrl.GetConfig() + kingpin.FatalIfError(err, "Cannot get API server rest config") + + mgr, err := ctrl.NewManager(cfg, ctrl.Options{ + LeaderElection: *leaderElection, + LeaderElectionID: "crossplane-leader-election-provider-aws", + SyncPeriod: syncPeriod, + LeaderElectionResourceLock: resourcelock.LeasesResourceLock, + LeaseDuration: func() *time.Duration { d := 60 * time.Second; return &d }(), + RenewDeadline: func() *time.Duration { d := 50 * time.Second; return &d }(), + }) + kingpin.FatalIfError(err, "Cannot create controller manager") + kingpin.FatalIfError(apis.AddToScheme(mgr.GetScheme()), "Cannot add AWS APIs to scheme") + o := tjcontroller.Options{ + Options: xpcontroller.Options{ + Logger: log, + GlobalRateLimiter: ratelimiter.NewGlobal(*maxReconcileRate), + PollInterval: 1 * time.Minute, + MaxConcurrentReconciles: 1, + }, + Provider: config.GetProvider(), + // use the following WorkspaceStoreOption to enable the shared gRPC mode + // terraform.WithProviderRunner(terraform.NewSharedProvider(log, os.Getenv("TERRAFORM_NATIVE_PROVIDER_PATH"), terraform.WithNativeProviderArgs("-debuggable"))) + WorkspaceStore: terraform.NewWorkspaceStore(log), + SetupFn: clients.TerraformSetupBuilder(*terraformVersion, *providerSource, *providerVersion), + } + + if *enableExternalSecretStores { + o.SecretStoreConfigGVK = &v1alpha1.StoreConfigGroupVersionKind + log.Info("Alpha feature enabled", "flag", features.EnableAlphaExternalSecretStores) + + // Ensure default store config exists. + kingpin.FatalIfError(resource.Ignore(kerrors.IsAlreadyExists, mgr.GetClient().Create(context.Background(), &v1alpha1.StoreConfig{ + ObjectMeta: metav1.ObjectMeta{ + Name: "default", + }, + Spec: v1alpha1.StoreConfigSpec{ + // NOTE(turkenh): We only set required spec and expect optional + // ones to properly be initialized with CRD level default values. + SecretStoreConfig: xpv1.SecretStoreConfig{ + DefaultScope: *namespace, + }, + }, + })), "cannot create default store config") + } + + if *enableManagementPolicies { + o.Features.Enable(features.EnableAlphaManagementPolicies) + log.Info("Alpha feature enabled", "flag", features.EnableAlphaManagementPolicies) + } + + kingpin.FatalIfError(controller.Setup(mgr, o), "Cannot setup AWS controllers") + kingpin.FatalIfError(mgr.Start(ctrl.SetupSignalHandler()), "Cannot start controller manager") +} diff --git a/internal/clients/aws.go b/internal/clients/aws.go index f7f3d7a..73ff571 100644 --- a/internal/clients/aws.go +++ b/internal/clients/aws.go @@ -15,7 +15,7 @@ import ( "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" - "github.com/upbound/upjet/pkg/terraform" + "github.com/crossplane/upjet/pkg/terraform" "kubedb.dev/provider-aws/apis/v1beta1" ) diff --git a/internal/controller/docdb/cluster/zz_controller.go b/internal/controller/docdb/cluster/zz_controller.go index a46adcd..7867d0c 100755 --- a/internal/controller/docdb/cluster/zz_controller.go +++ b/internal/controller/docdb/cluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Cluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Cluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Cluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/clusterinstance/zz_controller.go b/internal/controller/docdb/clusterinstance/zz_controller.go index 88fde01..ea9677b 100755 --- a/internal/controller/docdb/clusterinstance/zz_controller.go +++ b/internal/controller/docdb/clusterinstance/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterInstance_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_instance"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_instance"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterInstance{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterInstance{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/clusterparametergroup/zz_controller.go b/internal/controller/docdb/clusterparametergroup/zz_controller.go index 92fc9e1..3db1dd8 100755 --- a/internal/controller/docdb/clusterparametergroup/zz_controller.go +++ b/internal/controller/docdb/clusterparametergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterParameterGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_parameter_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_parameter_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterParameterGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterParameterGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/clustersnapshot/zz_controller.go b/internal/controller/docdb/clustersnapshot/zz_controller.go index 922fd31..61e3640 100755 --- a/internal/controller/docdb/clustersnapshot/zz_controller.go +++ b/internal/controller/docdb/clustersnapshot/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterSnapshot_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_snapshot"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_cluster_snapshot"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterSnapshot{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterSnapshot{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/eventsubscription/zz_controller.go b/internal/controller/docdb/eventsubscription/zz_controller.go index 6b5ef79..0366603 100755 --- a/internal/controller/docdb/eventsubscription/zz_controller.go +++ b/internal/controller/docdb/eventsubscription/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.EventSubscription_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_event_subscription"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_event_subscription"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.EventSubscription{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.EventSubscription{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/globalcluster/zz_controller.go b/internal/controller/docdb/globalcluster/zz_controller.go index bcd0f7c..cee0336 100755 --- a/internal/controller/docdb/globalcluster/zz_controller.go +++ b/internal/controller/docdb/globalcluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.GlobalCluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_global_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_global_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.GlobalCluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.GlobalCluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/docdb/subnetgroup/zz_controller.go b/internal/controller/docdb/subnetgroup/zz_controller.go index 20b6b4f..8775b16 100755 --- a/internal/controller/docdb/subnetgroup/zz_controller.go +++ b/internal/controller/docdb/subnetgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/docdb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SubnetGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_subnet_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_docdb_subnet_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SubnetGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SubnetGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/contributorinsights/zz_controller.go b/internal/controller/dynamodb/contributorinsights/zz_controller.go index cc74d91..51b1fb1 100755 --- a/internal/controller/dynamodb/contributorinsights/zz_controller.go +++ b/internal/controller/dynamodb/contributorinsights/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ContributorInsights_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ContributorInsights_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_contributor_insights"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ContributorInsights_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_contributor_insights"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ContributorInsights_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ContributorInsights{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ContributorInsights{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/globaltable/zz_controller.go b/internal/controller/dynamodb/globaltable/zz_controller.go index a4ca77e..60d35b4 100755 --- a/internal/controller/dynamodb/globaltable/zz_controller.go +++ b/internal/controller/dynamodb/globaltable/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.GlobalTable_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalTable_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_global_table"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalTable_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_global_table"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.GlobalTable_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.GlobalTable{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.GlobalTable{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/kinesisstreamingdestination/zz_controller.go b/internal/controller/dynamodb/kinesisstreamingdestination/zz_controller.go index a0e35a2..1ec4668 100755 --- a/internal/controller/dynamodb/kinesisstreamingdestination/zz_controller.go +++ b/internal/controller/dynamodb/kinesisstreamingdestination/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.KinesisStreamingDestination_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.KinesisStreamingDestination_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_kinesis_streaming_destination"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.KinesisStreamingDestination_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_kinesis_streaming_destination"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.KinesisStreamingDestination_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.KinesisStreamingDestination{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.KinesisStreamingDestination{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/table/zz_controller.go b/internal/controller/dynamodb/table/zz_controller.go index 4d90bc3..587031a 100755 --- a/internal/controller/dynamodb/table/zz_controller.go +++ b/internal/controller/dynamodb/table/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Table_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Table_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Table_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Table_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Table{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Table{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/tableitem/zz_controller.go b/internal/controller/dynamodb/tableitem/zz_controller.go index fcb42b5..b4371cc 100755 --- a/internal/controller/dynamodb/tableitem/zz_controller.go +++ b/internal/controller/dynamodb/tableitem/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.TableItem_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.TableItem_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table_item"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.TableItem_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table_item"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.TableItem_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.TableItem{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.TableItem{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/tablereplica/zz_controller.go b/internal/controller/dynamodb/tablereplica/zz_controller.go index aa506b2..4c3ac50 100755 --- a/internal/controller/dynamodb/tablereplica/zz_controller.go +++ b/internal/controller/dynamodb/tablereplica/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.TableReplica_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.TableReplica_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table_replica"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.TableReplica_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_table_replica"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.TableReplica_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.TableReplica{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.TableReplica{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/dynamodb/tag/zz_controller.go b/internal/controller/dynamodb/tag/zz_controller.go index b15ea13..50bd640 100755 --- a/internal/controller/dynamodb/tag/zz_controller.go +++ b/internal/controller/dynamodb/tag/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/dynamodb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Tag_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Tag_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_tag"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Tag_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_dynamodb_tag"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Tag_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Tag{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Tag{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/route/zz_controller.go b/internal/controller/ec2/route/zz_controller.go index 5975b3b..bd56e1f 100755 --- a/internal/controller/ec2/route/zz_controller.go +++ b/internal/controller/ec2/route/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Route_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Route_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_route"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Route_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_route"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Route_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Route{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Route{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/securitygroup/zz_controller.go b/internal/controller/ec2/securitygroup/zz_controller.go index 50c35e4..6a9def1 100755 --- a/internal/controller/ec2/securitygroup/zz_controller.go +++ b/internal/controller/ec2/securitygroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SecurityGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_security_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_security_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroup_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SecurityGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SecurityGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/securitygrouprule/zz_controller.go b/internal/controller/ec2/securitygrouprule/zz_controller.go index c590fad..b06d589 100755 --- a/internal/controller/ec2/securitygrouprule/zz_controller.go +++ b/internal/controller/ec2/securitygrouprule/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SecurityGroupRule_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroupRule_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_security_group_rule"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroupRule_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_security_group_rule"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SecurityGroupRule_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SecurityGroupRule{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SecurityGroupRule{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/subnet/zz_controller.go b/internal/controller/ec2/subnet/zz_controller.go index 2fd7ff9..6a5c4da 100755 --- a/internal/controller/ec2/subnet/zz_controller.go +++ b/internal/controller/ec2/subnet/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Subnet_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Subnet_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_subnet"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Subnet_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_subnet"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Subnet_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Subnet{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Subnet{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/vpc/zz_controller.go b/internal/controller/ec2/vpc/zz_controller.go index 028be43..20c0d5b 100755 --- a/internal/controller/ec2/vpc/zz_controller.go +++ b/internal/controller/ec2/vpc/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.VPC_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPC_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPC_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.VPC_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.VPC{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.VPC{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/vpcendpoint/zz_controller.go b/internal/controller/ec2/vpcendpoint/zz_controller.go index 1446479..2b2abd5 100755 --- a/internal/controller/ec2/vpcendpoint/zz_controller.go +++ b/internal/controller/ec2/vpcendpoint/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.VPCEndpoint_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPCEndpoint_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc_endpoint"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPCEndpoint_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc_endpoint"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.VPCEndpoint_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.VPCEndpoint{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.VPCEndpoint{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/ec2/vpcpeeringconnection/zz_controller.go b/internal/controller/ec2/vpcpeeringconnection/zz_controller.go index c8f5940..36aff91 100755 --- a/internal/controller/ec2/vpcpeeringconnection/zz_controller.go +++ b/internal/controller/ec2/vpcpeeringconnection/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/ec2/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.VPCPeeringConnection_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPCPeeringConnection_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc_peering_connection"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.VPCPeeringConnection_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_vpc_peering_connection"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.VPCPeeringConnection_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.VPCPeeringConnection{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.VPCPeeringConnection{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/cluster/zz_controller.go b/internal/controller/elasticache/cluster/zz_controller.go index 4866033..107d33d 100755 --- a/internal/controller/elasticache/cluster/zz_controller.go +++ b/internal/controller/elasticache/cluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Cluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Cluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Cluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/parametergroup/zz_controller.go b/internal/controller/elasticache/parametergroup/zz_controller.go index 617ad80..b2cda87 100755 --- a/internal/controller/elasticache/parametergroup/zz_controller.go +++ b/internal/controller/elasticache/parametergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ParameterGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_parameter_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_parameter_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ParameterGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ParameterGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/replicationgroup/zz_controller.go b/internal/controller/elasticache/replicationgroup/zz_controller.go index 921fd37..603a886 100755 --- a/internal/controller/elasticache/replicationgroup/zz_controller.go +++ b/internal/controller/elasticache/replicationgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ReplicationGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ReplicationGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_replication_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ReplicationGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_replication_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ReplicationGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ReplicationGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ReplicationGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/subnetgroup/zz_controller.go b/internal/controller/elasticache/subnetgroup/zz_controller.go index 5bd7739..e63f557 100755 --- a/internal/controller/elasticache/subnetgroup/zz_controller.go +++ b/internal/controller/elasticache/subnetgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SubnetGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_subnet_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_subnet_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SubnetGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SubnetGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/user/zz_controller.go b/internal/controller/elasticache/user/zz_controller.go index c758c2f..020f365 100755 --- a/internal/controller/elasticache/user/zz_controller.go +++ b/internal/controller/elasticache/user/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.User_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.User_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_user"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.User_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_user"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.User_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.User{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.User{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticache/usergroup/zz_controller.go b/internal/controller/elasticache/usergroup/zz_controller.go index 42c3dca..361ad3b 100755 --- a/internal/controller/elasticache/usergroup/zz_controller.go +++ b/internal/controller/elasticache/usergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticache/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.UserGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.UserGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_user_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.UserGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticache_user_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.UserGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.UserGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.UserGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticsearch/domain/zz_controller.go b/internal/controller/elasticsearch/domain/zz_controller.go index cd91141..507a7e5 100755 --- a/internal/controller/elasticsearch/domain/zz_controller.go +++ b/internal/controller/elasticsearch/domain/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticsearch/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Domain_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Domain_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Domain_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Domain_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Domain{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Domain{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticsearch/domainpolicy/zz_controller.go b/internal/controller/elasticsearch/domainpolicy/zz_controller.go index 11a32c4..951ea08 100755 --- a/internal/controller/elasticsearch/domainpolicy/zz_controller.go +++ b/internal/controller/elasticsearch/domainpolicy/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticsearch/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.DomainPolicy_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DomainPolicy_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain_policy"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DomainPolicy_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain_policy"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.DomainPolicy_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.DomainPolicy{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.DomainPolicy{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/elasticsearch/domainsamloptions/zz_controller.go b/internal/controller/elasticsearch/domainsamloptions/zz_controller.go index 1f54056..e86894a 100755 --- a/internal/controller/elasticsearch/domainsamloptions/zz_controller.go +++ b/internal/controller/elasticsearch/domainsamloptions/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/elasticsearch/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.DomainSAMLOptions_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DomainSAMLOptions_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain_saml_options"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DomainSAMLOptions_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_elasticsearch_domain_saml_options"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.DomainSAMLOptions_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.DomainSAMLOptions{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.DomainSAMLOptions{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/kafka/cluster/zz_controller.go b/internal/controller/kafka/cluster/zz_controller.go index 53d0aa5..8ed9c34 100755 --- a/internal/controller/kafka/cluster/zz_controller.go +++ b/internal/controller/kafka/cluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/kafka/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Cluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_msk_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_msk_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Cluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Cluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/kafka/configuration/zz_controller.go b/internal/controller/kafka/configuration/zz_controller.go index f70719e..9bef8bf 100755 --- a/internal/controller/kafka/configuration/zz_controller.go +++ b/internal/controller/kafka/configuration/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/kafka/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Configuration_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Configuration_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_msk_configuration"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Configuration_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_msk_configuration"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Configuration_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Configuration{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Configuration{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/kinesis/stream/zz_controller.go b/internal/controller/kinesis/stream/zz_controller.go index ebaa4cf..054ca2b 100755 --- a/internal/controller/kinesis/stream/zz_controller.go +++ b/internal/controller/kinesis/stream/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/kinesis/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Stream_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Stream_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_kinesis_stream"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Stream_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_kinesis_stream"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Stream_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Stream{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Stream{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/kms/key/zz_controller.go b/internal/controller/kms/key/zz_controller.go index fd95a55..cc2a617 100755 --- a/internal/controller/kms/key/zz_controller.go +++ b/internal/controller/kms/key/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/kms/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Key_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Key_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_kms_key"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Key_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_kms_key"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Key_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Key{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Key{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/memorydb/acl/zz_controller.go b/internal/controller/memorydb/acl/zz_controller.go index 9488065..579a73b 100755 --- a/internal/controller/memorydb/acl/zz_controller.go +++ b/internal/controller/memorydb/acl/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/memorydb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ACL_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ACL_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_acl"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ACL_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_acl"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ACL_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ACL{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ACL{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/memorydb/cluster/zz_controller.go b/internal/controller/memorydb/cluster/zz_controller.go index 6bb89aa..061a31d 100755 --- a/internal/controller/memorydb/cluster/zz_controller.go +++ b/internal/controller/memorydb/cluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/memorydb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Cluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Cluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Cluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/memorydb/parametergroup/zz_controller.go b/internal/controller/memorydb/parametergroup/zz_controller.go index dc01d5f..711ee0a 100755 --- a/internal/controller/memorydb/parametergroup/zz_controller.go +++ b/internal/controller/memorydb/parametergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/memorydb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ParameterGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_parameter_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_parameter_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ParameterGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ParameterGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/memorydb/snapshot/zz_controller.go b/internal/controller/memorydb/snapshot/zz_controller.go index 0b77377..9ce95ab 100755 --- a/internal/controller/memorydb/snapshot/zz_controller.go +++ b/internal/controller/memorydb/snapshot/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/memorydb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Snapshot_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_snapshot"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_snapshot"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Snapshot{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Snapshot{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/memorydb/subnetgroup/zz_controller.go b/internal/controller/memorydb/subnetgroup/zz_controller.go index d3a705a..7315e1e 100755 --- a/internal/controller/memorydb/subnetgroup/zz_controller.go +++ b/internal/controller/memorydb/subnetgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/memorydb/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SubnetGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_subnet_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_memorydb_subnet_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SubnetGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SubnetGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/providerconfig/config.go b/internal/controller/providerconfig/config.go index 1174daa..4d48e53 100644 --- a/internal/controller/providerconfig/config.go +++ b/internal/controller/providerconfig/config.go @@ -5,13 +5,11 @@ Copyright 2021 Upbound Inc. package providerconfig import ( - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/source" - "github.com/crossplane/crossplane-runtime/pkg/event" "github.com/crossplane/crossplane-runtime/pkg/reconciler/providerconfig" "github.com/crossplane/crossplane-runtime/pkg/resource" - "github.com/upbound/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller" + ctrl "sigs.k8s.io/controller-runtime" "kubedb.dev/provider-aws/apis/v1beta1" ) @@ -30,7 +28,7 @@ func Setup(mgr ctrl.Manager, o controller.Options) error { Named(name). WithOptions(o.ForControllerRuntime()). For(&v1beta1.ProviderConfig{}). - Watches(&source.Kind{Type: &v1beta1.ProviderConfigUsage{}}, &resource.EnqueueRequestForProviderConfig{}). + Watches(&v1beta1.ProviderConfigUsage{}, &resource.EnqueueRequestForProviderConfig{}). Complete(providerconfig.NewReconciler(mgr, of, providerconfig.WithLogger(o.Logger.WithValues("controller", name)), providerconfig.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))))) diff --git a/internal/controller/rds/cluster/zz_controller.go b/internal/controller/rds/cluster/zz_controller.go index 87dbe88..a5eb907 100755 --- a/internal/controller/rds/cluster/zz_controller.go +++ b/internal/controller/rds/cluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Cluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Cluster_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Cluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Cluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clusteractivitystream/zz_controller.go b/internal/controller/rds/clusteractivitystream/zz_controller.go index c2d22e8..3f850c9 100755 --- a/internal/controller/rds/clusteractivitystream/zz_controller.go +++ b/internal/controller/rds/clusteractivitystream/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterActivityStream_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterActivityStream_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_activity_stream"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterActivityStream_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_activity_stream"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterActivityStream_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterActivityStream{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterActivityStream{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clusterendpoint/zz_controller.go b/internal/controller/rds/clusterendpoint/zz_controller.go index 579753e..61d9572 100755 --- a/internal/controller/rds/clusterendpoint/zz_controller.go +++ b/internal/controller/rds/clusterendpoint/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterEndpoint_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterEndpoint_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_endpoint"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterEndpoint_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_endpoint"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterEndpoint_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterEndpoint{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterEndpoint{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clusterinstance/zz_controller.go b/internal/controller/rds/clusterinstance/zz_controller.go index 96eff8e..ea8ad8a 100755 --- a/internal/controller/rds/clusterinstance/zz_controller.go +++ b/internal/controller/rds/clusterinstance/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterInstance_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_instance"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_instance"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterInstance_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterInstance{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterInstance{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clusterparametergroup/zz_controller.go b/internal/controller/rds/clusterparametergroup/zz_controller.go index 059c43a..72fa075 100755 --- a/internal/controller/rds/clusterparametergroup/zz_controller.go +++ b/internal/controller/rds/clusterparametergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterParameterGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_parameter_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_parameter_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterParameterGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterParameterGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterParameterGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clusterroleassociation/zz_controller.go b/internal/controller/rds/clusterroleassociation/zz_controller.go index d827e85..a617d95 100755 --- a/internal/controller/rds/clusterroleassociation/zz_controller.go +++ b/internal/controller/rds/clusterroleassociation/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterRoleAssociation_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterRoleAssociation_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_role_association"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterRoleAssociation_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_cluster_role_association"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterRoleAssociation_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterRoleAssociation{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterRoleAssociation{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/clustersnapshot/zz_controller.go b/internal/controller/rds/clustersnapshot/zz_controller.go index aa226ef..928a932 100755 --- a/internal/controller/rds/clustersnapshot/zz_controller.go +++ b/internal/controller/rds/clustersnapshot/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ClusterSnapshot_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_cluster_snapshot"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_cluster_snapshot"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ClusterSnapshot_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ClusterSnapshot{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ClusterSnapshot{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/dbinstanceautomatedbackupsreplication/zz_controller.go b/internal/controller/rds/dbinstanceautomatedbackupsreplication/zz_controller.go index aa8e40d..6d1236e 100755 --- a/internal/controller/rds/dbinstanceautomatedbackupsreplication/zz_controller.go +++ b/internal/controller/rds/dbinstanceautomatedbackupsreplication/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.DBInstanceAutomatedBackupsReplication_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DBInstanceAutomatedBackupsReplication_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance_automated_backups_replication"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DBInstanceAutomatedBackupsReplication_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance_automated_backups_replication"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.DBInstanceAutomatedBackupsReplication_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.DBInstanceAutomatedBackupsReplication{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.DBInstanceAutomatedBackupsReplication{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/dbsnapshotcopy/zz_controller.go b/internal/controller/rds/dbsnapshotcopy/zz_controller.go index 73696b7..f17892c 100755 --- a/internal/controller/rds/dbsnapshotcopy/zz_controller.go +++ b/internal/controller/rds/dbsnapshotcopy/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.DBSnapshotCopy_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DBSnapshotCopy_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_snapshot_copy"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.DBSnapshotCopy_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_snapshot_copy"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.DBSnapshotCopy_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.DBSnapshotCopy{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.DBSnapshotCopy{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/eventsubscription/zz_controller.go b/internal/controller/rds/eventsubscription/zz_controller.go index 5bd44d9..78aa88e 100755 --- a/internal/controller/rds/eventsubscription/zz_controller.go +++ b/internal/controller/rds/eventsubscription/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.EventSubscription_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_event_subscription"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_event_subscription"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.EventSubscription_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.EventSubscription{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.EventSubscription{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/globalcluster/zz_controller.go b/internal/controller/rds/globalcluster/zz_controller.go index ba3a579..9eac8e2 100755 --- a/internal/controller/rds/globalcluster/zz_controller.go +++ b/internal/controller/rds/globalcluster/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.GlobalCluster_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_global_cluster"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_rds_global_cluster"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.GlobalCluster_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.GlobalCluster{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.GlobalCluster{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/instance/zz_controller.go b/internal/controller/rds/instance/zz_controller.go index 39e1a2a..6bb6671 100755 --- a/internal/controller/rds/instance/zz_controller.go +++ b/internal/controller/rds/instance/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -34,9 +39,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Instance_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Instance_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Instance_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -46,7 +53,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Instance_GroupVersionKind), opts...) @@ -54,6 +64,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Instance{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Instance{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/instanceroleassociation/zz_controller.go b/internal/controller/rds/instanceroleassociation/zz_controller.go index a0c04eb..526173c 100755 --- a/internal/controller/rds/instanceroleassociation/zz_controller.go +++ b/internal/controller/rds/instanceroleassociation/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.InstanceRoleAssociation_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.InstanceRoleAssociation_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance_role_association"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.InstanceRoleAssociation_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_instance_role_association"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.InstanceRoleAssociation_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.InstanceRoleAssociation{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.InstanceRoleAssociation{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/optiongroup/zz_controller.go b/internal/controller/rds/optiongroup/zz_controller.go index 4aa2bc9..45e4b53 100755 --- a/internal/controller/rds/optiongroup/zz_controller.go +++ b/internal/controller/rds/optiongroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.OptionGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.OptionGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_option_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.OptionGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_option_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.OptionGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.OptionGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.OptionGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/parametergroup/zz_controller.go b/internal/controller/rds/parametergroup/zz_controller.go index 09d56d5..add14d8 100755 --- a/internal/controller/rds/parametergroup/zz_controller.go +++ b/internal/controller/rds/parametergroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ParameterGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_parameter_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_parameter_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ParameterGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ParameterGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ParameterGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/proxy/zz_controller.go b/internal/controller/rds/proxy/zz_controller.go index ba4deed..7ef2423 100755 --- a/internal/controller/rds/proxy/zz_controller.go +++ b/internal/controller/rds/proxy/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Proxy_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Proxy_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Proxy_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Proxy_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Proxy{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Proxy{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/proxydefaulttargetgroup/zz_controller.go b/internal/controller/rds/proxydefaulttargetgroup/zz_controller.go index 6bece6b..e24da5d 100755 --- a/internal/controller/rds/proxydefaulttargetgroup/zz_controller.go +++ b/internal/controller/rds/proxydefaulttargetgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ProxyDefaultTargetGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyDefaultTargetGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_default_target_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyDefaultTargetGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_default_target_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ProxyDefaultTargetGroup_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ProxyDefaultTargetGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ProxyDefaultTargetGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/proxyendpoint/zz_controller.go b/internal/controller/rds/proxyendpoint/zz_controller.go index 10dabe9..ae97b28 100755 --- a/internal/controller/rds/proxyendpoint/zz_controller.go +++ b/internal/controller/rds/proxyendpoint/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ProxyEndpoint_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyEndpoint_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_endpoint"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyEndpoint_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_endpoint"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ProxyEndpoint_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ProxyEndpoint{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ProxyEndpoint{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/proxytarget/zz_controller.go b/internal/controller/rds/proxytarget/zz_controller.go index 98222ce..e398250 100755 --- a/internal/controller/rds/proxytarget/zz_controller.go +++ b/internal/controller/rds/proxytarget/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -30,9 +35,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.ProxyTarget_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyTarget_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_target"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.ProxyTarget_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_proxy_target"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -42,7 +49,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.ProxyTarget_GroupVersionKind), opts...) @@ -50,6 +60,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.ProxyTarget{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.ProxyTarget{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/snapshot/zz_controller.go b/internal/controller/rds/snapshot/zz_controller.go index a1c6d91..d61e4f3 100755 --- a/internal/controller/rds/snapshot/zz_controller.go +++ b/internal/controller/rds/snapshot/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.Snapshot_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_snapshot"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_snapshot"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.Snapshot_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.Snapshot{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.Snapshot{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/rds/subnetgroup/zz_controller.go b/internal/controller/rds/subnetgroup/zz_controller.go index 3218b59..06b9f05 100755 --- a/internal/controller/rds/subnetgroup/zz_controller.go +++ b/internal/controller/rds/subnetgroup/zz_controller.go @@ -1,3 +1,7 @@ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 + /* Copyright 2022 Upbound Inc. */ @@ -14,8 +18,9 @@ import ( "github.com/crossplane/crossplane-runtime/pkg/ratelimiter" "github.com/crossplane/crossplane-runtime/pkg/reconciler/managed" xpresource "github.com/crossplane/crossplane-runtime/pkg/resource" - tjcontroller "github.com/upbound/upjet/pkg/controller" - "github.com/upbound/upjet/pkg/terraform" + tjcontroller "github.com/crossplane/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller/handler" + "github.com/crossplane/upjet/pkg/terraform" ctrl "sigs.k8s.io/controller-runtime" v1alpha1 "kubedb.dev/provider-aws/apis/rds/v1alpha1" @@ -31,9 +36,11 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { if o.SecretStoreConfigGVK != nil { cps = append(cps, connection.NewDetailsManager(mgr.GetClient(), *o.SecretStoreConfigGVK, connection.WithTLSConfig(o.ESSOptions.TLSConfig))) } + eventHandler := handler.NewEventHandler(handler.WithLogger(o.Logger.WithValues("gvk", v1alpha1.SubnetGroup_GroupVersionKind))) + ac := tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), tjcontroller.WithEventHandler(eventHandler)) opts := []managed.ReconcilerOption{ - managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_subnet_group"], tjcontroller.WithLogger(o.Logger), - tjcontroller.WithCallbackProvider(tjcontroller.NewAPICallbacks(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind))), + managed.WithExternalConnecter(tjcontroller.NewConnector(mgr.GetClient(), o.WorkspaceStore, o.SetupFn, o.Provider.Resources["aws_db_subnet_group"], tjcontroller.WithLogger(o.Logger), tjcontroller.WithConnectorEventHandler(eventHandler), + tjcontroller.WithCallbackProvider(ac), )), managed.WithLogger(o.Logger.WithValues("controller", name)), managed.WithRecorder(event.NewAPIRecorder(mgr.GetEventRecorderFor(name))), @@ -43,7 +50,10 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { managed.WithConnectionPublishers(cps...), managed.WithPollInterval(o.PollInterval), } - if o.Features.Enabled(features.EnableAlphaManagementPolicies) { + if o.PollJitter != 0 { + opts = append(opts, managed.WithPollJitterHook(o.PollJitter)) + } + if o.Features.Enabled(features.EnableBetaManagementPolicies) { opts = append(opts, managed.WithManagementPolicies()) } r := managed.NewReconciler(mgr, xpresource.ManagedKind(v1alpha1.SubnetGroup_GroupVersionKind), opts...) @@ -51,6 +61,7 @@ func Setup(mgr ctrl.Manager, o tjcontroller.Options) error { return ctrl.NewControllerManagedBy(mgr). Named(name). WithOptions(o.ForControllerRuntime()). - For(&v1alpha1.SubnetGroup{}). + WithEventFilter(xpresource.DesiredStateChanged()). + Watches(&v1alpha1.SubnetGroup{}, eventHandler). Complete(ratelimiter.NewReconciler(name, r, o.GlobalRateLimiter)) } diff --git a/internal/controller/zz_setup.go b/internal/controller/zz_setup.go index 361192a..f4160dd 100755 --- a/internal/controller/zz_setup.go +++ b/internal/controller/zz_setup.go @@ -1,13 +1,13 @@ -/* -Copyright 2021 Upbound Inc. -*/ +// SPDX-FileCopyrightText: 2023 The Crossplane Authors +// +// SPDX-License-Identifier: Apache-2.0 package controller import ( ctrl "sigs.k8s.io/controller-runtime" - "github.com/upbound/upjet/pkg/controller" + "github.com/crossplane/upjet/pkg/controller" cluster "kubedb.dev/provider-aws/internal/controller/docdb/cluster" clusterinstance "kubedb.dev/provider-aws/internal/controller/docdb/clusterinstance" diff --git a/internal/features/features.go b/internal/features/features.go index 1b37951..96fd480 100644 --- a/internal/features/features.go +++ b/internal/features/features.go @@ -4,17 +4,19 @@ package features -import "github.com/crossplane/crossplane-runtime/pkg/feature" +import ( + xpfeature "github.com/crossplane/crossplane-runtime/pkg/feature" +) // Feature flags. const ( // EnableAlphaExternalSecretStores enables alpha support for // External Secret Stores. See the below design for more details. // https://github.com/crossplane/crossplane/blob/390ddd/design/design-doc-external-secret-stores.md - EnableAlphaExternalSecretStores feature.Flag = "EnableAlphaExternalSecretStores" + EnableAlphaExternalSecretStores xpfeature.Flag = "EnableAlphaExternalSecretStores" - // EnableAlphaManagementPolicies enables alpha support for + // EnableBetaManagementPolicies enables beta support for // Management Policies. See the below design for more details. // https://github.com/crossplane/crossplane/pull/3531 - EnableAlphaManagementPolicies feature.Flag = "EnableAlphaManagementPolicies" + EnableBetaManagementPolicies xpfeature.Flag = xpfeature.EnableBetaManagementPolicies ) diff --git a/package/crds/aws.kubedb.com_providerconfigs.yaml b/package/crds/aws.kubedb.com_providerconfigs.yaml index 0964488..931db2a 100644 --- a/package/crds/aws.kubedb.com_providerconfigs.yaml +++ b/package/crds/aws.kubedb.com_providerconfigs.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: providerconfigs.aws.kubedb.com spec: group: aws.kubedb.com @@ -139,6 +138,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map users: description: Users of this provider configuration. format: int64 diff --git a/package/crds/aws.kubedb.com_providerconfigusages.yaml b/package/crds/aws.kubedb.com_providerconfigusages.yaml index 91212a2..a667b01 100644 --- a/package/crds/aws.kubedb.com_providerconfigusages.yaml +++ b/package/crds/aws.kubedb.com_providerconfigusages.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: providerconfigusages.aws.kubedb.com spec: group: aws.kubedb.com diff --git a/package/crds/aws.kubedb.com_storeconfigs.yaml b/package/crds/aws.kubedb.com_storeconfigs.yaml index 409272a..65642fc 100644 --- a/package/crds/aws.kubedb.com_storeconfigs.yaml +++ b/package/crds/aws.kubedb.com_storeconfigs.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: storeconfigs.aws.kubedb.com spec: group: aws.kubedb.com @@ -154,146 +153,6 @@ spec: - Vault - Plugin type: string - vault: - description: 'Vault configures a Vault secret store. Deprecated: This - API is scheduled to be removed in a future release. Vault should - be used as a plugin going forward. See https://github.com/crossplane-contrib/ess-plugin-vault - for more information.' - properties: - auth: - description: Auth configures an authentication method for Vault. - properties: - method: - description: Method configures which auth method will be used. - type: string - token: - description: Token configures Token Auth for Vault. - properties: - env: - description: Env is a reference to an environment variable - that contains credentials that must be used to connect - to the provider. - properties: - name: - description: Name is the name of an environment variable. - type: string - required: - - name - type: object - fs: - description: Fs is a reference to a filesystem location - that contains credentials that must be used to connect - to the provider. - properties: - path: - description: Path is a filesystem path. - type: string - required: - - path - type: object - secretRef: - description: A SecretRef is a reference to a secret key - that contains the credentials that must be used to connect - to the provider. - properties: - key: - description: The key to select. - type: string - name: - description: Name of the secret. - type: string - namespace: - description: Namespace of the secret. - type: string - required: - - key - - name - - namespace - type: object - source: - description: Source of the credentials. - enum: - - None - - Secret - - Environment - - Filesystem - type: string - required: - - source - type: object - required: - - method - type: object - caBundle: - description: CABundle configures CA bundle for Vault Server. - properties: - env: - description: Env is a reference to an environment variable - that contains credentials that must be used to connect to - the provider. - properties: - name: - description: Name is the name of an environment variable. - type: string - required: - - name - type: object - fs: - description: Fs is a reference to a filesystem location that - contains credentials that must be used to connect to the - provider. - properties: - path: - description: Path is a filesystem path. - type: string - required: - - path - type: object - secretRef: - description: A SecretRef is a reference to a secret key that - contains the credentials that must be used to connect to - the provider. - properties: - key: - description: The key to select. - type: string - name: - description: Name of the secret. - type: string - namespace: - description: Namespace of the secret. - type: string - required: - - key - - name - - namespace - type: object - source: - description: Source of the credentials. - enum: - - None - - Secret - - Environment - - Filesystem - type: string - required: - - source - type: object - mountPath: - description: MountPath is the mount path of the KV secrets engine. - type: string - server: - description: Server is the url of the Vault server, e.g. "https://vault.acme.org" - type: string - version: - default: v2 - description: Version of the KV Secrets engine of Vault. https://www.vaultproject.io/docs/secrets/kv - type: string - required: - - auth - - mountPath - - server - type: object required: - defaultScope type: object @@ -333,6 +192,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_clusterinstances.yaml b/package/crds/docdb.aws.kubedb.com_clusterinstances.yaml index 0a60028..a971955 100644 --- a/package/crds/docdb.aws.kubedb.com_clusterinstances.yaml +++ b/package/crds/docdb.aws.kubedb.com_clusterinstances.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterinstances.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -211,21 +210,105 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + applyImmediately: + description: Specifies whether any database modifications are + applied immediately, or during the next maintenance window. + Default isfalse. + type: boolean + autoMinorVersionUpgrade: + description: This parameter does not apply to Amazon DocumentDB. + Amazon DocumentDB does not perform minor version upgrades regardless + of the value set (see docs). Default true. + type: boolean + availabilityZone: + description: The EC2 Availability Zone that the DB instance is + created in. See docs about the details. + type: string + caCertIdentifier: + description: The identifier of the CA certificate for the DB instance. + type: string + enablePerformanceInsights: + description: A value that indicates whether to enable Performance + Insights for the DB Instance. Default false. See [docs] (https://docs.aws.amazon.com/documentdb/latest/developerguide/performance-insights.html) + about the details. + type: boolean + engine: + description: 'The name of the database engine to be used for the + DocumentDB instance. Defaults to docdb. Valid Values: docdb.' + type: string + instanceClass: + description: The instance class to use. For details on CPU and + memory, see Scaling for DocumentDB Instances. DocumentDB currently + supports the below instance classes. Please see AWS Documentation + for complete details. + type: string + performanceInsightsKmsKeyId: + description: The KMS key identifier is the key ARN, key ID, alias + ARN, or alias name for the KMS key. If you do not specify a + value for PerformanceInsightsKMSKeyId, then Amazon DocumentDB + uses your default KMS key. + type: string + preferredMaintenanceWindow: + description: 'The window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". + Eg: "Mon:00:00-Mon:03:00".' + type: string + promotionTier: + description: Default 0. Failover Priority setting on instance + level. The reader who has lower tier has higher priority to + get promoter to writer. + type: number + tags: + additionalProperties: + type: string + description: A map of tags to assign to the instance. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -264,42 +347,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -398,10 +445,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: instanceClass is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.instanceClass is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.instanceClass) + || (has(self.initProvider) && has(self.initProvider.instanceClass))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterInstanceStatus defines the observed state of ClusterInstance. properties: @@ -544,6 +594,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_clusterparametergroups.yaml b/package/crds/docdb.aws.kubedb.com_clusterparametergroups.yaml index 713f3ab..268fffa 100644 --- a/package/crds/docdb.aws.kubedb.com_clusterparametergroups.yaml +++ b/package/crds/docdb.aws.kubedb.com_clusterparametergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterparametergroups.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -92,9 +91,6 @@ spec: value: description: The value of the DocumentDB parameter. type: string - required: - - name - - value type: object type: array region: @@ -116,21 +112,84 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the DocumentDB cluster parameter + group. + type: string + family: + description: The family of the DocumentDB cluster parameter group. + type: string + parameter: + description: A list of DocumentDB parameters to apply. Setting + parameters to system default values may show a difference on + imported resources. + items: + properties: + applyMethod: + description: Valid values are immediate and pending-reboot. + Defaults to pending-reboot. + type: string + name: + description: The name of the DocumentDB cluster parameter + group. + type: string + value: + description: The value of the DocumentDB parameter. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -169,42 +228,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -303,10 +326,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: family is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.family is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.family) + || (has(self.initProvider) && has(self.initProvider.family))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterParameterGroupStatus defines the observed state of ClusterParameterGroup. @@ -393,6 +419,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_clusters.yaml b/package/crds/docdb.aws.kubedb.com_clusters.yaml index 04d2e3c..66156e9 100644 --- a/package/crds/docdb.aws.kubedb.com_clusters.yaml +++ b/package/crds/docdb.aws.kubedb.com_clusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusters.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -349,21 +348,141 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + applyImmediately: + description: Specifies whether any cluster modifications are applied + immediately, or during the next maintenance window. Default + is false. + type: boolean + availabilityZones: + description: A list of EC2 Availability Zones that instances in + the DB cluster can be created in. + items: + type: string + type: array + backupRetentionPeriod: + description: The days to retain backups for. Default 1 + type: number + dbClusterParameterGroupName: + description: A cluster parameter group to associate with the cluster. + type: string + dbSubnetGroupName: + description: A DB subnet group to associate with this DB instance. + type: string + deletionProtection: + description: A value that indicates whether the DB cluster has + deletion protection enabled. The database can't be deleted when + deletion protection is enabled. By default, deletion protection + is disabled. + type: boolean + enabledCloudwatchLogsExports: + description: 'List of log types to export to cloudwatch. If omitted, + no logs will be exported. The following log types are supported: + audit, profiler.' + items: + type: string + type: array + engine: + description: 'The name of the database engine to be used for this + DB cluster. Defaults to docdb. Valid Values: docdb' + type: string + engineVersion: + description: The database engine version. Updating this argument + results in an outage. + type: string + finalSnapshotIdentifier: + description: The name of your final DB snapshot when this DB cluster + is deleted. If omitted, no final snapshot will be made. + type: string + globalClusterIdentifier: + description: The global cluster identifier specified on aws_docdb_global_cluster. + type: string + masterUsername: + description: Username for the master DB user. + type: string + port: + description: The port on which the DB accepts connections + type: number + preferredBackupWindow: + description: 'The daily time range during which automated backups + are created if automated backups are enabled using the BackupRetentionPeriod + parameter.Time in UTC Default: A 30-minute window selected at + random from an 8-hour block of time per regionE.g., 04:00-09:00' + type: string + preferredMaintenanceWindow: + description: The weekly time range during which system maintenance + can occur, in (UTC) e.g., wed:04:00-wed:04:30 + type: string + skipFinalSnapshot: + description: Determines whether a final DB snapshot is created + before the DB cluster is deleted. If true is specified, no DB + snapshot is created. If false is specified, a DB snapshot is + created before the DB cluster is deleted, using the value from + final_snapshot_identifier. Default is false. + type: boolean + snapshotIdentifier: + description: Specifies whether or not to create this cluster from + a snapshot. You can use either the name or ARN when specifying + a DB cluster snapshot, or the ARN when specifying a DB snapshot. + Automated snapshots should not be used for this attribute, unless + from a different cluster. Automated snapshots are deleted as + part of cluster destruction when the resource is replaced. + type: string + storageEncrypted: + description: Specifies whether the DB cluster is encrypted. The + default is false. + type: boolean + tags: + additionalProperties: + type: string + description: A map of tags to assign to the DB cluster. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -402,42 +521,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -536,8 +619,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterStatus defines the observed state of Cluster. properties: @@ -709,6 +793,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_clustersnapshots.yaml b/package/crds/docdb.aws.kubedb.com_clustersnapshots.yaml index 0ad6696..f1c268a 100644 --- a/package/crds/docdb.aws.kubedb.com_clustersnapshots.yaml +++ b/package/crds/docdb.aws.kubedb.com_clustersnapshots.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clustersnapshots.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -150,21 +149,43 @@ spec: be created in. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -203,42 +224,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -337,8 +322,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterSnapshotStatus defines the observed state of ClusterSnapshot. properties: @@ -426,6 +412,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_eventsubscriptions.yaml b/package/crds/docdb.aws.kubedb.com_eventsubscriptions.yaml index 89e9449..6579d7c 100644 --- a/package/crds/docdb.aws.kubedb.com_eventsubscriptions.yaml +++ b/package/crds/docdb.aws.kubedb.com_eventsubscriptions.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: eventsubscriptions.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -116,21 +115,87 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + enabled: + description: A boolean flag to enable/disable the subscription. + Defaults to true. + type: boolean + eventCategories: + description: A list of event categories for a SourceType that + you want to subscribe to. See https://docs.aws.amazon.com/documentdb/latest/developerguide/API_Event.html + or run aws docdb describe-event-categories. + items: + type: string + type: array + snsTopicArn: + description: The Amazon Resource Name of the DocumentDB event + notification subscription + type: string + sourceIds: + description: A list of identifiers of the event sources for which + events will be returned. If not specified, then all sources + are included in the response. If specified, a source_type must + also be specified. + items: + type: string + type: array + sourceType: + description: The type of source that will be generating the events. + Valid options are db-instance, db-cluster, db-parameter-group, + db-security-group, db-cluster-snapshot. If not set, all sources + will be subscribed to. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -169,42 +234,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -303,10 +332,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: snsTopicArn is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.snsTopicArn) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.snsTopicArn is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.snsTopicArn) + || (has(self.initProvider) && has(self.initProvider.snsTopicArn))' status: description: EventSubscriptionStatus defines the observed state of EventSubscription. properties: @@ -400,6 +432,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_globalclusters.yaml b/package/crds/docdb.aws.kubedb.com_globalclusters.yaml index 9678d4e..b2ddc75 100644 --- a/package/crds/docdb.aws.kubedb.com_globalclusters.yaml +++ b/package/crds/docdb.aws.kubedb.com_globalclusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: globalclusters.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -177,21 +176,71 @@ spec: and encrypted. type: boolean type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + databaseName: + description: Name for an automatically created database on cluster + creation. + type: string + deletionProtection: + description: If the Global Cluster should have deletion protection + enabled. The database can't be deleted when this value is set + to true. The default is false. + type: boolean + engine: + description: 'Name of the database engine to be used for this + DB cluster. Current Valid values: docdb. Defaults to docdb. + Conflicts with source_db_cluster_identifier.' + type: string + engineVersion: + description: Engine version of the global database. Upgrading + the engine version will result in all cluster members being + immediately updated and will. + type: string + globalClusterIdentifier: + description: The global cluster identifier. + type: string + storageEncrypted: + description: Specifies whether the DB cluster is encrypted. The + default is false unless source_db_cluster_identifier is specified + and encrypted. + type: boolean + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -230,42 +279,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -364,10 +377,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: globalClusterIdentifier is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.globalClusterIdentifier) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.globalClusterIdentifier is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.globalClusterIdentifier) + || (has(self.initProvider) && has(self.initProvider.globalClusterIdentifier))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: GlobalClusterStatus defines the observed state of GlobalCluster. properties: @@ -463,6 +479,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/docdb.aws.kubedb.com_subnetgroups.yaml b/package/crds/docdb.aws.kubedb.com_subnetgroups.yaml index c86eaa2..619ff83 100644 --- a/package/crds/docdb.aws.kubedb.com_subnetgroups.yaml +++ b/package/crds/docdb.aws.kubedb.com_subnetgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: subnetgroups.docdb.aws.kubedb.com spec: group: docdb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -172,21 +171,61 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the docDB subnet group. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -225,42 +264,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -359,8 +362,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SubnetGroupStatus defines the observed state of SubnetGroup. properties: @@ -428,6 +432,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_contributorinsights.yaml b/package/crds/dynamodb.aws.kubedb.com_contributorinsights.yaml index 7434201..99c6a91 100644 --- a/package/crds/dynamodb.aws.kubedb.com_contributorinsights.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_contributorinsights.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: contributorinsights.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -152,21 +151,47 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + indexName: + description: The global secondary index name + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -205,42 +230,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -339,8 +328,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ContributorInsightsStatus defines the observed state of ContributorInsights. properties: @@ -388,6 +378,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_globaltables.yaml b/package/crds/dynamodb.aws.kubedb.com_globaltables.yaml index c1fed26..53607cf 100644 --- a/package/crds/dynamodb.aws.kubedb.com_globaltables.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_globaltables.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: globaltables.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -81,26 +80,58 @@ spec: description: AWS region name of replica DynamoDB TableE.g., us-east-1 type: string - required: - - regionName type: object type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + replica: + description: Underlying DynamoDB Table. At least 1 replica must + be defined. See below. + items: + properties: + regionName: + description: AWS region name of replica DynamoDB TableE.g., + us-east-1 + type: string + type: object + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -139,42 +170,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -273,10 +268,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: replica is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.replica) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.replica is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.replica) + || (has(self.initProvider) && has(self.initProvider.replica))' status: description: GlobalTableStatus defines the observed state of GlobalTable. properties: @@ -333,6 +331,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_kinesisstreamingdestinations.yaml b/package/crds/dynamodb.aws.kubedb.com_kinesisstreamingdestinations.yaml index 780d840..7ca397c 100644 --- a/package/crds/dynamodb.aws.kubedb.com_kinesisstreamingdestinations.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_kinesisstreamingdestinations.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: kinesisstreamingdestinations.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -59,7 +58,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -228,21 +227,43 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -281,42 +302,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -415,8 +400,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: KinesisStreamingDestinationStatus defines the observed state of KinesisStreamingDestination. @@ -469,6 +455,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_tableitems.yaml b/package/crds/dynamodb.aws.kubedb.com_tableitems.yaml index 003ba06..fa56558 100644 --- a/package/crds/dynamodb.aws.kubedb.com_tableitems.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_tableitems.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: tableitems.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -163,21 +162,58 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + hashKey: + description: Hash key to use for lookups and identification of + the item + type: string + item: + description: JSON representation of a map of attribute name/value + pairs, one for each attribute. Only the primary key attributes + are required; you can optionally provide other attribute name-value + pairs for the item. + type: string + rangeKey: + description: Range key to use for lookups and identification of + the item. Required if there is range key defined in the table. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -216,42 +252,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -350,12 +350,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: hashKey is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.hashKey) - - message: item is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.item) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.hashKey is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.hashKey) + || (has(self.initProvider) && has(self.initProvider.hashKey))' + - message: spec.forProvider.item is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.item) + || (has(self.initProvider) && has(self.initProvider.item))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: TableItemStatus defines the observed state of TableItem. properties: @@ -414,6 +419,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_tablereplicas.yaml b/package/crds/dynamodb.aws.kubedb.com_tablereplicas.yaml index d9fe84f..2f48347 100644 --- a/package/crds/dynamodb.aws.kubedb.com_tablereplicas.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_tablereplicas.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: tablereplicas.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -253,21 +252,67 @@ spec: inherited from the provider default_tags configuration block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + pointInTimeRecovery: + description: Whether to enable Point In Time Recovery for the + replica. Default is false. + type: boolean + tableClassOverride: + description: Storage class of the table replica. Valid values + are STANDARD and STANDARD_INFREQUENT_ACCESS. If not used, the + table replica will use the same class as the global table. + type: string + tags: + additionalProperties: + type: string + description: Map of tags to populate on the created table. If + configured with a provider default_tags configuration block + present, tags with matching keys will overwrite those defined + at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -306,42 +351,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -440,8 +449,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: TableReplicaStatus defines the observed state of TableReplica. properties: @@ -522,6 +532,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_tables.yaml b/package/crds/dynamodb.aws.kubedb.com_tables.yaml index 55874de..161e5ff 100644 --- a/package/crds/dynamodb.aws.kubedb.com_tables.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_tables.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: tables.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -80,9 +79,6 @@ spec: description: Attribute type. Valid values are S (string), N (number), B (binary). type: string - required: - - name - - type type: object type: array billingMode: @@ -133,10 +129,6 @@ spec: description: Number of write units for this index. Must be set if billing_mode is set to PROVISIONED. type: number - required: - - hashKey - - name - - projectionType type: object type: array hashKey: @@ -170,10 +162,6 @@ spec: rangeKey: description: Name of the range key. type: string - required: - - name - - projectionType - - rangeKey type: object type: array pointInTimeRecovery: @@ -185,8 +173,6 @@ spec: can take 10 minutes to enable for new tables. If the point_in_time_recovery block is not provided, this defaults to false. type: boolean - required: - - enabled type: object type: array rangeKey: @@ -231,8 +217,6 @@ spec: regionName: description: Region name of the replica. type: string - required: - - regionName type: object type: array restoreDateTime: @@ -270,8 +254,6 @@ spec: key, alias/aws/dynamodb. Note: This attribute will not be populated with the ARN of default keys.' type: string - required: - - enabled type: object type: array streamEnabled: @@ -311,8 +293,6 @@ spec: enabled: description: Whether TTL is enabled. type: boolean - required: - - attributeName type: object type: array writeCapacity: @@ -320,21 +300,272 @@ spec: is PROVISIONED, this field is required. type: number type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + attribute: + description: Set of nested attribute definitions. Only required + for hash_key and range_key attributes. See below. + items: + properties: + name: + description: Name of the attribute + type: string + type: + description: Attribute type. Valid values are S (string), + N (number), B (binary). + type: string + type: object + type: array + billingMode: + description: Controls how you are charged for read and write throughput + and how you manage capacity. The valid values are PROVISIONED + and PAY_PER_REQUEST. Defaults to PROVISIONED. + type: string + deletionProtectionEnabled: + description: Enables deletion protection for table. Defaults to + false. + type: boolean + globalSecondaryIndex: + description: Describe a GSI for the table; subject to the normal + limits on the number of GSIs, projected attributes, etc. See + below. + items: + properties: + hashKey: + description: Name of the hash key in the index; must be + defined as an attribute in the resource. + type: string + name: + description: Name of the index. + type: string + nonKeyAttributes: + description: Only required with INCLUDE as a projection + type; a list of attributes to project into the index. + These do not need to be defined as attributes on the table. + items: + type: string + type: array + projectionType: + description: One of ALL, INCLUDE or KEYS_ONLY where ALL + projects every attribute into the index, KEYS_ONLY projects into + the index only the table and index hash_key and sort_key + attributes , INCLUDE projects into the index all of the + attributes that are defined in non_key_attributes in addition + to the attributes that thatKEYS_ONLY project. + type: string + rangeKey: + description: Name of the range key; must be defined + type: string + readCapacity: + description: Number of read units for this index. Must be + set if billing_mode is set to PROVISIONED. + type: number + writeCapacity: + description: Number of write units for this index. Must + be set if billing_mode is set to PROVISIONED. + type: number + type: object + type: array + hashKey: + description: Attribute to use as the hash (partition) key. Must + also be defined as an attribute. See below. + type: string + localSecondaryIndex: + description: Describe an LSI on the table; these can only be allocated + at creation so you cannot change this definition after you have + created the resource. See below. + items: + properties: + name: + description: Name of the index + type: string + nonKeyAttributes: + description: Only required with INCLUDE as a projection + type; a list of attributes to project into the index. + These do not need to be defined as attributes on the table. + items: + type: string + type: array + projectionType: + description: One of ALL, INCLUDE or KEYS_ONLY where ALL + projects every attribute into the index, KEYS_ONLY projects into + the index only the table and index hash_key and sort_key + attributes , INCLUDE projects into the index all of the + attributes that are defined in non_key_attributes in addition + to the attributes that thatKEYS_ONLY project. + type: string + rangeKey: + description: Name of the range key. + type: string + type: object + type: array + pointInTimeRecovery: + description: Enable point-in-time recovery options. See below. + items: + properties: + enabled: + description: Whether to enable point-in-time recovery. It + can take 10 minutes to enable for new tables. If the point_in_time_recovery + block is not provided, this defaults to false. + type: boolean + type: object + type: array + rangeKey: + description: Attribute to use as the range (sort) key. Must also + be defined as an attribute, see below. + type: string + readCapacity: + description: Number of read units for this table. If the billing_mode + is PROVISIONED, this field is required. + type: number + replica: + description: Configuration block(s) with DynamoDB Global Tables + V2 (version 2019.11.21) replication configurations. See below. + items: + properties: + kmsKeyArn: + description: 'ARN of the CMK that should be used for the + AWS KMS encryption. This argument should only be used + if the key is different from the default KMS-managed DynamoDB + key, alias/aws/dynamodb. Note: This attribute will not + be populated with the ARN of default keys.' + type: string + pointInTimeRecovery: + description: Whether to enable Point In Time Recovery for + the replica. Default is false. + type: boolean + propagateTags: + description: 'Whether to propagate the global table''s tags + to a replica. Default is false. Changes to tags only move + in one direction: from global (source) to replica. In + other words, tag drift on a replica will not trigger an + update. Tag or replica changes on the global table, whether + from drift or configuration changes, are propagated to + replicas. Changing from true to false on a subsequent + apply means replica tags are left as they were, unmanaged, + not deleted.' + type: boolean + regionName: + description: Region name of the replica. + type: string + type: object + type: array + restoreDateTime: + description: Time of the point-in-time recovery point to restore. + type: string + restoreSourceName: + description: Name of the table to restore. Must match the name + of an existing table. + type: string + restoreToLatestTime: + description: If set, restores table to the most recent point-in-time + recovery point. + type: boolean + serverSideEncryption: + description: Encryption at rest options. AWS DynamoDB tables are + automatically encrypted at rest with an AWS-owned Customer Master + Key if this argument isn't specified. See below. + items: + properties: + enabled: + description: Whether or not to enable encryption at rest + using an AWS managed KMS customer master key (CMK). If + enabled is false then server-side encryption is set to + AWS-owned key (shown as DEFAULT in the AWS console). Potentially + confusingly, if enabled is true and no kms_key_arn is + specified then server-side encryption is set to the default + KMS-managed key (shown as KMS in the AWS console). The + AWS KMS documentation explains the difference between + AWS-owned and KMS-managed keys. + type: boolean + kmsKeyArn: + description: 'ARN of the CMK that should be used for the + AWS KMS encryption. This argument should only be used + if the key is different from the default KMS-managed DynamoDB + key, alias/aws/dynamodb. Note: This attribute will not + be populated with the ARN of default keys.' + type: string + type: object + type: array + streamEnabled: + description: Whether Streams are enabled. + type: boolean + streamViewType: + description: When an item in the table is modified, StreamViewType + determines what information is written to the table's stream. + Valid values are KEYS_ONLY, NEW_IMAGE, OLD_IMAGE, NEW_AND_OLD_IMAGES. + type: string + tableClass: + description: Storage class of the table. Valid values are STANDARD + and STANDARD_INFREQUENT_ACCESS. Default value is STANDARD. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to populate on the created table. If + configured with a provider default_tags configuration block + present, tags with matching keys will overwrite those defined + at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + ttl: + description: Configuration block for TTL. See below. + items: + properties: + attributeName: + description: Name of the table attribute to store the TTL + timestamp in. + type: string + enabled: + description: Whether TTL is enabled. + type: boolean + type: object + type: array + writeCapacity: + description: Number of write units for this table. If the billing_mode + is PROVISIONED, this field is required. + type: number + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -373,42 +604,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -507,8 +702,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: TableStatus defines the observed state of Table. properties: @@ -809,6 +1005,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/dynamodb.aws.kubedb.com_tags.yaml b/package/crds/dynamodb.aws.kubedb.com_tags.yaml index 5679b12..9a7d0a3 100644 --- a/package/crds/dynamodb.aws.kubedb.com_tags.yaml +++ b/package/crds/dynamodb.aws.kubedb.com_tags.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: tags.dynamodb.aws.kubedb.com spec: group: dynamodb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -86,21 +85,47 @@ spec: - key - resourceArn type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + value: + description: Tag value. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -139,42 +164,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -273,10 +262,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: value is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.value) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.value is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.value) + || (has(self.initProvider) && has(self.initProvider.value))' status: description: TagStatus defines the observed state of Tag. properties: @@ -330,6 +322,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_routes.yaml b/package/crds/ec2.aws.kubedb.com_routes.yaml index a819f2b..047c42c 100644 --- a/package/crds/ec2.aws.kubedb.com_routes.yaml +++ b/package/crds/ec2.aws.kubedb.com_routes.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: routes.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -119,21 +118,90 @@ spec: description: Identifier of a VPC peering connection. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + carrierGatewayId: + description: Identifier of a carrier gateway. This attribute can + only be used when the VPC contains a subnet which is associated + with a Wavelength Zone. + type: string + coreNetworkArn: + description: The Amazon Resource Name (ARN) of a core network. + type: string + destinationCidrBlock: + description: The destination CIDR block. + type: string + destinationIpv6CidrBlock: + description: The destination IPv6 CIDR block. + type: string + destinationPrefixListId: + description: The ID of a managed prefix list destination. + type: string + egressOnlyGatewayId: + description: Identifier of a VPC Egress Only Internet Gateway. + type: string + gatewayId: + description: Identifier of a VPC internet gateway or a virtual + private gateway. Specify local when updating a previously imported + local route. + type: string + localGatewayId: + description: Identifier of a Outpost local gateway. + type: string + natGatewayId: + description: Identifier of a VPC NAT gateway. + type: string + networkInterfaceId: + description: Identifier of an EC2 network interface. + type: string + routeTableId: + description: The ID of the routing table. + type: string + transitGatewayId: + description: Identifier of an EC2 Transit Gateway. + type: string + vpcEndpointId: + description: Identifier of a VPC Endpoint. + type: string + vpcPeeringConnectionId: + description: Identifier of a VPC peering connection. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -172,42 +240,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -306,10 +338,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: routeTableId is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.routeTableId) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.routeTableId is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.routeTableId) + || (has(self.initProvider) && has(self.initProvider.routeTableId))' status: description: RouteStatus defines the observed state of Route. properties: @@ -412,6 +447,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_securitygrouprules.yaml b/package/crds/ec2.aws.kubedb.com_securitygrouprules.yaml index d406df0..71afbd8 100644 --- a/package/crds/ec2.aws.kubedb.com_securitygrouprules.yaml +++ b/package/crds/ec2.aws.kubedb.com_securitygrouprules.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: securitygrouprules.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -194,21 +193,89 @@ spec: (inbound) or egress (outbound). type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + cidrBlocks: + description: List of CIDR blocks. Cannot be specified with source_security_group_id + or self. + items: + type: string + type: array + description: + description: Description of the rule. + type: string + fromPort: + description: Start port (or ICMP type number if protocol is "icmp" + or "icmpv6"). + type: number + ipv6CidrBlocks: + description: List of IPv6 CIDR blocks. Cannot be specified with + source_security_group_id or self. + items: + type: string + type: array + prefixListIds: + description: List of Prefix List IDs. + items: + type: string + type: array + protocol: + description: Protocol. If not icmp, icmpv6, tcp, udp, or all use + the protocol number + type: string + self: + description: Whether the security group itself will be added as + a source to this ingress rule. Cannot be specified with cidr_blocks, + ipv6_cidr_blocks, or source_security_group_id. + type: boolean + sourceSecurityGroupId: + description: Security group id to allow access to/from, depending + on the type. Cannot be specified with cidr_blocks, ipv6_cidr_blocks, + or self. + type: string + toPort: + description: End port (or ICMP code if protocol is "icmp"). + type: number + type: + description: Type of rule being created. Valid options are ingress + (inbound) or egress (outbound). + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -247,42 +314,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -381,16 +412,25 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: fromPort is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.fromPort) - - message: protocol is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.protocol) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: toPort is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.toPort) - - message: type is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.type) + - message: spec.forProvider.fromPort is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.fromPort) + || (has(self.initProvider) && has(self.initProvider.fromPort))' + - message: spec.forProvider.protocol is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.protocol) + || (has(self.initProvider) && has(self.initProvider.protocol))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.toPort is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.toPort) + || (has(self.initProvider) && has(self.initProvider.toPort))' + - message: spec.forProvider.type is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.type) + || (has(self.initProvider) && has(self.initProvider.type))' status: description: SecurityGroupRuleStatus defines the observed state of SecurityGroupRule. properties: @@ -486,6 +526,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_securitygroups.yaml b/package/crds/ec2.aws.kubedb.com_securitygroups.yaml index cb82e0c..6744c2a 100644 --- a/package/crds/ec2.aws.kubedb.com_securitygroups.yaml +++ b/package/crds/ec2.aws.kubedb.com_securitygroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: securitygroups.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -296,21 +295,191 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: 'Security group description. Cannot be "". NOTE: + This field maps to the AWS GroupDescription attribute, for which + there is no Update API. If you''d like to classify your security + groups in a way that can be updated, use tags.' + type: string + egress: + description: Configuration block for egress rules. Can be specified + multiple times for each egress rule. Each egress block supports + fields documented below. This argument is processed in attribute-as-blocks + mode. + items: + properties: + cidrBlocks: + description: List of CIDR blocks. + items: + type: string + type: array + description: + description: 'Security group description. Cannot be "". + NOTE: This field maps to the AWS GroupDescription attribute, + for which there is no Update API. If you''d like to classify + your security groups in a way that can be updated, use + tags.' + type: string + fromPort: + description: Start port (or ICMP type number if protocol + is icmp or icmpv6). + type: number + ipv6CidrBlocks: + description: List of IPv6 CIDR blocks. + items: + type: string + type: array + prefixListIds: + description: List of Prefix List IDs. + items: + type: string + type: array + protocol: + description: Protocol. If you select a protocol of -1 (semantically + equivalent to all, which is not a valid value here), you + must specify a from_port and to_port equal to 0. The + supported values are defined in the IpProtocol argument + on the IpPermission API reference.12. + type: string + securityGroups: + description: List of security groups. A group name can be + used relative to the default VPC. Otherwise, group ID. + items: + type: string + type: array + self: + description: Whether the security group itself will be added + as a source to this ingress rule. + type: boolean + toPort: + description: End range port (or ICMP code if protocol is + icmp). + type: number + type: object + type: array + ingress: + description: Configuration block for ingress rules. Can be specified + multiple times for each ingress rule. Each ingress block supports + fields documented below. This argument is processed in attribute-as-blocks + mode. + items: + properties: + cidrBlocks: + description: List of CIDR blocks. + items: + type: string + type: array + description: + description: 'Security group description. Cannot be "". + NOTE: This field maps to the AWS GroupDescription attribute, + for which there is no Update API. If you''d like to classify + your security groups in a way that can be updated, use + tags.' + type: string + fromPort: + description: Start port (or ICMP type number if protocol + is icmp or icmpv6). + type: number + ipv6CidrBlocks: + description: List of IPv6 CIDR blocks. + items: + type: string + type: array + prefixListIds: + description: List of Prefix List IDs. + items: + type: string + type: array + protocol: + description: Protocol. If you select a protocol of -1 (semantically + equivalent to all, which is not a valid value here), you + must specify a from_port and to_port equal to 0. The + supported values are defined in the IpProtocol argument + on the IpPermission API reference.12. + type: string + securityGroups: + description: List of security groups. A group name can be + used relative to the default VPC. Otherwise, group ID. + items: + type: string + type: array + self: + description: Whether the security group itself will be added + as a source to this ingress rule. + type: boolean + toPort: + description: End range port (or ICMP code if protocol is + icmp). + type: number + type: object + type: array + name: + description: Name of the security group. + type: string + namePrefix: + description: Creates a unique name beginning with the specified + prefix. Conflicts with name. + type: string + revokeRulesOnDelete: + description: This is normally not needed, however certain AWS + services such as Elastic Map Reduce may automatically add required + rules to security groups used with the service, and those rules + may contain a cyclic dependency that prevent the security groups + from being destroyed without removing the dependency first. + Default false. + type: boolean + tags: + additionalProperties: + type: string + description: Map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -349,42 +518,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -483,8 +616,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SecurityGroupStatus defines the observed state of SecurityGroup. properties: @@ -683,6 +817,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_subnets.yaml b/package/crds/ec2.aws.kubedb.com_subnets.yaml index 31c5fe2..1cb577e 100644 --- a/package/crds/ec2.aws.kubedb.com_subnets.yaml +++ b/package/crds/ec2.aws.kubedb.com_subnets.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: subnets.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -233,21 +232,128 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + assignIpv6AddressOnCreation: + description: Specify true to indicate that network interfaces + created in the specified subnet should be assigned an IPv6 address. + Default is false + type: boolean + availabilityZone: + description: AZ for the subnet. + type: string + availabilityZoneId: + description: AZ ID of the subnet. This argument is not supported + in all regions or partitions. If necessary, use availability_zone + instead. + type: string + cidrBlock: + description: The IPv4 CIDR block for the subnet. + type: string + customerOwnedIpv4Pool: + description: The customer owned IPv4 address pool. Typically used + with the map_customer_owned_ip_on_launch argument. The outpost_arn + argument must be specified when configured. + type: string + enableDns64: + description: 'Indicates whether DNS queries made to the Amazon-provided + DNS Resolver in this subnet should return synthetic IPv6 addresses + for IPv4-only destinations. Default: false.' + type: boolean + enableLniAtDeviceIndex: + description: Indicates the device position for local network interfaces + in this subnet. For example, 1 indicates local network interfaces + in this subnet are the secondary network interface (eth1). A + local network interface cannot be the primary network interface + (eth0). + type: number + enableResourceNameDnsARecordOnLaunch: + description: 'Indicates whether to respond to DNS queries for + instance hostnames with DNS A records. Default: false.' + type: boolean + enableResourceNameDnsAaaaRecordOnLaunch: + description: 'Indicates whether to respond to DNS queries for + instance hostnames with DNS AAAA records. Default: false.' + type: boolean + ipv6CidrBlock: + description: The IPv6 network range for the subnet, in CIDR notation. + The subnet size must use a /64 prefix length. + type: string + ipv6Native: + description: 'Indicates whether to create an IPv6-only subnet. + Default: false.' + type: boolean + mapCustomerOwnedIpOnLaunch: + description: Specify true to indicate that network interfaces + created in the subnet should be assigned a customer owned IP + address. The customer_owned_ipv4_pool and outpost_arn arguments + must be specified when set to true. Default is false. + type: boolean + mapPublicIpOnLaunch: + description: Specify true to indicate that instances launched + into the subnet should be assigned a public IP address. Default + is false. + type: boolean + outpostArn: + description: The Amazon Resource Name (ARN) of the Outpost. + type: string + privateDnsHostnameTypeOnLaunch: + description: 'The type of hostnames to assign to instances in + the subnet at launch. For IPv6-only subnets, an instance DNS + name must be based on the instance ID. For dual-stack and IPv4-only + subnets, you can specify whether DNS names use the instance + IPv4 address or the instance ID. Valid values: ip-name, resource-name.' + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -286,42 +392,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -420,8 +490,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SubnetStatus defines the observed state of Subnet. properties: @@ -560,6 +631,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_vpcendpoints.yaml b/package/crds/ec2.aws.kubedb.com_vpcendpoints.yaml index 87fe0e4..d3ef6bf 100644 --- a/package/crds/ec2.aws.kubedb.com_vpcendpoints.yaml +++ b/package/crds/ec2.aws.kubedb.com_vpcendpoints.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: vpcendpoints.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -378,21 +377,104 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + autoAccept: + description: Accept the VPC endpoint (the VPC endpoint and service + need to be in the same AWS account). + type: boolean + dnsOptions: + description: The DNS options for the endpoint. See dns_options + below. + items: + properties: + dnsRecordIpType: + description: The DNS records created for the endpoint. Valid + values are ipv4, dualstack, service-defined, and ipv6. + type: string + type: object + type: array + ipAddressType: + description: The IP address type for the endpoint. Valid values + are ipv4, dualstack, and ipv6. + type: string + policy: + description: A policy to attach to the endpoint that controls + access to the service. This is a JSON formatted string. Defaults + to full access. All Gateway and some Interface endpoints support + policies - see the relevant AWS documentation for more details. + type: string + privateDnsEnabled: + description: Whether or not to associate a private hosted zone + with the specified VPC. Applicable for endpoints of type Interface. + Defaults to false. + type: boolean + routeTableIds: + description: One or more route table IDs. Applicable for endpoints + of type Gateway. + items: + type: string + type: array + serviceName: + description: The service name. For AWS services the service name + is usually in the form com.amazonaws.. (the + SageMaker Notebook service is an exception to this rule, the + service name is in the form aws.sagemaker..notebook). + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + vpcEndpointType: + description: The VPC endpoint type, Gateway, GatewayLoadBalancer, + or Interface. Defaults to Gateway. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -431,42 +513,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -565,10 +611,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: serviceName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.serviceName) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.serviceName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.serviceName) + || (has(self.initProvider) && has(self.initProvider.serviceName))' status: description: VPCEndpointStatus defines the observed state of VPCEndpoint. properties: @@ -731,6 +780,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_vpcpeeringconnections.yaml b/package/crds/ec2.aws.kubedb.com_vpcpeeringconnections.yaml index 3fe2914..d5911f8 100644 --- a/package/crds/ec2.aws.kubedb.com_vpcpeeringconnections.yaml +++ b/package/crds/ec2.aws.kubedb.com_vpcpeeringconnections.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: vpcpeeringconnections.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -280,21 +279,98 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + accepter: + description: An optional configuration block that allows for VPC + Peering Connection options to be set for the VPC that accepts + the peering connection (a maximum of one). + items: + properties: + allowRemoteVpcDnsResolution: + description: Allow a local VPC to resolve public DNS hostnames + to private IP addresses when queried from instances in + the peer VPC. + type: boolean + type: object + type: array + autoAccept: + description: Accept the peering (both VPCs need to be in the same + AWS account and region). + type: boolean + peerOwnerId: + description: The AWS account ID of the owner of the peer VPC. + Defaults to the account ID the AWS provider is currently connected + to. + type: string + peerRegion: + description: The region of the accepter VPC of the VPC Peering + Connection. auto_accept must be false, and use the aws_vpc_peering_connection_accepter + to manage the accepter side. + type: string + requester: + description: A optional configuration block that allows for VPC + Peering Connection options to be set for the VPC that requests + the peering connection (a maximum of one). + items: + properties: + allowRemoteVpcDnsResolution: + description: Allow a local VPC to resolve public DNS hostnames + to private IP addresses when queried from instances in + the peer VPC. + type: boolean + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -333,42 +409,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -467,8 +507,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: VPCPeeringConnectionStatus defines the observed state of VPCPeeringConnection. @@ -576,6 +617,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/ec2.aws.kubedb.com_vpcs.yaml b/package/crds/ec2.aws.kubedb.com_vpcs.yaml index 5f40483..67eecf1 100644 --- a/package/crds/ec2.aws.kubedb.com_vpcs.yaml +++ b/package/crds/ec2.aws.kubedb.com_vpcs.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: vpcs.ec2.aws.kubedb.com spec: group: ec2.aws.kubedb.com @@ -57,7 +56,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -150,21 +149,122 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + assignGeneratedIpv6CidrBlock: + description: Requests an Amazon-provided IPv6 CIDR block with + a /56 prefix length for the VPC. You cannot specify the range + of IP addresses, or the size of the CIDR block. Default is false. + Conflicts with ipv6_ipam_pool_id + type: boolean + cidrBlock: + description: The IPv4 CIDR block for the VPC. CIDR can be explicitly + set or it can be derived from IPAM using ipv4_netmask_length. + type: string + enableDnsHostnames: + description: A boolean flag to enable/disable DNS hostnames in + the VPC. Defaults false. + type: boolean + enableDnsSupport: + description: A boolean flag to enable/disable DNS support in the + VPC. Defaults to true. + type: boolean + enableNetworkAddressUsageMetrics: + description: Indicates whether Network Address Usage metrics are + enabled for your VPC. Defaults to false. + type: boolean + instanceTenancy: + description: A tenancy option for instances launched into the + VPC. Default is default, which ensures that EC2 instances launched + in this VPC use the EC2 instance tenancy attribute specified + when the EC2 instance is launched. The only other option is + dedicated, which ensures that EC2 instances launched in this + VPC are run on dedicated tenancy instances regardless of the + tenancy attribute specified at launch. This has a dedicated + per region fee of $2 per hour, plus an hourly per instance usage + fee. + type: string + ipv4IpamPoolId: + description: The ID of an IPv4 IPAM pool you want to use for allocating + this VPC's CIDR. IPAM is a VPC feature that you can use to automate + your IP address management workflows including assigning, tracking, + troubleshooting, and auditing IP addresses across AWS Regions + and accounts. Using IPAM you can monitor IP address usage throughout + your AWS Organization. + type: string + ipv4NetmaskLength: + description: The netmask length of the IPv4 CIDR you want to allocate + to this VPC. Requires specifying a ipv4_ipam_pool_id. + type: number + ipv6CidrBlock: + description: IPv6 CIDR block to request from an IPAM Pool. Can + be set explicitly or derived from IPAM using ipv6_netmask_length. + type: string + ipv6CidrBlockNetworkBorderGroup: + description: By default when an IPv6 CIDR is assigned to a VPC + a default ipv6_cidr_block_network_border_group will be set to + the region of the VPC. This can be changed to restrict advertisement + of public addresses to specific Network Border Groups such as + LocalZones. + type: string + ipv6IpamPoolId: + description: IPAM Pool ID for a IPv6 pool. Conflicts with assign_generated_ipv6_cidr_block. + type: string + ipv6NetmaskLength: + description: 'Netmask length to request from IPAM Pool. Conflicts + with ipv6_cidr_block. This can be omitted if IPAM pool as a + allocation_default_netmask_length set. Valid values: 56.' + type: number + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -203,42 +303,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -337,8 +401,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: VPCStatus defines the observed state of VPC. properties: @@ -488,6 +553,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_clusters.yaml b/package/crds/elasticache.aws.kubedb.com_clusters.yaml index f260edb..62eb5ec 100644 --- a/package/crds/elasticache.aws.kubedb.com_clusters.yaml +++ b/package/crds/elasticache.aws.kubedb.com_clusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusters.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -138,11 +137,6 @@ spec: description: Valid values are slow-log or engine-log. Max 1 of each. type: string - required: - - destination - - destinationType - - logFormat - - logType type: object type: array maintenanceWindow: @@ -561,21 +555,205 @@ spec: inherited from the provider default_tags configuration block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + applyImmediately: + description: Whether any database modifications are applied immediately, + or during the next maintenance window. Default is false. See + Amazon ElastiCache Documentation for more information.. + type: boolean + autoMinorVersionUpgrade: + description: Specifies whether minor version engine upgrades will + be applied automatically to the underlying Cache Cluster instances + during the maintenance window. Only supported for engine type + "redis" and if the engine version is 6 or higher. Defaults to + true. + type: string + availabilityZone: + description: 'Availability Zone for the cache cluster. If you + want to create cache nodes in multi-az, use preferred_availability_zones + instead. Default: System chosen Availability Zone. Changing + this value will re-create the resource.' + type: string + azMode: + description: Whether the nodes in this Memcached node group are + created in a single Availability Zone or created across multiple + Availability Zones in the cluster's region. Valid values for + this parameter are single-az or cross-az, default is single-az. + If you want to choose cross-az, num_cache_nodes must be greater + than 1. + type: string + engine: + description: – Name of the cache engine to be used for this cache + cluster. Valid values are memcached or redis. + type: string + engineVersion: + description: – Version number of the cache engine to be used. + If not set, defaults to the latest version. See Describe Cache + Engine Versions in the AWS Documentation for supported versions. + When engine is redis and the version is 6 or higher, the major + and minor version can be set, e.g., 6.2, or the minor version + can be unspecified which will use the latest version at creation + time, e.g., 6.x. Otherwise, specify the full version desired, + e.g., 5.0.6. The actual engine version used is returned in the + attribute engine_version_actual, see Attributes Reference below. + type: string + finalSnapshotIdentifier: + description: Name of your final cluster snapshot. If omitted, + no final snapshot will be made. + type: string + ipDiscovery: + description: The IP version to advertise in the discovery protocol. + Valid values are ipv4 or ipv6. + type: string + logDeliveryConfiguration: + description: Specifies the destination and format of Redis SLOWLOG + or Redis Engine Log. See the documentation on Amazon ElastiCache. + See Log Delivery Configuration below for more details. + items: + properties: + destination: + description: Name of either the CloudWatch Logs LogGroup + or Kinesis Data Firehose resource. + type: string + destinationType: + description: For CloudWatch Logs use cloudwatch-logs or + for Kinesis Data Firehose use kinesis-firehose. + type: string + logFormat: + description: Valid values are json or text + type: string + logType: + description: Valid values are slow-log or engine-log. Max + 1 of each. + type: string + type: object + type: array + maintenanceWindow: + description: 'ddd:hh24:mi (24H Clock UTC). The minimum maintenance + window is a 60 minute period. Example: sun:05:00-sun:09:00.' + type: string + networkType: + description: The IP versions for cache cluster connections. IPv6 + is supported with Redis engine 6.2 onword or Memcached version + 1.6.6 for all Nitro system instances. Valid values are ipv4, + ipv6 or dual_stack. + type: string + nodeType: + description: create the resource. + type: string + notificationTopicArn: + description: east-1:012345678999:my_sns_topic. + type: string + numCacheNodes: + description: – The initial number of cache nodes that the cache + cluster will have. For Redis, this value must be 1. For Memcached, + this value must be between 1 and 40. If this number is reduced + on subsequent runs, the highest numbered nodes will be removed. + type: number + outpostMode: + description: Specify the outpost mode that will apply to the cache + cluster creation. Valid values are "single-outpost" and "cross-outpost", + however AWS currently only supports "single-outpost" mode. + type: string + port: + description: create the resource. + type: number + preferredAvailabilityZones: + description: 'List of the Availability Zones in which cache nodes + are created. If you are creating your cluster in an Amazon VPC + you can only locate nodes in Availability Zones that are associated + with the subnets in the selected subnet group. The number of + Availability Zones listed must equal the value of num_cache_nodes. + If you want all the nodes in the same Availability Zone, use + availability_zone instead, or repeat the Availability Zone multiple + times in the list. Default: System chosen Availability Zones. + Detecting drift of existing node availability zone is not currently + supported. Updating this argument by itself to migrate existing + node availability zones is not currently supported and will + show a perpetual difference.' + items: + type: string + type: array + preferredOutpostArn: + description: The outpost ARN in which the cache cluster will be + created. + type: string + snapshotArns: + description: element string list containing an Amazon Resource + Name (ARN) of a Redis RDB snapshot file stored in Amazon S3. + The object name cannot contain any commas. Changing snapshot_arns + forces a new resource. + items: + type: string + type: array + snapshotName: + description: Name of a snapshot from which to restore data into + the new node group. Changing snapshot_name forces a new resource. + type: string + snapshotRetentionLimit: + description: Number of days for which ElastiCache will retain + automatic cache cluster snapshots before deleting them. For + example, if you set SnapshotRetentionLimit to 5, then a snapshot + that was taken today will be retained for 5 days before being + deleted. If the value of SnapshotRetentionLimit is set to zero + (0), backups are turned off. Please note that setting a snapshot_retention_limit + is not supported on cache.t1.micro cache nodes + type: number + snapshotWindow: + description: 'Daily time range (in UTC) during which ElastiCache + will begin taking a daily snapshot of your cache cluster. Example: + 05:00-09:00' + type: string + tags: + additionalProperties: + type: string + description: Map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -614,42 +792,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -748,8 +890,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterStatus defines the observed state of Cluster. properties: @@ -1011,6 +1154,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_parametergroups.yaml b/package/crds/elasticache.aws.kubedb.com_parametergroups.yaml index c957e65..422db74 100644 --- a/package/crds/elasticache.aws.kubedb.com_parametergroups.yaml +++ b/package/crds/elasticache.aws.kubedb.com_parametergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: parametergroups.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -87,9 +86,6 @@ spec: value: description: The value of the ElastiCache parameter. type: string - required: - - name - - value type: object type: array region: @@ -111,21 +107,79 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the ElastiCache parameter group. + type: string + family: + description: The family of the ElastiCache parameter group. + type: string + name: + description: The name of the ElastiCache parameter group. + type: string + parameter: + description: A list of ElastiCache parameters to apply. + items: + properties: + name: + description: The name of the ElastiCache parameter group. + type: string + value: + description: The value of the ElastiCache parameter. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: Key-value mapping of resource tags. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -164,42 +218,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -298,12 +316,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: family is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family) - - message: name is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.name) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.family is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.family) + || (has(self.initProvider) && has(self.initProvider.family))' + - message: spec.forProvider.name is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.name) + || (has(self.initProvider) && has(self.initProvider.name))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ParameterGroupStatus defines the observed state of ParameterGroup. properties: @@ -384,6 +407,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_replicationgroups.yaml b/package/crds/elasticache.aws.kubedb.com_replicationgroups.yaml index dd37162..2a26ad2 100644 --- a/package/crds/elasticache.aws.kubedb.com_replicationgroups.yaml +++ b/package/crds/elasticache.aws.kubedb.com_replicationgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: replicationgroups.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -242,11 +241,6 @@ spec: description: Valid values are slow-log or engine-log. Max 1 of each. type: string - required: - - destination - - destinationType - - logFormat - - logType type: object type: array maintenanceWindow: @@ -528,21 +522,236 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + applyImmediately: + description: Specifies whether any modifications are applied immediately, + or during the next maintenance window. Default is false. + type: boolean + atRestEncryptionEnabled: + description: Whether to enable encryption at rest. + type: boolean + autoMinorVersionUpgrade: + description: Specifies whether minor version engine upgrades will + be applied automatically to the underlying Cache Cluster instances + during the maintenance window. Only supported for engine type + "redis" and if the engine version is 6 or higher. Defaults to + true. + type: string + automaticFailoverEnabled: + description: Specifies whether a read-only replica will be automatically + promoted to read/write primary if the existing primary fails. + If enabled, num_cache_clusters must be greater than 1. Must + be enabled for Redis (cluster mode enabled) replication groups. + Defaults to false. + type: boolean + dataTieringEnabled: + description: Enables data tiering. Data tiering is only supported + for replication groups using the r6gd node type. This parameter + must be set to true when using r6gd nodes. + type: boolean + description: + description: created description for the replication group. Must + not be empty. + type: string + engine: + description: Name of the cache engine to be used for the clusters + in this replication group. The only valid value is redis. + type: string + engineVersion: + description: Version number of the cache engine to be used for + the cache clusters in this replication group. If the version + is 6 or higher, the major and minor version can be set, e.g., + 6.2, or the minor version can be unspecified which will use + the latest version at creation time, e.g., 6.x. Otherwise, specify + the full version desired, e.g., 5.0.6. The actual engine version + used is returned in the attribute engine_version_actual, see + Attributes Reference below. + type: string + finalSnapshotIdentifier: + description: The name of your final node group (shard) snapshot. + ElastiCache creates the snapshot from the primary node in the + cluster. If omitted, no final snapshot will be made. + type: string + globalReplicationGroupId: + description: The ID of the global replication group to which this + replication group should belong. If this parameter is specified, + the replication group is added to the specified global replication + group as a secondary replication group; otherwise, the replication + group is not part of any global replication group. If global_replication_group_id + is set, the num_node_groups parameter cannot be set. + type: string + logDeliveryConfiguration: + description: Specifies the destination and format of Redis SLOWLOG + or Redis Engine Log. See the documentation on Amazon ElastiCache. + See Log Delivery Configuration below for more details. + items: + properties: + destination: + description: Name of either the CloudWatch Logs LogGroup + or Kinesis Data Firehose resource. + type: string + destinationType: + description: For CloudWatch Logs use cloudwatch-logs or + for Kinesis Data Firehose use kinesis-firehose. + type: string + logFormat: + description: Valid values are json or text + type: string + logType: + description: Valid values are slow-log or engine-log. Max + 1 of each. + type: string + type: object + type: array + maintenanceWindow: + description: 'ddd:hh24:mi (24H Clock UTC). The minimum maintenance + window is a 60 minute period. Example: sun:05:00-sun:09:00' + type: string + multiAzEnabled: + description: Specifies whether to enable Multi-AZ Support for + the replication group. If true, automatic_failover_enabled must + also be enabled. Defaults to false. + type: boolean + nodeType: + description: Instance class to be used. See AWS documentation + for information on supported node types and guidance on selecting + node types. Required unless global_replication_group_id is set. + Cannot be set if global_replication_group_id is set. + type: string + notificationTopicArn: + description: east-1:012345678999:my_sns_topic + type: string + numCacheClusters: + description: 00#. + type: number + numNodeGroups: + description: Number of node groups (shards) for this Redis replication + group. Changing this number will trigger a resizing operation + before other settings modifications. + type: number + parameterGroupName: + description: Name of the parameter group to associate with this + replication group. If this argument is omitted, the default + cache parameter group for the specified engine is used. To enable + "cluster mode", i.e., data sharding, use a parameter group that + has the parameter cluster-enabled set to true. + type: string + port: + description: – Port number on which each of the cache nodes will + accept connections. For Memcache the default is 11211, and for + Redis the default port is 6379. + type: number + preferredCacheClusterAzs: + description: List of EC2 availability zones in which the replication + group's cache clusters will be created. The order of the availability + zones in the list is considered. The first item in the list + will be the primary node. Ignored when updating. + items: + type: string + type: array + replicasPerNodeGroup: + description: Number of replica nodes in each node group. Changing + this number will trigger a resizing operation before other settings + modifications. Valid values are 0 to 5. + type: number + securityGroupNames: + description: List of cache security group names to associate with + this replication group. + items: + type: string + type: array + snapshotArns: + description: – List of ARNs that identify Redis RDB snapshot + files stored in Amazon S3. The names object names cannot contain + any commas. + items: + type: string + type: array + snapshotName: + description: Name of a snapshot from which to restore data into + the new node group. Changing the snapshot_name forces a new + resource. + type: string + snapshotRetentionLimit: + description: Number of days for which ElastiCache will retain + automatic cache cluster snapshots before deleting them. For + example, if you set SnapshotRetentionLimit to 5, then a snapshot + that was taken today will be retained for 5 days before being + deleted. If the value of snapshot_retention_limit is set to + zero (0), backups are turned off. Please note that setting a + snapshot_retention_limit is not supported on cache.t1.micro + cache nodes + type: number + snapshotWindow: + description: 'Daily time range (in UTC) during which ElastiCache + will begin taking a daily snapshot of your cache cluster. The + minimum snapshot window is a 60 minute period. Example: 05:00-09:00' + type: string + tags: + additionalProperties: + type: string + description: Map of tags to assign to the resource. Adding tags + to this resource will add or overwrite any existing tags on + the clusters in the replication group and not to the group itself. + If configured with a provider default_tags configuration block + present, tags with matching keys will overwrite those defined + at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + transitEncryptionEnabled: + description: Whether to enable encryption in transit. + type: boolean + userGroupIds: + description: 'User Group ID to associate with the replication + group. Only a maximum of one (1) user group ID is valid. NOTE: + This argument is a set because the AWS specification allows + for multiple IDs. However, in practice, AWS only allows a maximum + size of one.' + items: + type: string + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -581,42 +790,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -715,8 +888,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ReplicationGroupStatus defines the observed state of ReplicationGroup. properties: @@ -997,6 +1171,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_subnetgroups.yaml b/package/crds/elasticache.aws.kubedb.com_subnetgroups.yaml index 658a62b..43def26 100644 --- a/package/crds/elasticache.aws.kubedb.com_subnetgroups.yaml +++ b/package/crds/elasticache.aws.kubedb.com_subnetgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: subnetgroups.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -172,21 +171,61 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: – Description for the cache subnet group. + type: string + tags: + additionalProperties: + type: string + description: Key-value map of resource tags. If configured with + a provider default_tags configuration block present, tags with + matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -225,42 +264,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -359,8 +362,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SubnetGroupStatus defines the observed state of SubnetGroup. properties: @@ -426,6 +430,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_usergroups.yaml b/package/crds/elasticache.aws.kubedb.com_usergroups.yaml index 5592d13..ad247af 100644 --- a/package/crds/elasticache.aws.kubedb.com_usergroups.yaml +++ b/package/crds/elasticache.aws.kubedb.com_usergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: usergroups.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -171,21 +170,61 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + engine: + description: The current supported value is REDIS. + type: string + tags: + additionalProperties: + type: string + description: Key-value map of resource tags. If configured with + a provider default_tags configuration block present, tags with + matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -224,42 +263,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -358,10 +361,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: engine is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.engine is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) + || (has(self.initProvider) && has(self.initProvider.engine))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: UserGroupStatus defines the observed state of UserGroup. properties: @@ -429,6 +435,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticache.aws.kubedb.com_users.yaml b/package/crds/elasticache.aws.kubedb.com_users.yaml index 7bbcfdc..793c80a 100644 --- a/package/crds/elasticache.aws.kubedb.com_users.yaml +++ b/package/crds/elasticache.aws.kubedb.com_users.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: users.elasticache.aws.kubedb.com spec: group: elasticache.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -103,8 +102,6 @@ spec: description: 'Specifies the authentication type. Possible options are: password, no-password-required or iam.' type: string - required: - - type type: object type: array engine: @@ -153,21 +150,78 @@ spec: description: The username of the user. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + accessString: + description: Access permissions string used for this user. See + Specifying Permissions Using an Access String for more details. + type: string + authenticationMode: + description: Denotes the user's authentication properties. Detailed + below. + items: + properties: + type: + description: 'Specifies the authentication type. Possible + options are: password, no-password-required or iam.' + type: string + type: object + type: array + engine: + description: The current supported value is REDIS. + type: string + noPasswordRequired: + description: Indicates a password is not required for this user. + type: boolean + tags: + additionalProperties: + type: string + description: A list of tags to be added to this resource. A tag + is a key-value pair. + type: object + tagsAll: + additionalProperties: + type: string + type: object + userName: + description: The username of the user. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -206,42 +260,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -340,14 +358,21 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: accessString is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.accessString) - - message: engine is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: userName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.userName) + - message: spec.forProvider.accessString is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.accessString) + || (has(self.initProvider) && has(self.initProvider.accessString))' + - message: spec.forProvider.engine is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) + || (has(self.initProvider) && has(self.initProvider.engine))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.userName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.userName) + || (has(self.initProvider) && has(self.initProvider.userName))' status: description: UserStatus defines the observed state of User. properties: @@ -428,6 +453,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticsearch.aws.kubedb.com_domainpolicies.yaml b/package/crds/elasticsearch.aws.kubedb.com_domainpolicies.yaml index 61f738a..3a19292 100644 --- a/package/crds/elasticsearch.aws.kubedb.com_domainpolicies.yaml +++ b/package/crds/elasticsearch.aws.kubedb.com_domainpolicies.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: domainpolicies.elasticsearch.aws.kubedb.com spec: group: elasticsearch.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -155,21 +154,48 @@ spec: be created in. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + accessPolicies: + description: IAM policy document specifying the access policies + for the domain + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -208,42 +234,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -342,10 +332,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: accessPolicies is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.accessPolicies) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.accessPolicies is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.accessPolicies) + || (has(self.initProvider) && has(self.initProvider.accessPolicies))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: DomainPolicyStatus defines the observed state of DomainPolicy. properties: @@ -394,6 +387,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticsearch.aws.kubedb.com_domains.yaml b/package/crds/elasticsearch.aws.kubedb.com_domains.yaml index 1a34ca8..3a3be59 100644 --- a/package/crds/elasticsearch.aws.kubedb.com_domains.yaml +++ b/package/crds/elasticsearch.aws.kubedb.com_domains.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: domains.elasticsearch.aws.kubedb.com spec: group: elasticsearch.aws.kubedb.com @@ -57,7 +56,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -127,8 +126,6 @@ spec: type: object type: object type: array - required: - - enabled type: object type: array autoTuneOptions: @@ -165,19 +162,12 @@ spec: of the duration of an Auto-Tune maintenance window. type: number - required: - - unit - - value type: object type: array startAt: description: Date and time at which to start the Auto-Tune maintenance schedule in RFC3339 format. type: string - required: - - cronExpressionForRecurrence - - duration - - startAt type: object type: array rollbackOnDisable: @@ -185,8 +175,6 @@ spec: settings when disabling Auto-Tune. Valid values: DEFAULT_ROLLBACK or NO_ROLLBACK.' type: string - required: - - desiredState type: object type: array clusterConfig: @@ -277,10 +265,6 @@ spec: userPoolId: description: ID of the Cognito User Pool to use. type: string - required: - - identityPoolId - - roleArn - - userPoolId type: object type: array domainEndpointOptions: @@ -335,8 +319,6 @@ spec: volumeType: description: Type of EBS volumes attached to data nodes. type: string - required: - - ebsEnabled type: object type: array elasticsearchVersion: @@ -359,8 +341,6 @@ spec: service KMS key. Note that KMS will accept a KMS key ID but will return the key ARN. type: string - required: - - enabled type: object type: array logPublishingOptions: @@ -382,9 +362,6 @@ spec: description: 'Type of Elasticsearch log. Valid values: INDEX_SLOW_LOGS, SEARCH_SLOW_LOGS, ES_APPLICATION_LOGS, AUDIT_LOGS.' type: string - required: - - cloudwatchLogGroupArn - - logType type: object type: array nodeToNodeEncryption: @@ -399,8 +376,6 @@ spec: of a new domain requires an elasticsearch_version of 6.0 or greater. type: boolean - required: - - enabled type: object type: array region: @@ -419,8 +394,6 @@ spec: description: Hour during which the service takes an automated daily snapshot of the indices in the domain. type: number - required: - - automatedSnapshotStartHour type: object type: array tags: @@ -458,21 +431,384 @@ spec: type: object type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + accessPolicies: + description: IAM policy document specifying the access policies + for the domain. + type: string + advancedOptions: + additionalProperties: + type: string + description: Key-value string pairs to specify advanced configuration + options. + type: object + advancedSecurityOptions: + description: Configuration block for fine-grained access control. + Detailed below. + items: + properties: + enabled: + description: Whether advanced security is enabled. + type: boolean + internalUserDatabaseEnabled: + description: Whether the internal user database is enabled. + If not set, defaults to false by the AWS API. + type: boolean + masterUserOptions: + description: Configuration block for the main user. Detailed + below. + items: + properties: + masterUserArn: + description: ARN for the main user. Only specify if + internal_user_database_enabled is not set or set + to false. + type: string + masterUserName: + description: Main user's username, which is stored + in the Amazon Elasticsearch Service domain's internal + database. Only specify if internal_user_database_enabled + is set to true. + type: string + type: object + type: array + type: object + type: array + autoTuneOptions: + description: Configuration block for the Auto-Tune options of + the domain. Detailed below. + items: + properties: + desiredState: + description: 'The Auto-Tune desired state for the domain. + Valid values: ENABLED or DISABLED.' + type: string + maintenanceSchedule: + description: Configuration block for Auto-Tune maintenance + windows. Can be specified multiple times for each maintenance + window. Detailed below. + items: + properties: + cronExpressionForRecurrence: + description: A cron expression specifying the recurrence + pattern for an Auto-Tune maintenance schedule. + type: string + duration: + description: Configuration block for the duration + of the Auto-Tune maintenance window. Detailed below. + items: + properties: + unit: + description: 'The unit of time specifying the + duration of an Auto-Tune maintenance window. + Valid values: HOURS.' + type: string + value: + description: An integer specifying the value + of the duration of an Auto-Tune maintenance + window. + type: number + type: object + type: array + startAt: + description: Date and time at which to start the Auto-Tune + maintenance schedule in RFC3339 format. + type: string + type: object + type: array + rollbackOnDisable: + description: 'Whether to roll back to default Auto-Tune + settings when disabling Auto-Tune. Valid values: DEFAULT_ROLLBACK + or NO_ROLLBACK.' + type: string + type: object + type: array + clusterConfig: + description: Configuration block for the cluster of the domain. + Detailed below. + items: + properties: + coldStorageOptions: + description: Configuration block containing cold storage + configuration. Detailed below. + items: + properties: + enabled: + description: Boolean to enable cold storage for an + Elasticsearch domain. Defaults to false. Master + and ultrawarm nodes must be enabled for cold storage. + type: boolean + type: object + type: array + dedicatedMasterCount: + description: Number of dedicated main nodes in the cluster. + type: number + dedicatedMasterEnabled: + description: Whether dedicated main nodes are enabled for + the cluster. + type: boolean + dedicatedMasterType: + description: Instance type of the dedicated main nodes in + the cluster. + type: string + instanceCount: + description: Number of instances in the cluster. + type: number + instanceType: + description: Instance type of data nodes in the cluster. + type: string + warmCount: + description: Number of warm nodes in the cluster. Valid + values are between 2 and 150. warm_count can be only and + must be set when warm_enabled is set to true. + type: number + warmEnabled: + description: Whether to enable warm storage. + type: boolean + warmType: + description: Instance type for the Elasticsearch cluster's + warm nodes. Valid values are ultrawarm1.medium.elasticsearch, + ultrawarm1.large.elasticsearch and ultrawarm1.xlarge.elasticsearch. + warm_type can be only and must be set when warm_enabled + is set to true. + type: string + zoneAwarenessConfig: + description: Configuration block containing zone awareness + settings. Detailed below. + items: + properties: + availabilityZoneCount: + description: 'Number of Availability Zones for the + domain to use with zone_awareness_enabled. Defaults + to 2. Valid values: 2 or 3.' + type: number + type: object + type: array + zoneAwarenessEnabled: + description: Whether zone awareness is enabled, set to true + for multi-az deployment. To enable awareness with three + Availability Zones, the availability_zone_count within + the zone_awareness_config must be set to 3. + type: boolean + type: object + type: array + cognitoOptions: + description: Configuration block for authenticating Kibana with + Cognito. Detailed below. + items: + properties: + enabled: + description: Whether Amazon Cognito authentication with + Kibana is enabled or not. + type: boolean + identityPoolId: + description: ID of the Cognito Identity Pool to use. + type: string + roleArn: + description: ARN of the IAM role that has the AmazonESCognitoAccess + policy attached. + type: string + userPoolId: + description: ID of the Cognito User Pool to use. + type: string + type: object + type: array + domainEndpointOptions: + description: Configuration block for domain endpoint HTTP(S) related + options. Detailed below. + items: + properties: + customEndpoint: + description: Fully qualified domain for your custom endpoint. + type: string + customEndpointCertificateArn: + description: ACM certificate ARN for your custom endpoint. + type: string + customEndpointEnabled: + description: Whether to enable custom endpoint for the Elasticsearch + domain. + type: boolean + enforceHttps: + description: Whether or not to require HTTPS. Defaults to + true. + type: boolean + tlsSecurityPolicy: + description: 'Name of the TLS security policy that needs + to be applied to the HTTPS endpoint. Valid values: Policy-Min-TLS-1-0-2019-07 + and Policy-Min-TLS-1-2-2019-07.' + type: string + type: object + type: array + ebsOptions: + description: Configuration block for EBS related options, may + be required based on chosen instance size. Detailed below. + items: + properties: + ebsEnabled: + description: Whether EBS volumes are attached to data nodes + in the domain. + type: boolean + iops: + description: Baseline input/output (I/O) performance of + EBS volumes attached to data nodes. Applicable only for + the GP3 and Provisioned IOPS EBS volume types. + type: number + throughput: + description: Specifies the throughput (in MiB/s) of the + EBS volumes attached to data nodes. Applicable only for + the gp3 volume type. + type: number + volumeSize: + description: Size of EBS volumes attached to data nodes + (in GiB). + type: number + volumeType: + description: Type of EBS volumes attached to data nodes. + type: string + type: object + type: array + elasticsearchVersion: + description: Version of Elasticsearch to deploy. Defaults to 1.5. + type: string + encryptAtRest: + description: Configuration block for encrypt at rest options. + Only available for certain instance types. Detailed below. + items: + properties: + enabled: + description: Whether to enable encryption at rest. If the + encrypt_at_rest block is not provided then this defaults + to false. Enabling encryption on new domains requires + elasticsearch_version 5.1 or greater. + type: boolean + kmsKeyId: + description: KMS key ARN to encrypt the Elasticsearch domain + with. If not specified then it defaults to using the aws/es + service KMS key. Note that KMS will accept a KMS key ID + but will return the key ARN. + type: string + type: object + type: array + logPublishingOptions: + description: Configuration block for publishing slow and application + logs to CloudWatch Logs. This block can be declared multiple + times, for each log_type, within the same resource. Detailed + below. + items: + properties: + cloudwatchLogGroupArn: + description: ARN of the Cloudwatch log group to which log + needs to be published. + type: string + enabled: + description: Whether given log publishing option is enabled + or not. + type: boolean + logType: + description: 'Type of Elasticsearch log. Valid values: INDEX_SLOW_LOGS, + SEARCH_SLOW_LOGS, ES_APPLICATION_LOGS, AUDIT_LOGS.' + type: string + type: object + type: array + nodeToNodeEncryption: + description: Configuration block for node-to-node encryption options. + Detailed below. + items: + properties: + enabled: + description: Whether to enable node-to-node encryption. + If the node_to_node_encryption block is not provided then + this defaults to false. Enabling node-to-node encryption + of a new domain requires an elasticsearch_version of 6.0 + or greater. + type: boolean + type: object + type: array + snapshotOptions: + description: Configuration block for snapshot related options. + Detailed below. DEPRECATED. For domains running Elasticsearch + 5.3 and later, Amazon ES takes hourly automated snapshots, making + this setting irrelevant. For domains running earlier versions + of Elasticsearch, Amazon ES takes daily automated snapshots. + items: + properties: + automatedSnapshotStartHour: + description: Hour during which the service takes an automated + daily snapshot of the indices in the domain. + type: number + type: object + type: array + tags: + additionalProperties: + type: string + description: Map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + vpcOptions: + description: Configuration block for VPC related options. Adding + or removing this configuration forces a new resource (documentation). + Detailed below. + items: + properties: + securityGroupIds: + description: List of VPC Security Group IDs to be applied + to the Elasticsearch domain endpoints. If omitted, the + default Security Group for the VPC will be used. + items: + type: string + type: array + subnetIds: + description: List of VPC Subnet IDs for the Elasticsearch + domain endpoints to be created in. + items: + type: string + type: array + type: object + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -511,42 +847,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -645,8 +945,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: DomainStatus defines the observed state of Domain. properties: @@ -1053,6 +1354,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/elasticsearch.aws.kubedb.com_domainsamloptions.yaml b/package/crds/elasticsearch.aws.kubedb.com_domainsamloptions.yaml index f21005b..123f8d1 100644 --- a/package/crds/elasticsearch.aws.kubedb.com_domainsamloptions.yaml +++ b/package/crds/elasticsearch.aws.kubedb.com_domainsamloptions.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: domainsamloptions.elasticsearch.aws.kubedb.com spec: group: elasticsearch.aws.kubedb.com @@ -57,7 +56,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -91,9 +90,6 @@ spec: description: The Metadata of the SAML application in xml format. type: string - required: - - entityId - - metadataContent type: object type: array masterBackendRole: @@ -137,21 +133,87 @@ spec: type: object type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + samlOptions: + description: The SAML authentication options for an AWS Elasticsearch + Domain. + items: + properties: + enabled: + description: Whether SAML authentication is enabled. + type: boolean + idp: + description: Information from your identity provider. + items: + properties: + entityId: + description: The unique Entity ID of the application + in SAML Identity Provider. + type: string + metadataContent: + description: The Metadata of the SAML application + in xml format. + type: string + type: object + type: array + masterBackendRole: + description: This backend role from the SAML IdP receives + full permissions to the cluster, equivalent to a new master + user. + type: string + rolesKey: + description: Element of the SAML assertion to use for backend + roles. Default is roles. + type: string + sessionTimeoutMinutes: + description: Duration of a session in minutes after a user + logs in. Default is 60. Maximum value is 1,440. + type: number + subjectKey: + description: Custom SAML attribute to use for user names. + Default is an empty string - "". This will cause Elasticsearch + to use the NameID element of the Subject, which is the + default location for name identifiers in the SAML specification. + type: string + type: object + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -190,42 +252,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -324,8 +350,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: DomainSAMLOptionsStatus defines the observed state of DomainSAMLOptions. properties: @@ -412,6 +439,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/kafka.aws.kubedb.com_clusters.yaml b/package/crds/kafka.aws.kubedb.com_clusters.yaml index 8e69563..f9e60eb 100644 --- a/package/crds/kafka.aws.kubedb.com_clusters.yaml +++ b/package/crds/kafka.aws.kubedb.com_clusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusters.kafka.aws.kubedb.com spec: group: kafka.aws.kubedb.com @@ -57,7 +56,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -322,8 +321,6 @@ spec: type: array type: object type: array - required: - - instanceType type: object type: array clientAuthentication: @@ -380,9 +377,6 @@ spec: description: Revision of the MSK Configuration to use in the cluster. type: number - required: - - arn - - revision type: object type: array encryptionInfo: @@ -516,8 +510,6 @@ spec: description: Name of the Cloudwatch Log Group to deliver logs to. type: string - required: - - enabled type: object type: array firehose: @@ -531,8 +523,6 @@ spec: description: 'Controls whether provisioned throughput is enabled or not. Default value: false.' type: boolean - required: - - enabled type: object type: array s3: @@ -550,14 +540,10 @@ spec: description: Prefix to append to the folder name. type: string - required: - - enabled type: object type: array type: object type: array - required: - - brokerLogs type: object type: array numberOfBrokerNodes: @@ -584,8 +570,6 @@ spec: description: Indicates whether you want to enable or disable the JMX Exporter. type: boolean - required: - - enabledInBroker type: object type: array nodeExporter: @@ -597,14 +581,10 @@ spec: description: Indicates whether you want to enable or disable the JMX Exporter. type: boolean - required: - - enabledInBroker type: object type: array type: object type: array - required: - - prometheus type: object type: array region: @@ -630,21 +610,327 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + brokerNodeGroupInfo: + description: Configuration block for the broker nodes of the Kafka + cluster. + items: + properties: + azDistribution: + description: The distribution of broker nodes across availability + zones (documentation). Currently the only valid value + is DEFAULT. + type: string + connectivityInfo: + description: Information about the cluster access configuration. + See below. For security reasons, you can't turn on public + access while creating an MSK cluster. However, you can + update an existing cluster to make it publicly accessible. + You can also create a new cluster and then update it to + make it publicly accessible (documentation). + items: + properties: + publicAccess: + description: Access control settings for brokers. + See below. + items: + properties: + type: + description: 'Public access type. Valida values: + DISABLED, SERVICE_PROVIDED_EIPS.' + type: string + type: object + type: array + type: object + type: array + instanceType: + description: Specify the instance type to use for the kafka + brokersE.g., kafka.m5.large. (Pricing info) + type: string + storageInfo: + description: A block that contains information about storage + volumes attached to MSK broker nodes. See below. + items: + properties: + ebsStorageInfo: + description: A block that contains EBS volume information. + See below. + items: + properties: + provisionedThroughput: + description: A block that contains EBS volume + provisioned throughput information. To provision + storage throughput, you must choose broker + type kafka.m5.4xlarge or larger. See below. + items: + properties: + enabled: + description: 'Controls whether provisioned + throughput is enabled or not. Default + value: false.' + type: boolean + volumeThroughput: + description: Throughput value of the EBS + volumes for the data drive on each kafka + broker node in MiB per second. The minimum + value is 250. The maximum value varies + between broker type. You can refer to + the valid values for the maximum volume + throughput at the following documentation + on throughput bottlenecks + type: number + type: object + type: array + volumeSize: + description: The size in GiB of the EBS volume + for the data drive on each broker node. Minimum + value of 1 and maximum value of 16384. + type: number + type: object + type: array + type: object + type: array + type: object + type: array + clientAuthentication: + description: Configuration block for specifying a client authentication. + See below. + items: + properties: + sasl: + description: Configuration block for specifying SASL client + authentication. See below. + items: + properties: + iam: + description: Enables IAM client authentication. Defaults + to false. + type: boolean + scram: + description: Enables SCRAM client authentication via + AWS Secrets Manager. Defaults to false. + type: boolean + type: object + type: array + tls: + description: Configuration block for specifying TLS client + authentication. See below. + items: + properties: + certificateAuthorityArns: + description: List of ACM Certificate Authority Amazon + Resource Names (ARNs). + items: + type: string + type: array + type: object + type: array + unauthenticated: + description: Enables unauthenticated access. + type: boolean + type: object + type: array + clusterName: + description: Name of the MSK cluster. + type: string + configurationInfo: + description: Configuration block for specifying a MSK Configuration + to attach to Kafka brokers. See below. + items: + properties: + arn: + description: Amazon Resource Name (ARN) of the MSK Configuration + to use in the cluster. + type: string + revision: + description: Revision of the MSK Configuration to use in + the cluster. + type: number + type: object + type: array + encryptionInfo: + description: Configuration block for specifying encryption. See + below. + items: + properties: + encryptionInTransit: + description: Configuration block to specify encryption in + transit. See below. + items: + properties: + clientBroker: + description: 'Encryption setting for data in transit + between clients and brokers. Valid values: TLS, + TLS_PLAINTEXT, and PLAINTEXT. Default value is TLS.' + type: string + inCluster: + description: 'Whether data communication among broker + nodes is encrypted. Default value: true.' + type: boolean + type: object + type: array + type: object + type: array + enhancedMonitoring: + description: Specify the desired enhanced MSK CloudWatch monitoring + level. See Monitoring Amazon MSK with Amazon CloudWatch + type: string + kafkaVersion: + description: Specify the desired Kafka software version. + type: string + loggingInfo: + description: Configuration block for streaming broker logs to + Cloudwatch/S3/Kinesis Firehose. See below. + items: + properties: + brokerLogs: + description: Configuration block for Broker Logs settings + for logging info. See below. + items: + properties: + cloudwatchLogs: + items: + properties: + enabled: + description: 'Controls whether provisioned throughput + is enabled or not. Default value: false.' + type: boolean + logGroup: + description: Name of the Cloudwatch Log Group + to deliver logs to. + type: string + type: object + type: array + firehose: + items: + properties: + deliveryStream: + description: Name of the Kinesis Data Firehose + delivery stream to deliver logs to. + type: string + enabled: + description: 'Controls whether provisioned throughput + is enabled or not. Default value: false.' + type: boolean + type: object + type: array + s3: + items: + properties: + bucket: + description: Name of the S3 bucket to deliver + logs to. + type: string + enabled: + description: 'Controls whether provisioned throughput + is enabled or not. Default value: false.' + type: boolean + prefix: + description: Prefix to append to the folder + name. + type: string + type: object + type: array + type: object + type: array + type: object + type: array + numberOfBrokerNodes: + description: The desired total number of broker nodes in the kafka + cluster. It must be a multiple of the number of specified client + subnets. + type: number + openMonitoring: + description: Configuration block for JMX and Node monitoring for + the MSK cluster. See below. + items: + properties: + prometheus: + description: Configuration block for Prometheus settings + for open monitoring. See below. + items: + properties: + jmxExporter: + description: Configuration block for JMX Exporter. + See below. + items: + properties: + enabledInBroker: + description: Indicates whether you want to enable + or disable the JMX Exporter. + type: boolean + type: object + type: array + nodeExporter: + description: Configuration block for Node Exporter. + See below. + items: + properties: + enabledInBroker: + description: Indicates whether you want to enable + or disable the JMX Exporter. + type: boolean + type: object + type: array + type: object + type: array + type: object + type: array + storageMode: + description: 'Controls storage mode for supported storage tiers. + Valid values are: LOCAL or TIERED.' + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -683,42 +969,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -817,16 +1067,25 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: brokerNodeGroupInfo is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.brokerNodeGroupInfo) - - message: clusterName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.clusterName) - - message: kafkaVersion is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.kafkaVersion) - - message: numberOfBrokerNodes is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.numberOfBrokerNodes) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.brokerNodeGroupInfo is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.brokerNodeGroupInfo) + || (has(self.initProvider) && has(self.initProvider.brokerNodeGroupInfo))' + - message: spec.forProvider.clusterName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterName) + || (has(self.initProvider) && has(self.initProvider.clusterName))' + - message: spec.forProvider.kafkaVersion is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.kafkaVersion) + || (has(self.initProvider) && has(self.initProvider.kafkaVersion))' + - message: spec.forProvider.numberOfBrokerNodes is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.numberOfBrokerNodes) + || (has(self.initProvider) && has(self.initProvider.numberOfBrokerNodes))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterStatus defines the observed state of Cluster. properties: @@ -1256,6 +1515,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/kafka.aws.kubedb.com_configurations.yaml b/package/crds/kafka.aws.kubedb.com_configurations.yaml index f55375c..76a3c68 100644 --- a/package/crds/kafka.aws.kubedb.com_configurations.yaml +++ b/package/crds/kafka.aws.kubedb.com_configurations.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: configurations.kafka.aws.kubedb.com spec: group: kafka.aws.kubedb.com @@ -35,9 +34,8 @@ spec: name: v1alpha1 schema: openAPIV3Schema: - description: Configuration is the Schema for the Configurations API. Upbound - official provider resource for managing an amazon managed streaming for - kafka configuration + description: Configuration is the Schema for the Configurations API. provider + resource for managing an amazon managed streaming for kafka configuration properties: apiVersion: description: 'APIVersion defines the versioned schema of this representation @@ -59,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -90,21 +88,60 @@ spec: properties are documented in the MSK Developer Guide. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: Description of the configuration. + type: string + kafkaVersions: + description: List of Apache Kafka versions which can use this + configuration. + items: + type: string + type: array + name: + description: Name of the configuration. + type: string + serverProperties: + description: Contents of the server.properties file. Supported + properties are documented in the MSK Developer Guide. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -143,42 +180,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -277,12 +278,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: name is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.name) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: serverProperties is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.serverProperties) + - message: spec.forProvider.name is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.name) + || (has(self.initProvider) && has(self.initProvider.name))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.serverProperties is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.serverProperties) + || (has(self.initProvider) && has(self.initProvider.serverProperties))' status: description: ConfigurationStatus defines the observed state of Configuration. properties: @@ -346,6 +352,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/kinesis.aws.kubedb.com_streams.yaml b/package/crds/kinesis.aws.kubedb.com_streams.yaml index 5e9825b..8db7751 100644 --- a/package/crds/kinesis.aws.kubedb.com_streams.yaml +++ b/package/crds/kinesis.aws.kubedb.com_streams.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: streams.kinesis.aws.kubedb.com spec: group: kinesis.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -189,8 +188,6 @@ spec: description: Specifies the capacity mode of the stream. Must be either PROVISIONED or ON_DEMAND. type: string - required: - - streamMode type: object type: array tags: @@ -208,21 +205,99 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + encryptionType: + description: The encryption type to use. The only acceptable values + are NONE or KMS. The default value is NONE. + type: string + enforceConsumerDeletion: + description: A boolean that indicates all registered consumers + should be deregistered from the stream so that the stream can + be destroyed without error. The default value is false. + type: boolean + retentionPeriod: + description: Length of time data records are accessible after + they are added to the stream. The maximum value of a stream's + retention period is 8760 hours. Minimum value is 24. Default + is 24. + type: number + shardCount: + description: – The number of shards that the stream will use. + If the stream_mode is PROVISIONED, this field is required. Amazon + has guidelines for specifying the Stream size that should be + referenced when creating a Kinesis stream. See Amazon Kinesis + Streams for more. + type: number + shardLevelMetrics: + description: A list of shard-level CloudWatch metrics which can + be enabled for the stream. See Monitoring with CloudWatch for + more. Note that the value ALL should not be used; instead you + should provide an explicit list of metrics you wish to enable. + items: + type: string + type: array + streamModeDetails: + description: Indicates the capacity mode of the data stream. Detailed + below. + items: + properties: + streamMode: + description: Specifies the capacity mode of the stream. + Must be either PROVISIONED or ON_DEMAND. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -261,42 +336,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -395,8 +434,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: StreamStatus defines the observed state of Stream. properties: @@ -503,6 +543,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/kms.aws.kubedb.com_keys.yaml b/package/crds/kms.aws.kubedb.com_keys.yaml index 65e4cee..8680089 100644 --- a/package/crds/kms.aws.kubedb.com_keys.yaml +++ b/package/crds/kms.aws.kubedb.com_keys.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: keys.kms.aws.kubedb.com spec: group: kms.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -143,21 +142,114 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + bypassPolicyLockoutSafetyCheck: + description: A flag to indicate whether to bypass the key policy + lockout safety check. Setting this value to true increases the + risk that the KMS key becomes unmanageable. Do not set this + value to true indiscriminately. For more information, refer + to the scenario in the Default Key Policy section in the AWS + Key Management Service Developer Guide. The default value is + false. + type: boolean + customKeyStoreId: + description: ID of the KMS Custom Key Store where the key will + be stored instead of KMS (eg CloudHSM). + type: string + customerMasterKeySpec: + description: 'Specifies whether the key contains a symmetric key + or an asymmetric key pair and the encryption algorithms or signing + algorithms that the key supports. Valid values: SYMMETRIC_DEFAULT, RSA_2048, + RSA_3072, RSA_4096, HMAC_256, ECC_NIST_P256, ECC_NIST_P384, + ECC_NIST_P521, or ECC_SECG_P256K1. Defaults to SYMMETRIC_DEFAULT. + For help with choosing a key spec, see the AWS KMS Developer + Guide.' + type: string + deletionWindowInDays: + description: The waiting period, specified in number of days. + After the waiting period ends, AWS KMS deletes the KMS key. + If you specify a value, it must be between 7 and 30, inclusive. + If you do not specify a value, it defaults to 30. If the KMS + key is a multi-Region primary key with replicas, the waiting + period begins when the last of its replica keys is deleted. + Otherwise, the waiting period begins immediately. + type: number + description: + description: The description of the key as viewed in AWS console. + type: string + enableKeyRotation: + description: Specifies whether key rotation is enabled. Defaults + to false. + type: boolean + isEnabled: + description: Specifies whether the key is enabled. Defaults to + true. + type: boolean + keyUsage: + description: 'Specifies the intended use of the key. Valid values: + ENCRYPT_DECRYPT, SIGN_VERIFY, or GENERATE_VERIFY_MAC. Defaults + to ENCRYPT_DECRYPT.' + type: string + multiRegion: + description: Indicates whether the KMS key is a multi-Region (true) + or regional (false) key. Defaults to false. + type: boolean + policy: + description: A valid policy JSON document. Although this is a + key policy, not an IAM policy, an aws_iam_policy_document, in + the form that designates a principal, can be used. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the object. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -196,42 +288,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -330,8 +386,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: KeyStatus defines the observed state of Key. properties: @@ -449,6 +506,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/memorydb.aws.kubedb.com_acls.yaml b/package/crds/memorydb.aws.kubedb.com_acls.yaml index fa0b91d..6e6b92c 100644 --- a/package/crds/memorydb.aws.kubedb.com_acls.yaml +++ b/package/crds/memorydb.aws.kubedb.com_acls.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: acls.memorydb.aws.kubedb.com spec: group: memorydb.aws.kubedb.com @@ -57,7 +56,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -92,21 +91,64 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + userNames: + description: Set of MemoryDB user names to be included in this + ACL. + items: + type: string + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -145,42 +187,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -279,8 +285,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ACLStatus defines the observed state of ACL. properties: @@ -349,6 +356,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/memorydb.aws.kubedb.com_clusters.yaml b/package/crds/memorydb.aws.kubedb.com_clusters.yaml index 88d454d..03aa18b 100644 --- a/package/crds/memorydb.aws.kubedb.com_clusters.yaml +++ b/package/crds/memorydb.aws.kubedb.com_clusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusters.memorydb.aws.kubedb.com spec: group: memorydb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -408,21 +407,140 @@ spec: to true. type: boolean type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + aclName: + description: The name of the Access Control List to associate + with the cluster. + type: string + autoMinorVersionUpgrade: + description: When set to true, the cluster will automatically + receive minor engine version upgrades after launch. Defaults + to true. + type: boolean + dataTiering: + description: Enables data tiering. This option is not supported + by all instance types. For more information, see Data tiering. + type: boolean + description: + description: Description for the cluster. + type: string + engineVersion: + description: Version number of the Redis engine to be used for + the cluster. Downgrades are not supported. + type: string + finalSnapshotName: + description: Name of the final cluster snapshot to be created + when this resource is deleted. If omitted, no final snapshot + will be made. + type: string + maintenanceWindow: + description: 'Specifies the weekly time range during which maintenance + on the cluster is performed. Specify as a range in the format + ddd:hh24:mi-ddd:hh24:mi (24H Clock UTC). The minimum maintenance + window is a 60 minute period. Example: sun:23:00-mon:01:30.' + type: string + nodeType: + description: The compute and memory capacity of the nodes in the + cluster. See AWS documentation on supported node types as well + as vertical scaling. + type: string + numReplicasPerShard: + description: The number of replicas to apply to each shard, up + to a maximum of 5. Defaults to 1 (i.e. 2 nodes per shard). + type: number + numShards: + description: The number of shards in the cluster. Defaults to + 1. + type: number + parameterGroupName: + description: The name of the parameter group associated with the + cluster. + type: string + port: + description: The port number on which each of the nodes accepts + connections. Defaults to 6379. + type: number + snapshotArns: + description: List of ARN-s that uniquely identify RDB snapshot + files stored in S3. The snapshot files will be used to populate + the new cluster. Object names in the ARN-s cannot contain any + commas. + items: + type: string + type: array + snapshotName: + description: The name of a snapshot from which to restore data + into the new cluster. + type: string + snapshotRetentionLimit: + description: The number of days for which MemoryDB retains automatic + snapshots before deleting them. When set to 0, automatic backups + are disabled. Defaults to 0. + type: number + snapshotWindow: + description: 'The daily time range (in UTC) during which MemoryDB + begins taking a daily snapshot of your shard. Example: 05:00-09:00.' + type: string + snsTopicArn: + description: ARN of the SNS topic to which cluster notifications + are sent. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + tlsEnabled: + description: A flag to enable in-transit encryption on the cluster. + When set to false, the acl_name must be open-access. Defaults + to true. + type: boolean + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -461,42 +579,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -595,12 +677,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: aclName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.aclName) - - message: nodeType is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.nodeType) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.aclName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.aclName) + || (has(self.initProvider) && has(self.initProvider.aclName))' + - message: spec.forProvider.nodeType is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.nodeType) + || (has(self.initProvider) && has(self.initProvider.nodeType))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterStatus defines the observed state of Cluster. properties: @@ -818,6 +905,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/memorydb.aws.kubedb.com_parametergroups.yaml b/package/crds/memorydb.aws.kubedb.com_parametergroups.yaml index 8816ce6..5c2a5af 100644 --- a/package/crds/memorydb.aws.kubedb.com_parametergroups.yaml +++ b/package/crds/memorydb.aws.kubedb.com_parametergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: parametergroups.memorydb.aws.kubedb.com spec: group: memorydb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -87,9 +86,6 @@ spec: value: description: The value of the parameter. type: string - required: - - name - - value type: object type: array region: @@ -111,21 +107,79 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: Description for the parameter group. + type: string + family: + description: The engine version that the parameter group can be + used with. + type: string + parameter: + description: Set of MemoryDB parameters to apply. Any parameters + not specified will fall back to their family defaults. Detailed + below. + items: + properties: + name: + description: The name of the parameter. + type: string + value: + description: The value of the parameter. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -164,42 +218,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -298,10 +316,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: family is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.family is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.family) + || (has(self.initProvider) && has(self.initProvider.family))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ParameterGroupStatus defines the observed state of ParameterGroup. properties: @@ -382,6 +403,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/memorydb.aws.kubedb.com_snapshots.yaml b/package/crds/memorydb.aws.kubedb.com_snapshots.yaml index 286aea8..b204387 100644 --- a/package/crds/memorydb.aws.kubedb.com_snapshots.yaml +++ b/package/crds/memorydb.aws.kubedb.com_snapshots.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: snapshots.memorydb.aws.kubedb.com spec: group: memorydb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -240,21 +239,58 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -293,42 +329,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -427,8 +427,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SnapshotStatus defines the observed state of Snapshot. properties: @@ -552,6 +553,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/memorydb.aws.kubedb.com_subnetgroups.yaml b/package/crds/memorydb.aws.kubedb.com_subnetgroups.yaml index 5d49b02..43fe81e 100644 --- a/package/crds/memorydb.aws.kubedb.com_subnetgroups.yaml +++ b/package/crds/memorydb.aws.kubedb.com_subnetgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: subnetgroups.memorydb.aws.kubedb.com spec: group: memorydb.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -173,21 +172,61 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: Description for the subnet group. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -226,42 +265,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -360,8 +363,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SubnetGroupStatus defines the observed state of SubnetGroup. properties: @@ -433,6 +437,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusteractivitystreams.yaml b/package/crds/rds.aws.kubedb.com_clusteractivitystreams.yaml index 29fdc30..2d7f4df 100644 --- a/package/crds/rds.aws.kubedb.com_clusteractivitystreams.yaml +++ b/package/crds/rds.aws.kubedb.com_clusteractivitystreams.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusteractivitystreams.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -240,21 +239,56 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + engineNativeAuditFieldsIncluded: + description: Specifies whether the database activity stream includes + engine-native audit fields. This option only applies to an Oracle + DB instance. By default, no engine-native audit fields are included. + Defaults false. + type: boolean + mode: + description: 'Specifies the mode of the database activity stream. + Database events such as a change or access generate an activity + stream event. The database session can handle these events either + synchronously or asynchronously. One of: sync, async.' + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -293,42 +327,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -427,10 +425,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: mode is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.mode) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.mode is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.mode) + || (has(self.initProvider) && has(self.initProvider.mode))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterActivityStreamStatus defines the observed state of ClusterActivityStream. @@ -499,6 +500,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusterendpoints.yaml b/package/crds/rds.aws.kubedb.com_clusterendpoints.yaml index d77a0a6..cf791e3 100644 --- a/package/crds/rds.aws.kubedb.com_clusterendpoints.yaml +++ b/package/crds/rds.aws.kubedb.com_clusterendpoints.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterendpoints.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -180,21 +179,75 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + customEndpointType: + description: 'The type of the endpoint. One of: READER , ANY .' + type: string + excludedMembers: + description: List of DB instance identifiers that aren't part + of the custom endpoint group. All other eligible instances are + reachable through the custom endpoint. Only relevant if the + list of static members is empty. Conflicts with static_members. + items: + type: string + type: array + staticMembers: + description: List of DB instance identifiers that are part of + the custom endpoint group. Conflicts with excluded_members. + items: + type: string + type: array + tags: + additionalProperties: + type: string + description: Key-value map of resource tags. If configured with + a provider default_tags configuration block present, tags with + matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -233,42 +286,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -367,10 +384,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: customEndpointType is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.customEndpointType) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.customEndpointType is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.customEndpointType) + || (has(self.initProvider) && has(self.initProvider.customEndpointType))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterEndpointStatus defines the observed state of ClusterEndpoint. properties: @@ -453,6 +473,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusterinstances.yaml b/package/crds/rds.aws.kubedb.com_clusterinstances.yaml index ad11c6a..ea5abbd 100644 --- a/package/crds/rds.aws.kubedb.com_clusterinstances.yaml +++ b/package/crds/rds.aws.kubedb.com_clusterinstances.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterinstances.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -400,21 +399,138 @@ spec: inherited from the provider default_tags configuration block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + applyImmediately: + description: Specifies whether any database modifications are + applied immediately, or during the next maintenance window. + Default isfalse. + type: boolean + autoMinorVersionUpgrade: + description: Indicates that minor engine upgrades will be applied + automatically to the DB instance during the maintenance window. + Default true. + type: boolean + availabilityZone: + description: EC2 Availability Zone that the DB instance is created + in. See docs about the details. + type: string + caCertIdentifier: + description: Identifier of the CA certificate for the DB instance. + type: string + copyTagsToSnapshot: + description: defined tags from the DB instance to snapshots of + the DB instance. Default false. + type: boolean + dbParameterGroupName: + description: Name of the DB parameter group to associate with + this instance. + type: string + engine: + description: 'Name of the database engine to be used for the RDS + instance. Valid Values: aurora-mysql, aurora-postgresql, mysql, + postgres.' + type: string + engineVersion: + description: Database engine version. + type: string + instanceClass: + description: Instance class to use. For details on CPU and memory, + see Scaling Aurora DB Instances. Aurora uses db.* instance classes/types. + Please see AWS Documentation for currently available instance + classes and complete details. + type: string + monitoringInterval: + description: 'Interval, in seconds, between points when Enhanced + Monitoring metrics are collected for the DB instance. To disable + collecting Enhanced Monitoring metrics, specify 0. The default + is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.' + type: number + monitoringRoleArn: + description: ARN for the IAM role that permits RDS to send enhanced + monitoring metrics to CloudWatch Logs. You can find more information + on the AWS Documentation what IAM permissions are needed to + allow Enhanced Monitoring for RDS Instances. + type: string + performanceInsightsEnabled: + description: Specifies whether Performance Insights is enabled + or not. + type: boolean + performanceInsightsRetentionPeriod: + description: Amount of time in days to retain Performance Insights + data. Valid values are 7, 731 (2 years) or a multiple of 31. + When specifying performance_insights_retention_period, performance_insights_enabled + needs to be set to true. Defaults to '7'. + type: number + preferredBackupWindow: + description: 'Daily time range during which automated backups + are created if automated backups are enabled. Eg: "04:00-09:00". + NOTE: If preferred_backup_window is set at the cluster level, + this argument must be omitted.' + type: string + preferredMaintenanceWindow: + description: 'Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". + Eg: "Mon:00:00-Mon:03:00".' + type: string + promotionTier: + description: Default 0. Failover Priority setting on instance + level. The reader who has lower tier has higher priority to + get promoted to writer. + type: number + publiclyAccessible: + description: Bool to control if instance is publicly accessible. + Default false. See the documentation on Creating DB Instances + for more details on controlling this property. + type: boolean + tags: + additionalProperties: + type: string + description: Map of tags to assign to the instance. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -453,42 +569,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -587,12 +667,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: engine is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine) - - message: instanceClass is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.engine is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) + || (has(self.initProvider) && has(self.initProvider.engine))' + - message: spec.forProvider.instanceClass is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.instanceClass) + || (has(self.initProvider) && has(self.initProvider.instanceClass))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterInstanceStatus defines the observed state of ClusterInstance. properties: @@ -772,6 +857,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusterparametergroups.yaml b/package/crds/rds.aws.kubedb.com_clusterparametergroups.yaml index 248e166..3ff8e7a 100644 --- a/package/crds/rds.aws.kubedb.com_clusterparametergroups.yaml +++ b/package/crds/rds.aws.kubedb.com_clusterparametergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterparametergroups.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -92,9 +91,6 @@ spec: value: description: The value of the DB parameter. type: string - required: - - name - - value type: object type: array region: @@ -116,21 +112,84 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the DB cluster parameter group. + type: string + family: + description: The family of the DB cluster parameter group. + type: string + parameter: + description: A list of DB parameters to apply. Note that parameters + may differ from a family to an other. Full list of all parameters + can be discovered via aws rds describe-db-cluster-parameters + after initial creation of the group. + items: + properties: + applyMethod: + description: '"immediate" (default), or "pending-reboot". + Some engines can''t apply some parameters without a reboot, + and you will need to specify "pending-reboot" here.' + type: string + name: + description: The name of the DB cluster parameter group. + type: string + value: + description: The value of the DB parameter. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -169,42 +228,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -303,10 +326,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: family is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.family is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.family) + || (has(self.initProvider) && has(self.initProvider.family))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterParameterGroupStatus defines the observed state of ClusterParameterGroup. @@ -393,6 +419,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusterroleassociations.yaml b/package/crds/rds.aws.kubedb.com_clusterroleassociations.yaml index 3782df5..498cd43 100644 --- a/package/crds/rds.aws.kubedb.com_clusterroleassociations.yaml +++ b/package/crds/rds.aws.kubedb.com_clusterroleassociations.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusterroleassociations.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -159,21 +158,54 @@ spec: with the DB Cluster. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + featureName: + description: Name of the feature for association. This can be + found in the AWS documentation relevant to the integration or + a full list is available in the SupportedFeatureNames list returned + by AWS CLI rds describe-db-engine-versions. + type: string + roleArn: + description: Amazon Resource Name (ARN) of the IAM Role to associate + with the DB Cluster. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -212,42 +244,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -346,12 +342,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: featureName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.featureName) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: roleArn is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn) + - message: spec.forProvider.featureName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.featureName) + || (has(self.initProvider) && has(self.initProvider.featureName))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.roleArn is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.roleArn) + || (has(self.initProvider) && has(self.initProvider.roleArn))' status: description: ClusterRoleAssociationStatus defines the observed state of ClusterRoleAssociation. @@ -409,6 +410,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clusters.yaml b/package/crds/rds.aws.kubedb.com_clusters.yaml index fbc14e6..b8c8ddf 100644 --- a/package/crds/rds.aws.kubedb.com_clusters.yaml +++ b/package/crds/rds.aws.kubedb.com_clusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clusters.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -603,11 +602,6 @@ spec: description: Version of the source engine used to make the backup type: string - required: - - bucketName - - ingestionRole - - sourceEngine - - sourceEngineVersion type: object type: array scalingConfiguration: @@ -673,9 +667,6 @@ spec: 256. Valid Aurora PostgreSQL capacity values are (2, 4, 8, 16, 32, 64, 192, and 384). Defaults to 1. type: number - required: - - maxCapacity - - minCapacity type: object type: array skipFinalSnapshot: @@ -811,21 +802,356 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + allocatedStorage: + description: The amount of storage in gibibytes (GiB) to allocate + to each DB instance in the Multi-AZ DB cluster. + type: number + allowMajorVersionUpgrade: + description: Enable to allow major engine version upgrades when + changing engine versions. Defaults to false. + type: boolean + applyImmediately: + description: Specifies whether any cluster modifications are applied + immediately, or during the next maintenance window. Default + is false. See Amazon RDS Documentation for more information. + type: boolean + availabilityZones: + description: List of EC2 Availability Zones for the DB cluster + storage where DB cluster instances can be created. We recommend + specifying 3 AZs or using the if necessary. A maximum of 3 + AZs can be configured. + items: + type: string + type: array + backtrackWindow: + description: Target backtrack window, in seconds. Only available + for aurora and aurora-mysql engines currently. To disable backtracking, + set this value to 0. Defaults to 0. Must be between 0 and 259200 + (72 hours) + type: number + backupRetentionPeriod: + description: Days to retain backups for. Default 1 + type: number + clusterMembers: + description: – List of RDS Instances that are a part of this cluster + items: + type: string + type: array + copyTagsToSnapshot: + description: – Copy all Cluster tags to snapshots. Default is + false. + type: boolean + databaseName: + description: 'Name for an automatically created database on cluster + creation. There are different naming restrictions per database + engine: RDS Naming Constraints' + type: string + dbClusterInstanceClass: + description: Compute and memory capacity of each DB instance in + the Multi-AZ DB cluster, for example db.m6g.xlarge. Not all + DB instance classes are available in all AWS Regions, or for + all database engines. For the full list of DB instance classes + and availability for your engine, see DB instance class in the + Amazon RDS User Guide. (This setting is required to create a + Multi-AZ DB cluster). + type: string + dbClusterParameterGroupName: + type: string + dbInstanceParameterGroupName: + description: Instance parameter group to associate with all instances + of the DB cluster. The db_instance_parameter_group_name parameter + is only valid in combination with the allow_major_version_upgrade + parameter. + type: string + deletionProtection: + description: If the DB instance should have deletion protection + enabled. The database can't be deleted when this value is set + to true. The default is false. + type: boolean + enableGlobalWriteForwarding: + description: Whether cluster should forward writes to an associated + global cluster. Applied to secondary clusters to enable them + to forward writes to an aws_rds_global_cluster's primary cluster. + See the Aurora Userguide documentation for more information. + type: boolean + enableHttpEndpoint: + description: Enable HTTP endpoint (data API). Only valid when + engine_mode is set to serverless. + type: boolean + enabledCloudwatchLogsExports: + description: 'Set of log types to export to cloudwatch. If omitted, + no logs will be exported. The following log types are supported: + audit, error, general, slowquery, postgresql (PostgreSQL).' + items: + type: string + type: array + engine: + description: 'Name of the database engine to be used for this + DB cluster. Valid Values: aurora-mysql, aurora-postgresql, mysql, + postgres. (Note that mysql and postgres are Multi-AZ RDS clusters).' + type: string + engineMode: + description: 'Database engine mode. Valid values: global (only + valid for Aurora MySQL 1.21 and earlier), multimaster, parallelquery, + provisioned, serverless. Defaults to: provisioned. See the RDS + User Guide for limitations when using serverless.' + type: string + engineVersion: + description: Database engine version. Updating this argument results + in an outage. See the Aurora MySQL and Aurora Postgres documentation + for your configured engine to determine this value, or by running + aws rds describe-db-engine-versions. For example with Aurora + MySQL 2, a potential value for this argument is 5.7.mysql_aurora.2.03.2. + The value can contain a partial version where supported by the + API. The actual engine version used is returned in the attribute + engine_version_actual, , see Attributes Reference below. + type: string + finalSnapshotIdentifier: + description: Name of your final DB snapshot when this DB cluster + is deleted. If omitted, no final snapshot will be made. + type: string + globalClusterIdentifier: + description: Global cluster identifier specified on aws_rds_global_cluster. + type: string + iamDatabaseAuthenticationEnabled: + description: Specifies whether or not mappings of AWS Identity + and Access Management (IAM) accounts to database accounts is + enabled. Please see AWS Documentation for availability and limitations. + type: boolean + iops: + description: Amount of Provisioned IOPS (input/output operations + per second) to be initially allocated for each DB instance in + the Multi-AZ DB cluster. For information about valid Iops values, + see Amazon RDS Provisioned IOPS storage to improve performance + in the Amazon RDS User Guide. (This setting is required to create + a Multi-AZ DB cluster). Must be a multiple between .5 and 50 + of the storage amount for the DB cluster. + type: number + manageMasterUserPassword: + description: Set to true to allow RDS to manage the master user + password in Secrets Manager. Cannot be set if master_password + is provided. + type: boolean + masterUsername: + description: Username for the master DB user. Please refer to + the RDS Naming Constraints. This argument does not support in-place + updates and cannot be changed during a restore from snapshot. + type: string + networkType: + description: 'Network type of the cluster. Valid values: IPV4, + DUAL.' + type: string + port: + description: Port on which the DB accepts connections + type: number + preferredBackupWindow: + description: 'Daily time range during which automated backups + are created if automated backups are enabled using the BackupRetentionPeriod + parameter.Time in UTC. Default: A 30-minute window selected + at random from an 8-hour block of time per regionE.g., 04:00-09:00' + type: string + preferredMaintenanceWindow: + description: Weekly time range during which system maintenance + can occur, in (UTC) e.g., wed:04:00-wed:04:30 + type: string + replicationSourceIdentifier: + description: ARN of a source DB cluster or DB instance if this + DB cluster is to be created as a Read Replica. + type: string + restoreToPointInTime: + description: Nested attribute for point in time restore. More + details below. + items: + properties: + restoreToTime: + description: Date and time in UTC format to restore the + database cluster to. Conflicts with use_latest_restorable_time. + type: string + restoreType: + description: Type of restore to be performed. Valid options + are full-copy (default) and copy-on-write. + type: string + useLatestRestorableTime: + description: Set to true to restore the database cluster + to the latest restorable backup time. Defaults to false. + Conflicts with restore_to_time. + type: boolean + type: object + type: array + s3Import: + description: Port on which the DB accepts connections + items: + properties: + bucketName: + description: Bucket name where your backup is stored + type: string + bucketPrefix: + description: Can be blank, but is the path to your backup + type: string + ingestionRole: + description: Role applied to load the data. + type: string + sourceEngine: + description: Source engine for the backup + type: string + sourceEngineVersion: + description: Version of the source engine used to make the + backup + type: string + type: object + type: array + scalingConfiguration: + description: Nested attribute with scaling properties. Only valid + when engine_mode is set to serverless. More details below. + items: + properties: + autoPause: + description: Whether to enable automatic pause. A DB cluster + can be paused only when it's idle (it has no connections). + If a DB cluster is paused for more than seven days, the + DB cluster might be backed up with a snapshot. In this + case, the DB cluster is restored when there is a request + to connect to it. Defaults to true. + type: boolean + maxCapacity: + description: Maximum capacity for an Aurora DB cluster in + serverless DB engine mode. The maximum capacity must be + greater than or equal to the minimum capacity. Valid Aurora + MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, + 256. Valid Aurora PostgreSQL capacity values are (2, 4, + 8, 16, 32, 64, 192, and 384). Defaults to 16. + type: number + minCapacity: + description: Minimum capacity for an Aurora DB cluster in + serverless DB engine mode. The minimum capacity must be + lesser than or equal to the maximum capacity. Valid Aurora + MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, + 256. Valid Aurora PostgreSQL capacity values are (2, 4, + 8, 16, 32, 64, 192, and 384). Defaults to 1. + type: number + secondsUntilAutoPause: + description: Time, in seconds, before an Aurora DB cluster + in serverless mode is paused. Valid values are 300 through + 86400. Defaults to 300. + type: number + timeoutAction: + description: 'Action to take when the timeout is reached. + Valid values: ForceApplyCapacityChange, RollbackCapacityChange. + Defaults to RollbackCapacityChange. See documentation.' + type: string + type: object + type: array + serverlessv2ScalingConfiguration: + description: Nested attribute with scaling properties for ServerlessV2. + Only valid when engine_mode is set to provisioned. More details + below. + items: + properties: + maxCapacity: + description: Maximum capacity for an Aurora DB cluster in + serverless DB engine mode. The maximum capacity must be + greater than or equal to the minimum capacity. Valid Aurora + MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, + 256. Valid Aurora PostgreSQL capacity values are (2, 4, + 8, 16, 32, 64, 192, and 384). Defaults to 16. + type: number + minCapacity: + description: Minimum capacity for an Aurora DB cluster in + serverless DB engine mode. The minimum capacity must be + lesser than or equal to the maximum capacity. Valid Aurora + MySQL capacity values are 1, 2, 4, 8, 16, 32, 64, 128, + 256. Valid Aurora PostgreSQL capacity values are (2, 4, + 8, 16, 32, 64, 192, and 384). Defaults to 1. + type: number + type: object + type: array + skipFinalSnapshot: + description: Determines whether a final DB snapshot is created + before the DB cluster is deleted. If true is specified, no DB + snapshot is created. If false is specified, a DB snapshot is + created before the DB cluster is deleted, using the value from + final_snapshot_identifier. Default is false. + type: boolean + snapshotIdentifier: + description: Specifies whether or not to create this cluster from + a snapshot. You can use either the name or ARN when specifying + a DB cluster snapshot, or the ARN when specifying a DB snapshot. + Conflicts with global_cluster_identifier. Clusters cannot be + restored from snapshot and joined to an existing global cluster + in a single operation. See the AWS documentation or the Global + Cluster Restored From Snapshot example for instructions on building + a global cluster starting with a snapshot. + type: string + sourceRegion: + description: The source region for an encrypted replica DB cluster. + type: string + storageEncrypted: + description: Specifies whether the DB cluster is encrypted. The + default is false for provisioned engine_mode and true for serverless + engine_mode. When restoring an unencrypted snapshot_identifier, + the kms_key_id argument must be provided to encrypt the restored + cluster. + type: boolean + storageType: + description: '(Forces new for Multi-AZ DB clusters) Specifies + the storage type to be associated with the DB cluster. For Aurora + DB clusters, storage_type modifications can be done in-place. + For Multi-AZ DB Clusters, the iops argument must also be set. + Valid values are: "", aurora-iopt1 (Aurora DB Clusters); io1 + (Multi-AZ DB Clusters). Default: "" (Aurora DB Clusters); io1 + (Multi-AZ DB Clusters).' + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the DB cluster. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: Map of tags assigned to the resource, including those + inherited from the provider default_tags configuration block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -864,42 +1190,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -998,10 +1288,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: engine is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engine) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.engine is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) + || (has(self.initProvider) && has(self.initProvider.engine))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterStatus defines the observed state of Cluster. properties: @@ -1426,6 +1719,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_clustersnapshots.yaml b/package/crds/rds.aws.kubedb.com_clustersnapshots.yaml index 3f31d52..7d70428 100644 --- a/package/crds/rds.aws.kubedb.com_clustersnapshots.yaml +++ b/package/crds/rds.aws.kubedb.com_clustersnapshots.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: clustersnapshots.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -167,21 +166,61 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + dbClusterSnapshotIdentifier: + description: The Identifier for the snapshot. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the DB cluster. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -220,42 +259,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -354,10 +357,14 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: dbClusterSnapshotIdentifier is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.dbClusterSnapshotIdentifier) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.dbClusterSnapshotIdentifier is a required + parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.dbClusterSnapshotIdentifier) + || (has(self.initProvider) && has(self.initProvider.dbClusterSnapshotIdentifier))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ClusterSnapshotStatus defines the observed state of ClusterSnapshot. properties: @@ -466,6 +473,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_dbinstanceautomatedbackupsreplications.yaml b/package/crds/rds.aws.kubedb.com_dbinstanceautomatedbackupsreplications.yaml index 0ebdca8..c9c307e 100644 --- a/package/crds/rds.aws.kubedb.com_dbinstanceautomatedbackupsreplications.yaml +++ b/package/crds/rds.aws.kubedb.com_dbinstanceautomatedbackupsreplications.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: dbinstanceautomatedbackupsreplications.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -59,7 +58,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -239,21 +238,53 @@ spec: type: object type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + preSignedUrl: + description: A URL that contains a Signature Version 4 signed + request for the StartDBInstanceAutomatedBackupsReplication action + to be called in the AWS Region of the source DB instance. + type: string + retentionPeriod: + description: The retention period for the replicated automated + backups, defaults to 7. + type: number + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -292,42 +323,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -426,8 +421,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: DBInstanceAutomatedBackupsReplicationStatus defines the observed state of DBInstanceAutomatedBackupsReplication. @@ -491,6 +487,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_dbsnapshotcopies.yaml b/package/crds/rds.aws.kubedb.com_dbsnapshotcopies.yaml index 5034b39..a719677 100644 --- a/package/crds/rds.aws.kubedb.com_dbsnapshotcopies.yaml +++ b/package/crds/rds.aws.kubedb.com_dbsnapshotcopies.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: dbsnapshotcopies.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -259,21 +258,78 @@ spec: description: The Identifier for the snapshot. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + copyTags: + description: Whether to copy existing tags. Defaults to false. + type: boolean + destinationRegion: + description: The Destination region to place snapshot copy. + type: string + optionGroupName: + description: The name of an option group to associate with the + copy of the snapshot. + type: string + presignedUrl: + description: he URL that contains a Signature Version 4 signed + request. + type: string + tags: + additionalProperties: + type: string + description: Key-value map of resource tags. If configured with + a provider default_tags configuration block present, tags with + matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + targetCustomAvailabilityZone: + description: The external custom Availability Zone. + type: string + targetDbSnapshotIdentifier: + description: The Identifier for the snapshot. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -312,42 +368,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -446,10 +466,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: targetDbSnapshotIdentifier is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.targetDbSnapshotIdentifier) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.targetDbSnapshotIdentifier is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.targetDbSnapshotIdentifier) + || (has(self.initProvider) && has(self.initProvider.targetDbSnapshotIdentifier))' status: description: DBSnapshotCopyStatus defines the observed state of DBSnapshotCopy. properties: @@ -573,6 +596,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_eventsubscriptions.yaml b/package/crds/rds.aws.kubedb.com_eventsubscriptions.yaml index 2426bdf..be822b4 100644 --- a/package/crds/rds.aws.kubedb.com_eventsubscriptions.yaml +++ b/package/crds/rds.aws.kubedb.com_eventsubscriptions.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: eventsubscriptions.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -115,21 +114,86 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + enabled: + description: A boolean flag to enable/disable the subscription. + Defaults to true. + type: boolean + eventCategories: + description: A list of event categories for a SourceType that + you want to subscribe to. See http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html + or run aws rds describe-event-categories. + items: + type: string + type: array + snsTopic: + description: The SNS topic to send events to. + type: string + sourceIds: + description: A list of identifiers of the event sources for which + events will be returned. If not specified, then all sources + are included in the response. If specified, a source_type must + also be specified. + items: + type: string + type: array + sourceType: + description: The type of source that will be generating the events. + Valid options are db-instance, db-security-group, db-parameter-group, + db-snapshot, db-cluster or db-cluster-snapshot. If not set, + all sources will be subscribed to. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -168,42 +232,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -302,10 +330,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: snsTopic is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.snsTopic) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.snsTopic is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.snsTopic) + || (has(self.initProvider) && has(self.initProvider.snsTopic))' status: description: EventSubscriptionStatus defines the observed state of EventSubscription. properties: @@ -398,6 +429,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_globalclusters.yaml b/package/crds/rds.aws.kubedb.com_globalclusters.yaml index 7050658..2789096 100644 --- a/package/crds/rds.aws.kubedb.com_globalclusters.yaml +++ b/package/crds/rds.aws.kubedb.com_globalclusters.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: globalclusters.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -182,21 +181,76 @@ spec: and encrypted. type: boolean type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + databaseName: + description: Name for an automatically created database on cluster + creation. + type: string + deletionProtection: + description: If the Global Cluster should have deletion protection + enabled. The database can't be deleted when this value is set + to true. The default is false. + type: boolean + engine: + description: 'Name of the database engine to be used for this + DB cluster. Valid values: aurora, aurora-mysql, aurora-postgresql. + Defaults to aurora. Conflicts with source_db_cluster_identifier.' + type: string + engineVersion: + description: 'Engine version of the Aurora global database. The + engine, engine_version, and instance_class (on the aws_rds_cluster_instance) + must together support global databases. See Using Amazon Aurora + global databases for more information. NOTE: To avoid an inconsistent + final plan error while upgrading, use the lifecycle ignore_changes + for engine_version meta argument on the associated aws_rds_cluster + resource as shown above in Upgrading Engine Versions example.' + type: string + forceDestroy: + description: Enable to remove DB Cluster members from Global Cluster + on destroy. Required with source_db_cluster_identifier. + type: boolean + storageEncrypted: + description: Specifies whether the DB cluster is encrypted. The + default is false unless source_db_cluster_identifier is specified + and encrypted. + type: boolean + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -235,42 +289,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -369,8 +387,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: GlobalClusterStatus defines the observed state of GlobalCluster. properties: @@ -471,6 +490,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_instanceroleassociations.yaml b/package/crds/rds.aws.kubedb.com_instanceroleassociations.yaml index 87f841e..57c740a 100644 --- a/package/crds/rds.aws.kubedb.com_instanceroleassociations.yaml +++ b/package/crds/rds.aws.kubedb.com_instanceroleassociations.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: instanceroleassociations.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -59,7 +58,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -161,21 +160,54 @@ spec: with the DB Instance. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + featureName: + description: Name of the feature for association. This can be + found in the AWS documentation relevant to the integration or + a full list is available in the SupportedFeatureNames list returned + by AWS CLI rds describe-db-engine-versions. + type: string + roleArn: + description: Amazon Resource Name (ARN) of the IAM Role to associate + with the DB Instance. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -214,42 +246,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -348,12 +344,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: featureName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.featureName) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: roleArn is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn) + - message: spec.forProvider.featureName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.featureName) + || (has(self.initProvider) && has(self.initProvider.featureName))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.roleArn is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.roleArn) + || (has(self.initProvider) && has(self.initProvider.roleArn))' status: description: InstanceRoleAssociationStatus defines the observed state of InstanceRoleAssociation. @@ -412,6 +413,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_instances.yaml b/package/crds/rds.aws.kubedb.com_instances.yaml index f5596c6..6303d36 100644 --- a/package/crds/rds.aws.kubedb.com_instances.yaml +++ b/package/crds/rds.aws.kubedb.com_instances.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: instances.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -706,11 +705,6 @@ spec: description: Version of the source engine used to make the backup type: string - required: - - bucketName - - ingestionRole - - sourceEngine - - sourceEngineVersion type: object type: array skipFinalSnapshot: @@ -849,21 +843,381 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + allocatedStorage: + description: The allocated storage in gibibytes. If max_allocated_storage + is configured, this argument represents the initial storage + allocation and differences from the configuration will be ignored + automatically when Storage Autoscaling occurs. If replicate_source_db + is set, the value is ignored during the creation of the instance. + type: number + allowMajorVersionUpgrade: + description: Indicates that major version upgrades are allowed. + Changing this parameter does not result in an outage and the + change is asynchronously applied as soon as possible. + type: boolean + applyImmediately: + description: Specifies whether any database modifications are + applied immediately, or during the next maintenance window. + Default is false. See Amazon RDS Documentation for more information. + type: boolean + autoMinorVersionUpgrade: + description: Indicates that minor engine upgrades will be applied + automatically to the DB instance during the maintenance window. + Defaults to true. + type: boolean + availabilityZone: + description: The AZ for the RDS instance. + type: string + backupRetentionPeriod: + description: The days to retain backups for. Must be between 0 + and 35. Default is 0. Must be greater than 0 if the database + is used as a source for a Read Replica, uses low-downtime updates, + or will use RDS Blue/Green deployments. + type: number + backupWindow: + description: 'The daily time range (in UTC) during which automated + backups are created if they are enabled. Example: "09:46-10:16". + Must not overlap with maintenance_window.' + type: string + blueGreenUpdate: + description: Enables low-downtime updates using RDS Blue/Green + deployments. See blue_green_update below + items: + properties: + enabled: + description: Enables [low-downtime updates](#Low-Downtime + Updates) when true. Default is false. + type: boolean + type: object + type: array + caCertIdentifier: + description: The identifier of the CA certificate for the DB instance. + type: string + characterSetName: + description: The character set name to use for DB encoding in + Oracle and Microsoft SQL instances (collation). This can't be + changed. See Oracle Character Sets Supported in Amazon RDS or + Server-Level Collation for Microsoft SQL Server for more information. + type: string + copyTagsToSnapshot: + description: – Copy all Instance tags to snapshots. Default is + false. + type: boolean + customIamInstanceProfile: + description: The instance profile associated with the underlying + Amazon EC2 instance of an RDS Custom DB instance. + type: string + customerOwnedIpEnabled: + description: Indicates whether to enable a customer-owned IP address + (CoIP) for an RDS on Outposts DB instance. See CoIP for RDS + on Outposts for more information. + type: boolean + dbName: + description: The name of the database to create when the DB instance + is created. If this parameter is not specified, no database + is created in the DB instance. Note that this does not apply + for Oracle or SQL Server engines. See the AWS documentation + for more details on what applies for those engines. If you are + providing an Oracle db name, it needs to be in all upper case. + Cannot be specified for a replica. + type: string + deleteAutomatedBackups: + description: Specifies whether to remove automated backups immediately + after the DB instance is deleted. Default is true. + type: boolean + deletionProtection: + description: If the DB instance should have deletion protection + enabled. The database can't be deleted when this value is set + to true. The default is false. + type: boolean + domain: + description: The ID of the Directory Service Active Directory + domain to create the instance in. + type: string + domainIamRoleName: + description: The name of the IAM role to be used when making API + calls to the Directory Service. + type: string + enabledCloudwatchLogsExports: + description: 'Set of log types to enable for exporting to CloudWatch + logs. If omitted, no logs will be exported. Valid values (depending + on engine). MySQL and MariaDB: audit, error, general, slowquery. + PostgreSQL: postgresql, upgrade. MSSQL: agent , error. Oracle: + alert, audit, listener, trace.' + items: + type: string + type: array + engine: + description: The database engine to use. For supported values, + see the Engine parameter in [API action CreateDBInstance](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html). + Note that for Amazon Aurora instances the engine must match + the [DB Cluster](https://marketplace.upbound.io/providers/kubedb.dev/provider-aws/latest/resources/rds.aws.upbound.io/Cluster/v1alpha1)'s + engine'. For information on the difference between the available + Aurora MySQL engines see Comparison in the [Amazon RDS Release + Notes](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraMySQLReleaseNotes/Welcome.html). + type: string + engineVersion: + description: The engine version to use. If `autoMinorVersionUpgrade` + is enabled, you can provide a prefix of the version such as + 5.7 (for 5.7.10). The actual engine version used is returned + in the attribute `status.atProvider.engineVersionActual`. For + supported values, see the EngineVersion parameter in [API action + CreateDBInstance](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html). + Note that for Amazon Aurora instances the engine version must + match the [DB Cluster](https://marketplace.upbound.io/providers/kubedb.dev/provider-aws/latest/resources/rds.aws.upbound.io/Cluster/v1alpha1)'s + engine version'. + type: string + finalSnapshotIdentifier: + description: The name of your final DB snapshot when this DB instance + is deleted. Must be provided if skip_final_snapshot is set to + false. The value must begin with a letter, only contain alphanumeric + characters and hyphens, and not end with a hyphen or contain + two consecutive hyphens. Must not be provided when deleting + a read replica. + type: string + iamDatabaseAuthenticationEnabled: + description: Specifies whether mappings of AWS Identity and Access + Management (IAM) accounts to database accounts is enabled. + type: boolean + instanceClass: + description: The instance type of the RDS instance. + type: string + iops: + description: The amount of provisioned IOPS. Setting this implies + a storage_type of "io1". Can only be set when storage_type is + "io1" or "gp3". Cannot be specified for gp3 storage if the allocated_storage + value is below a per-engine threshold. See the RDS User Guide + for details. + type: number + licenseModel: + description: License model information for this DB instance. + type: string + maintenanceWindow: + description: 'The window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". + Eg: "Mon:00:00-Mon:03:00". See RDS Maintenance Window docs for + more information.' + type: string + manageMasterUserPassword: + description: Set to true to allow RDS to manage the master user + password in Secrets Manager. Cannot be set if password is provided. + type: boolean + maxAllocatedStorage: + description: When configured, the upper limit to which Amazon + RDS can automatically scale the storage of the DB instance. + Configuring this will automatically ignore differences to allocated_storage. + Must be greater than or equal to allocated_storage or 0 to disable + Storage Autoscaling. + type: number + monitoringInterval: + description: 'The interval, in seconds, between points when Enhanced + Monitoring metrics are collected for the DB instance. To disable + collecting Enhanced Monitoring metrics, specify 0. The default + is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.' + type: number + monitoringRoleArn: + description: The ARN for the IAM role that permits RDS to send + enhanced monitoring metrics to CloudWatch Logs. You can find + more information on the AWS Documentation what IAM permissions + are needed to allow Enhanced Monitoring for RDS Instances. + type: string + multiAz: + description: Specifies if the RDS instance is multi-AZ + type: boolean + ncharCharacterSetName: + description: The national character set is used in the NCHAR, + NVARCHAR2, and NCLOB data types for Oracle instances. This can't + be changed. See Oracle Character Sets Supported in Amazon RDS. + type: string + networkType: + description: 'The network type of the DB instance. Valid values: + IPV4, DUAL.' + type: string + optionGroupName: + description: Name of the DB option group to associate. + type: string + parameterGroupName: + description: Name of the DB parameter group to associate. + type: string + performanceInsightsEnabled: + description: Specifies whether Performance Insights are enabled. + Defaults to false. + type: boolean + performanceInsightsKmsKeyId: + description: The ARN for the KMS key to encrypt Performance Insights + data. When specifying performance_insights_kms_key_id, performance_insights_enabled + needs to be set to true. Once KMS key is set, it can never be + changed. + type: string + performanceInsightsRetentionPeriod: + description: Amount of time in days to retain Performance Insights + data. Valid values are 7, 731 (2 years) or a multiple of 31. + When specifying performance_insights_retention_period, performance_insights_enabled + needs to be set to true. Defaults to '7'. + type: number + port: + description: The port on which the DB accepts connections. + type: number + publiclyAccessible: + description: Bool to control if instance is publicly accessible. + Default is false. + type: boolean + replicaMode: + description: Specifies whether the replica is in either mounted + or open-read-only mode. This attribute is only supported by + Oracle instances. Oracle replicas operate in open-read-only + mode unless otherwise specified. See Working with Oracle Read + Replicas for more information. + type: string + restoreToPointInTime: + description: A configuration block for restoring a DB instance + to an arbitrary point in time. Requires the identifier argument + to be set with the name of the new DB instance to be created. + See Restore To Point In Time below for details. + items: + properties: + restoreTime: + description: The date and time to restore from. Value must + be a time in Universal Coordinated Time (UTC) format and + must be before the latest restorable time for the DB instance. + Cannot be specified with use_latest_restorable_time. + type: string + sourceDbInstanceAutomatedBackupsArn: + description: The ARN of the automated backup from which + to restore. Required if source_db_instance_identifier + or source_dbi_resource_id is not specified. + type: string + sourceDbInstanceIdentifier: + description: The identifier of the source DB instance from + which to restore. Must match the identifier of an existing + DB instance. Required if source_db_instance_automated_backups_arn + or source_dbi_resource_id is not specified. + type: string + sourceDbiResourceId: + description: The resource ID of the source DB instance from + which to restore. Required if source_db_instance_identifier + or source_db_instance_automated_backups_arn is not specified. + type: string + useLatestRestorableTime: + description: A boolean value that indicates whether the + DB instance is restored from the latest backup time. Defaults + to false. Cannot be specified with restore_time. + type: boolean + type: object + type: array + s3Import: + description: Restore from a Percona Xtrabackup in S3. See Importing + Data into an Amazon RDS MySQL DB Instance + items: + properties: + bucketName: + description: The bucket name where your backup is stored + type: string + bucketPrefix: + description: Can be blank, but is the path to your backup + type: string + ingestionRole: + description: Role applied to load the data. + type: string + sourceEngine: + description: Source engine for the backup + type: string + sourceEngineVersion: + description: Version of the source engine used to make the + backup + type: string + type: object + type: array + skipFinalSnapshot: + description: Determines whether a final DB snapshot is created + before the DB instance is deleted. If true is specified, no + DBSnapshot is created. If false is specified, a DB snapshot + is created before the DB instance is deleted, using the value + from final_snapshot_identifier. Default is false. + type: boolean + snapshotIdentifier: + description: 'Specifies whether or not to create this database + from a snapshot. This correlates to the snapshot ID you''d find + in the RDS console, e.g: rds:production-2015-06-26-06-05.' + type: string + storageEncrypted: + description: Specifies whether the DB instance is encrypted. Note + that if you are creating a cross-region read replica this field + is ignored and you should instead declare kms_key_id with a + valid ARN. The default is false if not specified. + type: boolean + storageThroughput: + description: The storage throughput value for the DB instance. + Can only be set when storage_type is "gp3". Cannot be specified + if the allocated_storage value is below a per-engine threshold. + See the RDS User Guide for details. + type: number + storageType: + description: One of "standard" (magnetic), "gp2" (general purpose + SSD), "gp3" (general purpose SSD that needs iops independently) + or "io1" (provisioned IOPS SSD). The default is "io1" if iops + is specified, "gp2" if not. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + timezone: + description: Time zone of the DB instance. timezone is currently + only supported by Microsoft SQL Server. The timezone can only + be set on creation. See MSSQL User Guide for more information. + type: string + username: + description: Username for the master DB user. Cannot be specified + for a replica. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -902,42 +1256,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -1036,10 +1354,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: instanceClass is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.instanceClass) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.instanceClass is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.instanceClass) + || (has(self.initProvider) && has(self.initProvider.instanceClass))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: InstanceStatus defines the observed state of Instance. properties: @@ -1523,6 +1844,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_optiongroups.yaml b/package/crds/rds.aws.kubedb.com_optiongroups.yaml index 19d669b..8b930ac 100644 --- a/package/crds/rds.aws.kubedb.com_optiongroups.yaml +++ b/package/crds/rds.aws.kubedb.com_optiongroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: optiongroups.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -100,9 +99,6 @@ spec: value: description: The Value of the setting. type: string - required: - - name - - value type: object type: array port: @@ -118,8 +114,6 @@ spec: items: type: string type: array - required: - - optionName type: object type: array optionGroupDescription: @@ -144,21 +138,110 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + engineName: + description: Specifies the name of the engine that this option + group should be associated with. + type: string + majorEngineVersion: + description: Specifies the major version of the engine that this + option group should be associated with. + type: string + option: + description: A list of Options to apply. + items: + properties: + dbSecurityGroupMemberships: + description: A list of DB Security Groups for which the + option is enabled. + items: + type: string + type: array + optionName: + description: The Name of the Option (e.g., MEMCACHED). + type: string + optionSettings: + description: A list of option settings to apply. + items: + properties: + name: + description: The name of the option group. Must be + lowercase, to match as it is stored in AWS. + type: string + value: + description: The Value of the setting. + type: string + type: object + type: array + port: + description: The Port number when connecting to the Option + (e.g., 11211). + type: number + version: + description: The version of the option (e.g., 13.1.0.0). + type: string + vpcSecurityGroupMemberships: + description: A list of VPC Security Groups for which the + option is enabled. + items: + type: string + type: array + type: object + type: array + optionGroupDescription: + description: The description of the option group. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -197,42 +280,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -331,12 +378,17 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: engineName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engineName) - - message: majorEngineVersion is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.majorEngineVersion) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.engineName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engineName) + || (has(self.initProvider) && has(self.initProvider.engineName))' + - message: spec.forProvider.majorEngineVersion is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.majorEngineVersion) + || (has(self.initProvider) && has(self.initProvider.majorEngineVersion))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: OptionGroupStatus defines the observed state of OptionGroup. properties: @@ -448,6 +500,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_parametergroups.yaml b/package/crds/rds.aws.kubedb.com_parametergroups.yaml index 8eefb1d..e19dcc4 100644 --- a/package/crds/rds.aws.kubedb.com_parametergroups.yaml +++ b/package/crds/rds.aws.kubedb.com_parametergroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: parametergroups.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -92,9 +91,6 @@ spec: value: description: The value of the DB parameter. type: string - required: - - name - - value type: object type: array region: @@ -116,21 +112,84 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the DB parameter group. + type: string + family: + description: The family of the DB parameter group. + type: string + parameter: + description: A list of DB parameters to apply. Note that parameters + may differ from a family to an other. Full list of all parameters + can be discovered via aws rds describe-db-parameters after initial + creation of the group. + items: + properties: + applyMethod: + description: '"immediate" (default), or "pending-reboot". + Some engines can''t apply some parameters without a reboot, + and you will need to specify "pending-reboot" here.' + type: string + name: + description: The name of the DB parameter group. + type: string + value: + description: The value of the DB parameter. + type: string + type: object + type: array + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -169,42 +228,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -303,10 +326,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: family is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.family) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.family is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.family) + || (has(self.initProvider) && has(self.initProvider.family))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ParameterGroupStatus defines the observed state of ParameterGroup. properties: @@ -392,6 +418,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_proxies.yaml b/package/crds/rds.aws.kubedb.com_proxies.yaml index 04c9694..444fc79 100644 --- a/package/crds/rds.aws.kubedb.com_proxies.yaml +++ b/package/crds/rds.aws.kubedb.com_proxies.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: proxies.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -246,21 +245,134 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + auth: + description: Configuration block(s) with authorization mechanisms + to connect to the associated instances or clusters. Described + below. + items: + properties: + authScheme: + description: The type of authentication that the proxy uses + for connections from the proxy to the underlying database. + One of SECRETS. + type: string + clientPasswordAuthType: + description: The type of authentication the proxy uses for + connections from clients. Valid values are MYSQL_NATIVE_PASSWORD, + POSTGRES_SCRAM_SHA_256, POSTGRES_MD5, and SQL_SERVER_AUTHENTICATION. + type: string + description: + description: A user-specified description about the authentication + used by a proxy to log in as a specific database user. + type: string + iamAuth: + description: Whether to require or disallow AWS Identity + and Access Management (IAM) authentication for connections + to the proxy. One of DISABLED, REQUIRED. + type: string + secretArn: + description: The Amazon Resource Name (ARN) representing + the secret that the proxy uses to authenticate to the + RDS DB instance or Aurora DB cluster. These secrets are + stored within Amazon Secrets Manager. + type: string + username: + description: The name of the database user to which the + proxy connects. + type: string + type: object + type: array + debugLogging: + description: Whether the proxy includes detailed information about + SQL statements in its logs. This information helps you to debug + issues involving SQL behavior or the performance and scalability + of the proxy connections. The debug information includes the + text of SQL statements that you submit through the proxy. Thus, + only enable this setting when needed for debugging, and only + when you have security measures in place to safeguard any sensitive + information that appears in the logs. + type: boolean + engineFamily: + description: The kinds of databases that the proxy can connect + to. This value determines which database network protocol the + proxy recognizes when it interprets network traffic to and from + the database. The engine family applies to MySQL and PostgreSQL + for both RDS and Aurora. Valid values are MYSQL and POSTGRESQL. + type: string + idleClientTimeout: + description: The number of seconds that a connection to the proxy + can be inactive before the proxy disconnects it. You can set + this value higher or lower than the connection timeout limit + for the associated database. + type: number + requireTls: + description: A Boolean parameter that specifies whether Transport + Layer Security (TLS) encryption is required for connections + to the proxy. By enabling this setting, you can enforce encrypted + TLS connections to the proxy. + type: boolean + roleArn: + description: The Amazon Resource Name (ARN) of the IAM role that + the proxy uses to access secrets in AWS Secrets Manager. + type: string + tags: + additionalProperties: + type: string + description: A mapping of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + vpcSubnetIds: + description: One or more VPC subnet IDs to associate with the + new proxy. + items: + type: string + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -299,42 +411,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -433,16 +509,25 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: auth is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.auth) - - message: engineFamily is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.engineFamily) - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: roleArn is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.roleArn) - - message: vpcSubnetIds is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.vpcSubnetIds) + - message: spec.forProvider.auth is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.auth) + || (has(self.initProvider) && has(self.initProvider.auth))' + - message: spec.forProvider.engineFamily is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.engineFamily) + || (has(self.initProvider) && has(self.initProvider.engineFamily))' + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.roleArn is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.roleArn) + || (has(self.initProvider) && has(self.initProvider.roleArn))' + - message: spec.forProvider.vpcSubnetIds is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.vpcSubnetIds) + || (has(self.initProvider) && has(self.initProvider.vpcSubnetIds))' status: description: ProxyStatus defines the observed state of Proxy. properties: @@ -589,6 +674,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_proxydefaulttargetgroups.yaml b/package/crds/rds.aws.kubedb.com_proxydefaulttargetgroups.yaml index b73077e..30275fa 100644 --- a/package/crds/rds.aws.kubedb.com_proxydefaulttargetgroups.yaml +++ b/package/crds/rds.aws.kubedb.com_proxydefaulttargetgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: proxydefaulttargetgroups.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -59,7 +58,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -202,21 +201,96 @@ spec: be created in. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + connectionPoolConfig: + description: The settings that determine the size and behavior + of the connection pool for the target group. + items: + properties: + connectionBorrowTimeout: + description: The number of seconds for a proxy to wait for + a connection to become available in the connection pool. + Only applies when the proxy has opened its maximum number + of connections and all connections are busy with client + sessions. + type: number + initQuery: + description: One or more SQL statements for the proxy to + run when opening each new database connection. Typically + used with SET statements to make sure that each connection + has identical settings such as time zone and character + set. This setting is empty by default. For multiple statements, + use semicolons as the separator. You can also include + multiple variables in a single SET statement, such as + SET x=1, y=2. + type: string + maxConnectionsPercent: + description: The maximum size of the connection pool for + each target in a target group. For Aurora MySQL, it is + expressed as a percentage of the max_connections setting + for the RDS DB instance or Aurora DB cluster used by the + target group. + type: number + maxIdleConnectionsPercent: + description: Controls how actively the proxy closes idle + database connections in the connection pool. A high value + enables the proxy to leave a high percentage of idle connections + open. A low value causes the proxy to close idle client + connections and return the underlying database connections + to the connection pool. For Aurora MySQL, it is expressed + as a percentage of the max_connections setting for the + RDS DB instance or Aurora DB cluster used by the target + group. + type: number + sessionPinningFilters: + description: Each item in the list represents a class of + SQL operations that normally cause all later statements + in a session using a proxy to be pinned to the same underlying + database connection. Including an item in the list exempts + that class of SQL operations from the pinning behavior. + Currently, the only allowed value is EXCLUDE_VARIABLE_SETS. + items: + type: string + type: array + type: object + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -255,42 +329,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -389,8 +427,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: ProxyDefaultTargetGroupStatus defines the observed state of ProxyDefaultTargetGroup. @@ -496,6 +535,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_proxyendpoints.yaml b/package/crds/rds.aws.kubedb.com_proxyendpoints.yaml index d65dcd9..144af9b 100644 --- a/package/crds/rds.aws.kubedb.com_proxyendpoints.yaml +++ b/package/crds/rds.aws.kubedb.com_proxyendpoints.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: proxyendpoints.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -253,21 +252,64 @@ spec: type: string type: array type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + tags: + additionalProperties: + type: string + description: A mapping of tags to assign to the resource. + type: object + tagsAll: + additionalProperties: + type: string + type: object + targetRole: + description: Indicates whether the DB proxy endpoint can be used + for read/write or read-only operations. The default is READ_WRITE. + Valid values are READ_WRITE and READ_ONLY. + type: string + vpcSubnetIds: + description: One or more VPC subnet IDs to associate with the + new proxy. + items: + type: string + type: array + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -306,42 +348,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -440,10 +446,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: vpcSubnetIds is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.vpcSubnetIds) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.vpcSubnetIds is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.vpcSubnetIds) + || (has(self.initProvider) && has(self.initProvider.vpcSubnetIds))' status: description: ProxyEndpointStatus defines the observed state of ProxyEndpoint. properties: @@ -532,6 +541,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_proxytargets.yaml b/package/crds/rds.aws.kubedb.com_proxytargets.yaml index 8c2bbb1..6cbf721 100644 --- a/package/crds/rds.aws.kubedb.com_proxytargets.yaml +++ b/package/crds/rds.aws.kubedb.com_proxytargets.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: proxytargets.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -231,21 +230,50 @@ spec: description: The name of the target group. type: string type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + dbClusterIdentifier: + description: DB cluster identifier. + type: string + targetGroupName: + description: The name of the target group. + type: string + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -284,42 +312,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -418,10 +410,13 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) - - message: targetGroupName is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.targetGroupName) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' + - message: spec.forProvider.targetGroupName is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.targetGroupName) + || (has(self.initProvider) && has(self.initProvider.targetGroupName))' status: description: ProxyTargetStatus defines the observed state of ProxyTarget. properties: @@ -502,6 +497,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_snapshots.yaml b/package/crds/rds.aws.kubedb.com_snapshots.yaml index affd499..1f3d046 100644 --- a/package/crds/rds.aws.kubedb.com_snapshots.yaml +++ b/package/crds/rds.aws.kubedb.com_snapshots.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: snapshots.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -170,21 +169,64 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + sharedAccounts: + description: List of AWS Account ids to share snapshot with, use + all to make snaphot public. + items: + type: string + type: array + tags: + additionalProperties: + type: string + description: Key-value map of resource tags. If configured with + a provider default_tags configuration block present, tags with + matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -223,42 +265,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -357,8 +363,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SnapshotStatus defines the observed state of Snapshot. properties: @@ -479,6 +486,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec diff --git a/package/crds/rds.aws.kubedb.com_subnetgroups.yaml b/package/crds/rds.aws.kubedb.com_subnetgroups.yaml index dcc1b13..91bbc0f 100644 --- a/package/crds/rds.aws.kubedb.com_subnetgroups.yaml +++ b/package/crds/rds.aws.kubedb.com_subnetgroups.yaml @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.11.3 - creationTimestamp: null + controller-gen.kubebuilder.io/version: v0.13.0 name: subnetgroups.rds.aws.kubedb.com spec: group: rds.aws.kubedb.com @@ -58,7 +57,7 @@ spec: description: 'DeletionPolicy specifies what will happen to the underlying external when this managed resource is deleted - either "Delete" or "Orphan" the external resource. This field is planned to be deprecated - in favor of the ManagementPolicy field in a future release. Currently, + in favor of the ManagementPolicies field in a future release. Currently, both could be set independently and non-default values would be honored if the feature flag is enabled. See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' @@ -172,21 +171,61 @@ spec: block. type: object type: object - managementPolicy: - default: FullControl - description: 'THIS IS AN ALPHA FIELD. Do not use it in production. - It is not honored unless the relevant Crossplane feature flag is - enabled, and may be changed or removed without notice. ManagementPolicy - specifies the level of control Crossplane has over the managed external - resource. This field is planned to replace the DeletionPolicy field - in a future release. Currently, both could be set independently - and non-default values would be honored if the feature flag is enabled. - See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223' - enum: - - FullControl - - ObserveOnly - - OrphanOnDelete - type: string + initProvider: + description: THIS IS A BETA FIELD. It will be honored unless the Management + Policies feature flag is disabled. InitProvider holds the same fields + as ForProvider, with the exception of Identifier and other resource + reference fields. The fields that are in InitProvider are merged + into ForProvider when the resource is created. The same fields are + also added to the terraform ignore_changes hook, to avoid updating + them after creation. This is useful for fields that are required + on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, + like an autoscaler. + properties: + description: + description: The description of the DB subnet group. + type: string + tags: + additionalProperties: + type: string + description: A map of tags to assign to the resource. If configured + with a provider default_tags configuration block present, tags + with matching keys will overwrite those defined at the provider-level. + type: object + tagsAll: + additionalProperties: + type: string + description: A map of tags assigned to the resource, including + those inherited from the provider default_tags configuration + block. + type: object + type: object + managementPolicies: + default: + - '*' + description: 'THIS IS A BETA FIELD. It is on by default but can be + opted out through a Crossplane feature flag. ManagementPolicies + specify the array of actions Crossplane is allowed to take on the + managed and external resources. This field is planned to replace + the DeletionPolicy field in a future release. Currently, both could + be set independently and non-default values would be honored if + the feature flag is enabled. If both are custom, the DeletionPolicy + field will be ignored. See the design doc for more information: + https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md' + items: + description: A ManagementAction represents an action that the Crossplane + controllers can take on an external resource. + enum: + - Observe + - Create + - Update + - Delete + - LateInitialize + - '*' + type: string + type: array providerConfigRef: default: name: default @@ -225,42 +264,6 @@ spec: required: - name type: object - providerRef: - description: 'ProviderReference specifies the provider that will be - used to create, observe, update, and delete this managed resource. - Deprecated: Please use ProviderConfigReference, i.e. `providerConfigRef`' - properties: - name: - description: Name of the referenced object. - type: string - policy: - description: Policies for referencing. - properties: - resolution: - default: Required - description: Resolution specifies whether resolution of this - reference is required. The default is 'Required', which - means the reconcile will fail if the reference cannot be - resolved. 'Optional' means this reference will be a no-op - if it cannot be resolved. - enum: - - Required - - Optional - type: string - resolve: - description: Resolve specifies when this reference should - be resolved. The default is 'IfNotPresent', which will attempt - to resolve the reference only when the corresponding field - is not present. Use 'Always' to resolve the reference on - every reconcile. - enum: - - Always - - IfNotPresent - type: string - type: object - required: - - name - type: object publishConnectionDetailsTo: description: PublishConnectionDetailsTo specifies the connection secret config which contains a name, metadata and a reference to secret @@ -359,8 +362,9 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: region is a required parameter - rule: self.managementPolicy == 'ObserveOnly' || has(self.forProvider.region) + - message: spec.forProvider.region is a required parameter + rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies + || ''Update'' in self.managementPolicies) || has(self.forProvider.region)' status: description: SubnetGroupStatus defines the observed state of SubnetGroup. properties: @@ -436,6 +440,9 @@ spec: - type type: object type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map type: object required: - spec