From c21e55a70dc003647bc89e90b502de6e6d458e16 Mon Sep 17 00:00:00 2001 From: Mike Ross Date: Mon, 26 Mar 2018 19:24:51 +0000 Subject: [PATCH] Releasing version 1.3.17 --- CHANGELOG.rst | 13 + docs/exceptions.rst | 47 + docs/index.rst | 1 + docs/sdk-with-proxy.rst | 6 + docs/sdk_behaviors/index.rst | 4 +- docs/sdk_behaviors/retries.rst | 44 + examples/remote_peering_connection_example.py | 307 +++++ examples/retries.py | 120 ++ src/oci/audit/audit_client.py | 19 +- src/oci/audit/models/audit_event.py | 2 +- src/oci/audit/models/configuration.py | 2 +- .../models/update_configuration_details.py | 2 +- src/oci/base_client.py | 12 +- src/oci/core/blockstorage_client.py | 125 +- src/oci/core/compute_client.py | 239 +++- src/oci/core/models/__init__.py | 10 + .../core/models/attach_boot_volume_details.py | 2 +- .../models/attach_i_scsi_volume_details.py | 2 +- .../attach_paravirtualized_volume_details.py | 2 +- src/oci/core/models/attach_vnic_details.py | 2 +- src/oci/core/models/attach_volume_details.py | 2 +- src/oci/core/models/boot_volume.py | 2 +- src/oci/core/models/boot_volume_attachment.py | 2 +- ...virtual_circuit_public_prefixes_details.py | 2 +- ...virtual_circuit_public_prefixes_details.py | 2 +- .../models/capture_console_history_details.py | 2 +- .../connect_local_peering_gateways_details.py | 2 +- ...nect_remote_peering_connections_details.py | 101 ++ src/oci/core/models/console_history.py | 2 +- src/oci/core/models/cpe.py | 2 +- src/oci/core/models/create_cpe_details.py | 2 +- .../models/create_cross_connect_details.py | 2 +- .../create_cross_connect_group_details.py | 2 +- src/oci/core/models/create_dhcp_details.py | 2 +- .../models/create_drg_attachment_details.py | 2 +- src/oci/core/models/create_drg_details.py | 2 +- src/oci/core/models/create_image_details.py | 2 +- ...ate_instance_console_connection_details.py | 2 +- .../models/create_internet_gateway_details.py | 2 +- .../create_ip_sec_connection_details.py | 2 +- .../create_local_peering_gateway_details.py | 2 +- .../core/models/create_private_ip_details.py | 2 +- .../core/models/create_public_ip_details.py | 2 +- ...reate_remote_peering_connection_details.py | 130 ++ .../core/models/create_route_table_details.py | 2 +- .../models/create_security_list_details.py | 2 +- src/oci/core/models/create_subnet_details.py | 2 +- src/oci/core/models/create_vcn_details.py | 2 +- .../models/create_virtual_circuit_details.py | 2 +- ...e_virtual_circuit_public_prefix_details.py | 2 +- src/oci/core/models/create_vnic_details.py | 2 +- .../models/create_volume_backup_details.py | 2 +- ...volume_backup_policy_assignment_details.py | 2 +- src/oci/core/models/create_volume_details.py | 2 +- src/oci/core/models/cross_connect.py | 2 +- src/oci/core/models/cross_connect_group.py | 2 +- src/oci/core/models/cross_connect_location.py | 2 +- src/oci/core/models/cross_connect_mapping.py | 2 +- .../models/cross_connect_port_speed_shape.py | 2 +- src/oci/core/models/cross_connect_status.py | 2 +- ...e_virtual_circuit_public_prefix_details.py | 2 +- src/oci/core/models/dhcp_dns_option.py | 2 +- src/oci/core/models/dhcp_option.py | 2 +- src/oci/core/models/dhcp_options.py | 2 +- .../core/models/dhcp_search_domain_option.py | 2 +- src/oci/core/models/drg.py | 2 +- src/oci/core/models/drg_attachment.py | 2 +- src/oci/core/models/egress_security_rule.py | 2 +- src/oci/core/models/export_image_details.py | 2 +- ..._image_via_object_storage_tuple_details.py | 2 +- ...rt_image_via_object_storage_uri_details.py | 2 +- .../models/fast_connect_provider_service.py | 2 +- .../get_public_ip_by_ip_address_details.py | 2 +- .../get_public_ip_by_private_ip_id_details.py | 2 +- .../core/models/i_scsi_volume_attachment.py | 2 +- src/oci/core/models/icmp_options.py | 2 +- src/oci/core/models/image.py | 2 +- src/oci/core/models/image_source_details.py | 2 +- ...source_via_object_storage_tuple_details.py | 2 +- ...e_source_via_object_storage_uri_details.py | 2 +- src/oci/core/models/ingress_security_rule.py | 2 +- src/oci/core/models/instance.py | 2 +- .../models/instance_console_connection.py | 2 +- src/oci/core/models/instance_credentials.py | 2 +- .../core/models/instance_source_details.py | 2 +- ...instance_source_via_boot_volume_details.py | 2 +- .../instance_source_via_image_details.py | 2 +- src/oci/core/models/internet_gateway.py | 2 +- src/oci/core/models/ip_sec_connection.py | 2 +- .../models/ip_sec_connection_device_config.py | 2 +- .../models/ip_sec_connection_device_status.py | 2 +- .../core/models/launch_instance_details.py | 2 +- src/oci/core/models/launch_options.py | 2 +- src/oci/core/models/letter_of_authority.py | 2 +- src/oci/core/models/local_peering_gateway.py | 2 +- .../paravirtualized_volume_attachment.py | 2 +- .../models/peer_region_for_remote_peering.py | 70 ++ src/oci/core/models/port_range.py | 2 +- src/oci/core/models/private_ip.py | 2 +- src/oci/core/models/public_ip.py | 2 +- .../core/models/remote_peering_connection.py | 410 +++++++ src/oci/core/models/route_rule.py | 2 +- src/oci/core/models/route_table.py | 2 +- src/oci/core/models/security_list.py | 2 +- src/oci/core/models/shape.py | 2 +- src/oci/core/models/subnet.py | 2 +- src/oci/core/models/tcp_options.py | 2 +- src/oci/core/models/tunnel_config.py | 2 +- src/oci/core/models/tunnel_status.py | 2 +- src/oci/core/models/udp_options.py | 2 +- .../core/models/update_boot_volume_details.py | 2 +- .../models/update_console_history_details.py | 2 +- src/oci/core/models/update_cpe_details.py | 2 +- .../models/update_cross_connect_details.py | 2 +- .../update_cross_connect_group_details.py | 2 +- src/oci/core/models/update_dhcp_details.py | 2 +- .../models/update_drg_attachment_details.py | 2 +- src/oci/core/models/update_drg_details.py | 2 +- src/oci/core/models/update_image_details.py | 2 +- .../core/models/update_instance_details.py | 2 +- .../models/update_internet_gateway_details.py | 2 +- .../update_ip_sec_connection_details.py | 2 +- .../update_local_peering_gateway_details.py | 2 +- .../core/models/update_private_ip_details.py | 2 +- .../core/models/update_public_ip_details.py | 2 +- ...pdate_remote_peering_connection_details.py | 68 ++ .../core/models/update_route_table_details.py | 2 +- .../models/update_security_list_details.py | 2 +- src/oci/core/models/update_subnet_details.py | 2 +- src/oci/core/models/update_vcn_details.py | 2 +- .../models/update_virtual_circuit_details.py | 2 +- src/oci/core/models/update_vnic_details.py | 2 +- .../models/update_volume_backup_details.py | 2 +- src/oci/core/models/update_volume_details.py | 2 +- src/oci/core/models/vcn.py | 2 +- src/oci/core/models/virtual_circuit.py | 2 +- .../models/virtual_circuit_bandwidth_shape.py | 2 +- .../models/virtual_circuit_public_prefix.py | 2 +- src/oci/core/models/vnic.py | 2 +- src/oci/core/models/vnic_attachment.py | 2 +- src/oci/core/models/volume.py | 2 +- src/oci/core/models/volume_attachment.py | 2 +- src/oci/core/models/volume_backup.py | 2 +- src/oci/core/models/volume_backup_policy.py | 2 +- .../models/volume_backup_policy_assignment.py | 2 +- src/oci/core/models/volume_backup_schedule.py | 2 +- src/oci/core/models/volume_source_details.py | 2 +- ...olume_source_from_volume_backup_details.py | 2 +- .../volume_source_from_volume_details.py | 2 +- src/oci/core/virtual_network_client.py | 1050 +++++++++++++++-- src/oci/database/database_client.py | 233 +++- src/oci/database/models/backup.py | 2 +- src/oci/database/models/backup_summary.py | 2 +- .../database/models/create_backup_details.py | 2 +- .../create_data_guard_association_details.py | 2 +- ...sociation_to_existing_db_system_details.py | 2 +- .../models/create_database_details.py | 2 +- .../create_database_from_backup_details.py | 2 +- .../database/models/create_db_home_details.py | 2 +- .../create_db_home_with_db_system_id_base.py | 2 +- ...reate_db_home_with_db_system_id_details.py | 2 +- ...e_with_db_system_id_from_backup_details.py | 2 +- .../database/models/data_guard_association.py | 2 +- .../models/data_guard_association_summary.py | 2 +- src/oci/database/models/database.py | 2 +- src/oci/database/models/database_summary.py | 2 +- src/oci/database/models/db_backup_config.py | 2 +- src/oci/database/models/db_home.py | 2 +- src/oci/database/models/db_home_summary.py | 2 +- src/oci/database/models/db_node.py | 2 +- src/oci/database/models/db_node_summary.py | 2 +- src/oci/database/models/db_system.py | 2 +- .../models/db_system_shape_summary.py | 130 +- src/oci/database/models/db_system_summary.py | 2 +- src/oci/database/models/db_version_summary.py | 2 +- ...failover_data_guard_association_details.py | 2 +- .../models/launch_db_system_details.py | 2 +- src/oci/database/models/patch.py | 2 +- src/oci/database/models/patch_details.py | 2 +- .../database/models/patch_history_entry.py | 2 +- .../models/patch_history_entry_summary.py | 2 +- src/oci/database/models/patch_summary.py | 2 +- ...einstate_data_guard_association_details.py | 2 +- .../models/restore_database_details.py | 2 +- ...itchover_data_guard_association_details.py | 2 +- .../models/update_database_details.py | 2 +- .../database/models/update_db_home_details.py | 2 +- .../models/update_db_system_details.py | 2 +- src/oci/dns/dns_client.py | 97 +- src/oci/dns/models/create_zone_details.py | 2 +- src/oci/dns/models/external_master.py | 2 +- .../models/patch_domain_records_details.py | 2 +- src/oci/dns/models/patch_rr_set_details.py | 2 +- .../dns/models/patch_zone_records_details.py | 2 +- src/oci/dns/models/record.py | 2 +- src/oci/dns/models/record_collection.py | 2 +- src/oci/dns/models/record_details.py | 2 +- src/oci/dns/models/record_operation.py | 2 +- src/oci/dns/models/rr_set.py | 2 +- src/oci/dns/models/tsig.py | 2 +- .../models/update_domain_records_details.py | 2 +- src/oci/dns/models/update_rr_set_details.py | 2 +- src/oci/dns/models/update_zone_details.py | 2 +- .../dns/models/update_zone_records_details.py | 2 +- src/oci/dns/models/zone.py | 2 +- src/oci/dns/models/zone_summary.py | 2 +- src/oci/email/email_client.py | 49 +- src/oci/email/models/create_sender_details.py | 2 +- .../models/create_suppression_details.py | 2 +- src/oci/email/models/sender.py | 2 +- src/oci/email/models/sender_summary.py | 2 +- src/oci/email/models/suppression.py | 2 +- src/oci/email/models/suppression_summary.py | 2 +- src/oci/exceptions.py | 14 +- src/oci/file_storage/file_storage_client.py | 138 ++- .../models/create_export_details.py | 2 +- .../models/create_file_system_details.py | 2 +- .../models/create_mount_target_details.py | 2 +- .../models/create_snapshot_details.py | 2 +- src/oci/file_storage/models/export.py | 2 +- src/oci/file_storage/models/export_set.py | 2 +- .../file_storage/models/export_set_summary.py | 2 +- src/oci/file_storage/models/export_summary.py | 2 +- src/oci/file_storage/models/file_system.py | 2 +- .../models/file_system_summary.py | 2 +- src/oci/file_storage/models/mount_target.py | 2 +- .../models/mount_target_summary.py | 2 +- src/oci/file_storage/models/snapshot.py | 2 +- .../file_storage/models/snapshot_summary.py | 2 +- .../models/update_export_set_details.py | 2 +- .../models/update_file_system_details.py | 2 +- .../models/update_mount_target_details.py | 2 +- src/oci/identity/identity_client.py | 441 +++++-- .../models/add_user_to_group_details.py | 2 +- src/oci/identity/models/api_key.py | 2 +- .../identity/models/availability_domain.py | 2 +- src/oci/identity/models/compartment.py | 2 +- .../identity/models/create_api_key_details.py | 2 +- .../models/create_compartment_details.py | 2 +- .../create_customer_secret_key_details.py | 2 +- .../models/create_dynamic_group_details.py | 2 +- .../identity/models/create_group_details.py | 2 +- .../create_identity_provider_details.py | 2 +- .../create_idp_group_mapping_details.py | 2 +- .../identity/models/create_policy_details.py | 2 +- .../create_region_subscription_details.py | 4 +- .../create_saml2_identity_provider_details.py | 2 +- .../models/create_smtp_credential_details.py | 2 +- .../models/create_swift_password_details.py | 2 +- src/oci/identity/models/create_tag_details.py | 2 +- .../models/create_tag_namespace_details.py | 2 +- .../identity/models/create_user_details.py | 2 +- .../identity/models/customer_secret_key.py | 2 +- .../models/customer_secret_key_summary.py | 2 +- src/oci/identity/models/dynamic_group.py | 2 +- src/oci/identity/models/group.py | 2 +- src/oci/identity/models/identity_provider.py | 2 +- src/oci/identity/models/idp_group_mapping.py | 2 +- src/oci/identity/models/policy.py | 2 +- src/oci/identity/models/region.py | 6 +- .../identity/models/region_subscription.py | 6 +- .../models/saml2_identity_provider.py | 2 +- src/oci/identity/models/smtp_credential.py | 2 +- .../models/smtp_credential_summary.py | 2 +- src/oci/identity/models/swift_password.py | 2 +- src/oci/identity/models/tag.py | 2 +- src/oci/identity/models/tag_namespace.py | 2 +- .../identity/models/tag_namespace_summary.py | 2 +- src/oci/identity/models/tag_summary.py | 2 +- src/oci/identity/models/tenancy.py | 14 +- src/oci/identity/models/ui_password.py | 2 +- .../models/update_compartment_details.py | 2 +- .../update_customer_secret_key_details.py | 2 +- .../models/update_dynamic_group_details.py | 2 +- .../identity/models/update_group_details.py | 2 +- .../update_identity_provider_details.py | 2 +- .../update_idp_group_mapping_details.py | 2 +- .../identity/models/update_policy_details.py | 2 +- .../update_saml2_identity_provider_details.py | 2 +- .../models/update_smtp_credential_details.py | 2 +- .../identity/models/update_state_details.py | 2 +- .../models/update_swift_password_details.py | 2 +- src/oci/identity/models/update_tag_details.py | 2 +- .../models/update_tag_namespace_details.py | 2 +- .../identity/models/update_user_details.py | 2 +- src/oci/identity/models/user.py | 2 +- .../identity/models/user_group_membership.py | 2 +- src/oci/load_balancer/load_balancer_client.py | 247 +++- src/oci/load_balancer/models/backend.py | 2 +- .../load_balancer/models/backend_details.py | 2 +- .../load_balancer/models/backend_health.py | 2 +- src/oci/load_balancer/models/backend_set.py | 2 +- .../models/backend_set_details.py | 2 +- .../models/backend_set_health.py | 2 +- src/oci/load_balancer/models/certificate.py | 2 +- .../models/certificate_details.py | 2 +- .../models/connection_configuration.py | 2 +- .../models/create_backend_details.py | 2 +- .../models/create_backend_set_details.py | 2 +- .../models/create_certificate_details.py | 2 +- .../models/create_listener_details.py | 2 +- .../models/create_load_balancer_details.py | 2 +- .../models/create_path_route_set_details.py | 2 +- .../models/health_check_result.py | 2 +- .../load_balancer/models/health_checker.py | 2 +- .../models/health_checker_details.py | 2 +- src/oci/load_balancer/models/ip_address.py | 2 +- src/oci/load_balancer/models/listener.py | 2 +- .../load_balancer/models/listener_details.py | 2 +- src/oci/load_balancer/models/load_balancer.py | 2 +- .../models/load_balancer_health.py | 2 +- .../models/load_balancer_health_summary.py | 2 +- .../models/load_balancer_policy.py | 2 +- .../models/load_balancer_protocol.py | 2 +- .../models/load_balancer_shape.py | 2 +- .../load_balancer/models/path_match_type.py | 2 +- src/oci/load_balancer/models/path_route.py | 2 +- .../load_balancer/models/path_route_set.py | 2 +- .../models/path_route_set_details.py | 2 +- ...ssion_persistence_configuration_details.py | 2 +- .../load_balancer/models/ssl_configuration.py | 2 +- .../models/ssl_configuration_details.py | 2 +- .../models/update_backend_details.py | 2 +- .../models/update_backend_set_details.py | 2 +- .../models/update_health_checker_details.py | 2 +- .../models/update_listener_details.py | 2 +- .../models/update_load_balancer_details.py | 2 +- .../models/update_path_route_set_details.py | 2 +- src/oci/load_balancer/models/work_request.py | 2 +- .../models/work_request_error.py | 2 +- src/oci/object_storage/models/bucket.py | 2 +- .../object_storage/models/bucket_summary.py | 2 +- .../models/commit_multipart_upload_details.py | 2 +- .../commit_multipart_upload_part_details.py | 2 +- .../models/create_bucket_details.py | 2 +- .../models/create_multipart_upload_details.py | 2 +- ...create_preauthenticated_request_details.py | 2 +- src/oci/object_storage/models/list_objects.py | 2 +- .../object_storage/models/multipart_upload.py | 2 +- .../models/multipart_upload_part_summary.py | 2 +- .../models/namespace_metadata.py | 2 +- .../object_storage/models/object_summary.py | 2 +- .../models/preauthenticated_request.py | 2 +- .../preauthenticated_request_summary.py | 2 +- .../models/rename_object_details.py | 2 +- .../models/restore_objects_details.py | 2 +- .../models/update_bucket_details.py | 2 +- .../update_namespace_metadata_details.py | 2 +- .../object_storage/object_storage_client.py | 157 ++- src/oci/regions.py | 6 +- src/oci/retry/retry.py | 2 +- src/oci/version.py | 2 +- tests/util.py | 8 +- 353 files changed, 4182 insertions(+), 782 deletions(-) create mode 100644 docs/exceptions.rst create mode 100644 docs/sdk_behaviors/retries.rst create mode 100644 examples/remote_peering_connection_example.py create mode 100644 examples/retries.py create mode 100644 src/oci/core/models/connect_remote_peering_connections_details.py create mode 100644 src/oci/core/models/create_remote_peering_connection_details.py create mode 100644 src/oci/core/models/peer_region_for_remote_peering.py create mode 100644 src/oci/core/models/remote_peering_connection.py create mode 100644 src/oci/core/models/update_remote_peering_connection_details.py diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 6960836e52..3e9517f382 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,19 @@ All notable changes to this project will be documented in this file. The format is based on `Keep a Changelog `_. +==================== +1.3.17 - 2018-03-26 +==================== + +Added +------ +* Added support for remote VCN peering across regions + + * An example on how to perform these operations can be found on `GitHub `__. + +* Added support for calling Oracle Cloud Infrastructure services in the uk-london-1 (LHR) region + + ==================== 1.3.16 - 2018-03-08 ==================== diff --git a/docs/exceptions.rst b/docs/exceptions.rst new file mode 100644 index 0000000000..006262e2a2 --- /dev/null +++ b/docs/exceptions.rst @@ -0,0 +1,47 @@ +.. _exception-handling: + +Exception handling +~~~~~~~~~~~~~~~~~~~~~~ +When using the Python SDK, you should be prepared to handle the following exceptions: + +* Any response received by the SDK with a non-2xx HTTP status will be thrown as a :py:class:`~oci.exceptions.ServiceError` +* A ``ValueError`` will be thrown if you provide invalid parameters to a method call or when setting an attribute. For example: + + * When setting an attribute on a model and that attribute has a constrained set of values, such as :py:attr:`~oci.core.models.CreatePublicIpDetails.lifetime` on ``CreatePublicIpDetails`` + * When passing a blank string as the identifier for a ``get_`` operation, such as passing a nil ``instance_id`` to :py:meth:`~oci.core.compute_client.ComputeClient.get_instance` + +* :py:class:`~oci.exceptions.ClientError` and its subclasses. These exceptions are raised when there is an error with your configuration file or when using the :py:meth:`~oci.wait_until` function + + * :py:class:`~oci.exceptions.ConfigFileNotFound` + * :py:class:`~oci.exceptions.InvalidConfig` + * :py:class:`~oci.exceptions.InvalidPrivateKey` + * :py:class:`~oci.exceptions.MissingPrivateKeyPassphrase` + * :py:class:`~oci.exceptions.ProfileNotFound` + * :py:class:`~oci.exceptions.WaitUntilNotSupported` + * :py:class:`~oci.exceptions.MaximumWaitTimeExceeded` + +* If you use the :py:class:`~oci.object_storage.UploadManager` then you should also catch :py:class:`~oci.exceptions.MultipartUploadError` + +* The Python SDK uses the `Requests `_ library to make calls to OCI services but it does not mask or wrap any of the errors originating from this library, so you should also account for these in your code. The exception reference for Requests can be found `here `__ and `here `__ + +Handling HTTP 3xx responses +============================ +As a result of the SDK treating responses with a non-2xx HTTP status as a :py:class:`~oci.exceptions.ServiceError` the SDK will throw a :py:class:`~oci.exceptions.ServiceError` on 3xx responses. This can impact operations which support conditional GETs, such as :py:meth:`~oci.object_storage.object_storage_client.ObjectStorageClient.get_object` and :py:meth:`~oci.object_storage.object_storage_client.ObjectStorageClient.head_object` methods as these can return responses with a HTTP status code of 304 if passed an ``if_none_match`` which corresponds to the curent etag of the object or bucket. + +In order to account for this, you should catch :py:class:`~oci.exceptions.ServiceError` and check its ``status`` attribute for the HTTP status code. For example: + +.. code-block:: python + + import oci + + config = oci.config.from_file() + client = oci.object_storage.ObjectStorageClient(config) + + try: + get_object_response = client.get_object('my_namespace', 'my_bucket', 'my_object', if_none_match='some_etag_value') + except oci.exceptions.ServiceError as e: + if e.status == 304: + # Object exists but has not been modified (based on the etag value) + pass + else: + raise diff --git a/docs/index.rst b/docs/index.rst index bf614372f7..99358b9ab1 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -48,6 +48,7 @@ To get started, head over to the :ref:`installation instructions ` or s backward-compatibility quickstart logging + exceptions upload-manager raw-requests waiters diff --git a/docs/sdk-with-proxy.rst b/docs/sdk-with-proxy.rst index e469cb3490..7263720ad0 100644 --- a/docs/sdk-with-proxy.rst +++ b/docs/sdk-with-proxy.rst @@ -30,3 +30,9 @@ In order to modify the underlying Session object, you can do something similar t The key parts are that the underlying Session object can be accessed via ``base_client.session`` and we can then modify the `proxies `_ dictionary to add any required proxies. + +If your proxy uses HTTP Basic Auth, then when setting ``base_client.session.proxies`` you can use the *http://user:password@host/* syntax to provide the username and password. For example: + +.. code-block:: python + + compute.base_client.session.proxies = { 'https': 'http://myuser:mypassword@proxy.example.org:80' } \ No newline at end of file diff --git a/docs/sdk_behaviors/index.rst b/docs/sdk_behaviors/index.rst index e1bfe3dd88..7d0d8e54cd 100644 --- a/docs/sdk_behaviors/index.rst +++ b/docs/sdk_behaviors/index.rst @@ -7,6 +7,7 @@ This section describes SDK-specific behaviors: * :doc:`Handling naive datetimes ` * :doc:`Parallel operations ` * :doc:`Passing explicit null/None values ` +* :doc:`Retries ` .. toctree:: :hidden: @@ -14,4 +15,5 @@ This section describes SDK-specific behaviors: handle_naive_datetime /parallel-ops - /pass-explicit-null \ No newline at end of file + /pass-explicit-null + retries \ No newline at end of file diff --git a/docs/sdk_behaviors/retries.rst b/docs/sdk_behaviors/retries.rst new file mode 100644 index 0000000000..0bff24cbfb --- /dev/null +++ b/docs/sdk_behaviors/retries.rst @@ -0,0 +1,44 @@ +.. _sdk-retries: + +Retries +~~~~~~~~ +By default, operations exposed in the SDK do not retry, but retries can be set in the SDK on a per-operation basis. Each operation accepts a +``retry_strategy`` keyword argument which can be used to set the retry strategy for that operation. This retry stategy could be: + +* The default strategy vended by the SDK as :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` +* The :py:class:`~oci.retry.NoneRetryStrategy`. This will result in no retries being performed for the operation +* A custom strategy produced via the :py:class:`~oci.retry.RetryStrategyBuilder` + +A sample on using retries, including the default strategy and a custom strategy, can be found on `GitHub ` + +Default Retry Strategy +------------------------ +The default retry strategy vended by the SDK has the following attributes: + +* 5 total attempts +* Total allowed elapsed time for all requests of 300 seconds (5 minutes) +* Exponential backoff with jitter, using: + + * The base time to use in retry calculations will be 1 second + * An exponent of 2. When calculating the next retry time we will raise this to the power of the number of attempts + * A maximum wait time between calls of 30 seconds + +* Exponential backoff with equal jitter is used for throttles as this guarantees some sleep time between attempts. The sleep time in this circumstance is calculated as: + +.. code-block:: none + + exponential_backoff_sleep_base = min(base_time * (exponent ** attempt_number), max_wait_time) + sleep_time = (exponential_backoff_sleep_base / 2.0) + random(0, exponential_backoff_sleep_base / 2.0) + +* Exponential backoff with full jitter is used for other scenarios where we need to retry (e.g. timeouts, HTTP 5xx). The sleep time in this circumstance is calculated as: + +.. code-block:: none + + exponential_backoff_sleep_base = min(base_time * (exponent ** attempt_number), max_wait_time) + sleep_time = random(0, exponential_backoff_sleep_base) + +* Retries on the following exception types: + + * Timeouts and connection errors + * HTTP 429s (throttles) + * HTTP 5xx (server errors) diff --git a/examples/remote_peering_connection_example.py b/examples/remote_peering_connection_example.py new file mode 100644 index 0000000000..0ecbd17770 --- /dev/null +++ b/examples/remote_peering_connection_example.py @@ -0,0 +1,307 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + +# This script provides a basic example of how to use use the Python SDK to create a remote peering of two virtual cloud networks +# between two different regions within a single compartment. +# +# This script accepts the following arguments: +# +# * The OCID of the compartment where resources will be created +# * The local region (e.g. us-phoenix-1) +# * The remote region (e.g. us-ashburn-1) +# +# This script relies on the correct IAM policies already being in place for a given compartment ID. +# For more information, please refer to: https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Tasks/remoteVCNpeering.htm +# +# In order to demonstrate remote peering, this script will also create one DRG and one VCN in each region. These resources will +# be deleted at the end of the script. DRGs and VCNs are a finite resource and may require contacting customer support if limits +# have been exceeded for your tenancy. + +import oci +import sys + + +def create_vcn_drg_and_drg_attachment(virtual_network_client, compartment_id, cidr_block, vcn_dns_label): + vcn_name = 'py_sdk_example_vcn' + + result = virtual_network_client.create_vcn( + oci.core.models.CreateVcnDetails( + cidr_block=cidr_block, + display_name=vcn_name, + compartment_id=compartment_id, + dns_label=vcn_dns_label + ) + ) + vcn = oci.wait_until( + virtual_network_client, + virtual_network_client.get_vcn(result.data.id), + 'lifecycle_state', + 'AVAILABLE', + max_wait_seconds=300 + ).data + print('Created VCN') + print('===============') + print(vcn) + print('\n\n') + + result = virtual_network_client.create_drg( + oci.core.models.CreateDrgDetails( + compartment_id=compartment_id, + display_name='Python SDK Example DRG' + ) + ) + drg = oci.wait_until( + virtual_network_client, + virtual_network_client.get_drg(result.data.id), + 'lifecycle_state', + 'AVAILABLE' + ).data + print('Created DRG') + print('===============') + print(drg) + print('\n\n') + + result = virtual_network_client.create_drg_attachment( + oci.core.models.CreateDrgAttachmentDetails( + display_name='Python SDK Example DRG Attachment', + vcn_id=vcn.id, + drg_id=drg.id + ) + ) + drg_attachment = oci.wait_until( + virtual_network_client, + virtual_network_client.get_drg_attachment(result.data.id), + 'lifecycle_state', + 'ATTACHED' + ).data + print('Created DRG Attachment') + print('=========================') + print(drg_attachment) + print('\n\n') + + return {'vcn': vcn, 'drg': drg, 'drg_attachment': drg_attachment} + + +def delete_vcn_drg_and_drg_attachment(virtual_network_client, vcn_drg_and_drg_attachment): + vcn = vcn_drg_and_drg_attachment['vcn'] + drg = vcn_drg_and_drg_attachment['drg'] + drg_attachment = vcn_drg_and_drg_attachment['drg_attachment'] + + print('Deleting DRG Attachment') + virtual_network_client.delete_drg_attachment(drg_attachment.id) + oci.wait_until( + virtual_network_client, + virtual_network_client.get_drg_attachment(drg_attachment.id), + 'lifecycle_state', + 'DETACHED', + succeed_on_not_found=True + ) + + print('Deleting DRG') + virtual_network_client.delete_drg(drg.id) + oci.wait_until( + virtual_network_client, + virtual_network_client.get_drg(drg.id), + 'lifecycle_state', + 'TERMINATED', + succeed_on_not_found=True + ) + + print('Deleting VCN') + virtual_network_client.delete_vcn(vcn.id) + oci.wait_until( + virtual_network_client, + virtual_network_client.get_vcn(vcn.id), + 'lifecycle_state', + 'TERMINATED', + succeed_on_not_found=True + ) + + +config = oci.config.from_file() +virtual_network_client_local = oci.core.VirtualNetworkClient(config) +virtual_network_client_remote = oci.core.VirtualNetworkClient(config) + +if len(sys.argv) != 4: + raise RuntimeError('This script expects an argument of the compartment OCID and the local and remote regions for peering') + +compartment_id = sys.argv[1] +local_region = sys.argv[2] +remote_region = sys.argv[3] + +virtual_network_client_local.base_client.set_region(local_region) +virtual_network_client_remote.base_client.set_region(remote_region) + +local_vcn_and_drg = None +remote_vcn_and_drg = None + +remote_peering_connection_in_local_region = None +remote_peering_connection_in_remote_region = None +remote_peering_connection_established = False + +try: + local_vcn_and_drg = create_vcn_drg_and_drg_attachment( + virtual_network_client_local, + compartment_id, + '10.5.0.0/16', + 'pylocal' + ) + + remote_vcn_and_drg = create_vcn_drg_and_drg_attachment( + virtual_network_client_remote, + compartment_id, + '10.6.0.0/16', + 'pyremote' + ) + + # Create a remote peering connection in the local region + print('Creating remote peering connection in {}'.format(local_region)) + print('=====================================') + result = virtual_network_client_local.create_remote_peering_connection( + oci.core.models.CreateRemotePeeringConnectionDetails( + compartment_id=compartment_id, + drg_id=local_vcn_and_drg['drg'].id, + display_name='Remote peering connection in local' + ) + ) + remote_peering_connection_in_local_region = oci.wait_until( + virtual_network_client_local, + virtual_network_client_local.get_remote_peering_connection(result.data.id), + 'lifecycle_state', + 'AVAILABLE' + ).data + print(remote_peering_connection_in_local_region) + print('\n\n') + + # Create a remote peering connection in the remote region + print('Creating remote peering connection in {}'.format(remote_region)) + print('=====================================') + result = virtual_network_client_remote.create_remote_peering_connection( + oci.core.models.CreateRemotePeeringConnectionDetails( + compartment_id=compartment_id, + drg_id=remote_vcn_and_drg['drg'].id, + display_name='Remote peering connection in remote' + ) + ) + remote_peering_connection_in_remote_region = oci.wait_until( + virtual_network_client_remote, + virtual_network_client_remote.get_remote_peering_connection(result.data.id), + 'lifecycle_state', + 'AVAILABLE' + ).data + print(remote_peering_connection_in_remote_region) + print('\n\n') + + # Now that we have remote peering connections created in the local and remote regions, we can link the two + print("Establishing connection between local and remote regions") + print('=====================================') + # We use the service client in the LOCAL region + # The first parameter is the remote peering connection in the LOCAL region + # The ConnectRemotePeeringConnectionsDetails should contain the details of the remote peering connection in the REMOTE region + virtual_network_client_local.connect_remote_peering_connections( + remote_peering_connection_in_local_region.id, + oci.core.models.ConnectRemotePeeringConnectionsDetails( + peer_id=remote_peering_connection_in_remote_region.id, + peer_region_name=remote_region + ) + ) + remote_peering_connection_established = True + + # Now we wait until the local and remote peering connections say that both are peered. Note here that our waiter uses the + # peering_status attribute + oci.wait_until( + virtual_network_client_local, + virtual_network_client_local.get_remote_peering_connection(remote_peering_connection_in_local_region.id), + 'peering_status', + 'PEERED' + ) + oci.wait_until( + virtual_network_client_remote, + virtual_network_client_remote.get_remote_peering_connection(remote_peering_connection_in_remote_region.id), + 'peering_status', + 'PEERED' + ) + print('Remote peering connection established between {} and {}'.format(local_region, remote_region)) + print('\n\n') + +finally: + # Note that the order of deleting resources when we have remote peering connections is important. First we + # delete the remote peering connections on either end and wait for their lifecycle states to be terminated + # and their peering statuses to be revoked. Then we can delete our DRG and VCN in the local and remote region + + if remote_peering_connection_in_local_region is not None: + print('Deleting remote peering connection in {}'.format(local_region)) + print('=======================') + # After the delete, the call to get_remote_peering_connection() may 404, so we can't call it directly in an argument to + # wait_until() because that'll cause an exception. We have two options: + # + # 1) Do a GET before the delete so that we have a response to provide to wait_until + # 2) Catch the exception and proceed onwards if it is a 404 + # + # The code directly below demonstrates the first option. The second option is demonstrated later on line 268 + get_response = virtual_network_client_local.get_remote_peering_connection(remote_peering_connection_in_local_region.id) + virtual_network_client_local.delete_remote_peering_connection(remote_peering_connection_in_local_region.id) + oci.wait_until( + virtual_network_client_local, + get_response, + 'lifecycle_state', + 'TERMINATED', + succeed_on_not_found=True + ) + print('Deleted remote peering connection\n\n') + + if remote_peering_connection_established: + # No need for a succeed_on_not_found here because we haven't called delete_remote_peering_connection() in the + # remote region yet + result = oci.wait_until( + virtual_network_client_remote, + virtual_network_client_remote.get_remote_peering_connection(remote_peering_connection_in_remote_region.id), + 'peering_status', + 'REVOKED' + ) + print('Remote peering connection in remote ({}) region revoked'.format(remote_region)) + print('\n\n') + + # It is possible that the get_remote_peering_connection() call here can 404. That's OK as it means the connection + # is deleted and we can proceed + try: + oci.wait_until( + virtual_network_client_local, + virtual_network_client_local.get_remote_peering_connection(remote_peering_connection_in_local_region.id), + 'peering_status', + 'REVOKED', + succeed_on_not_found=True + ) + except oci.exceptions.ServiceError as e: + if e.status == 404: + pass + else: + raise + print('Remote peering connection in local ({}) region revoked'.format(local_region)) + print('\n\n') + + if remote_peering_connection_in_remote_region is not None: + print('Deleting remote peering connection in {}'.format(remote_region)) + print('=======================') + get_response = virtual_network_client_remote.get_remote_peering_connection(remote_peering_connection_in_remote_region.id) + virtual_network_client_remote.delete_remote_peering_connection(remote_peering_connection_in_remote_region.id) + oci.wait_until( + virtual_network_client_remote, + get_response, + 'lifecycle_state', + 'TERMINATED', + succeed_on_not_found=True + ) + print('Remote peering connection deleted') + print('\n\n') + + if local_vcn_and_drg is not None: + print('Deleting local VCN and DRG') + print('================================') + delete_vcn_drg_and_drg_attachment(virtual_network_client_local, local_vcn_and_drg) + print('\n\n') + + if remote_vcn_and_drg is not None: + print('Deleting remote VCN and DRG') + print('================================') + delete_vcn_drg_and_drg_attachment(virtual_network_client_remote, remote_vcn_and_drg) diff --git a/examples/retries.py b/examples/retries.py new file mode 100644 index 0000000000..c0594dc37e --- /dev/null +++ b/examples/retries.py @@ -0,0 +1,120 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + +# This script provides a basic example of how to use the retry functionality in the Python SDK when +# making calls to OCI services. In order to demonstrate this functionality, this script shows +# performing create, update and delete operations against VCNs. +# +# This script takes a single argument: +# +# * The OCID of the compartment where we'll create the VCN + +import oci +import sys + + +def do_vcn_interactions_with_retries(virtual_network_client, compartment_id, retry_strategy): + vcn_name = 'python_sdk_example_vcn' + cidr_block = '10.0.0.0/16' + result = virtual_network_client.create_vcn( + oci.core.models.CreateVcnDetails( + cidr_block=cidr_block, + display_name=vcn_name, + compartment_id=compartment_id + ), + retry_strategy=retry_strategy + ) + + vcn = oci.wait_until( + virtual_network_client, + virtual_network_client.get_vcn(result.data.id), + 'lifecycle_state', + 'AVAILABLE', + max_wait_seconds=300 + ).data + print('Created VCN') + print('================') + print(vcn) + print('\n\n') + + result = virtual_network_client.update_vcn( + vcn.id, + oci.core.models.UpdateVcnDetails(display_name='python_sdk_example_vcn_updated'), + retry_strategy=retry_strategy + ) + print('Updated VCN') + print('================') + print(result.data) + print('\n\n') + + virtual_network_client.delete_vcn(vcn.id, retry_strategy=retry_strategy) + oci.wait_until( + virtual_network_client, + virtual_network_client.get_vcn(vcn.id), + 'lifecycle_state', + 'TERMINATED', + max_wait_seconds=300, + succeed_on_not_found=True + ) + print('Deleted VCN') + print('\n\n') + + +if len(sys.argv) != 2: + raise RuntimeError('A compartment OCID must be provided to this script') + +compartment_id = sys.argv[1] + +# Default config file and profile +config = oci.config.from_file() +virtual_network_client = oci.core.VirtualNetworkClient(config) + +# Here we use the default retry strategy. The attributes of this retry strategy are +# documented on this page: +# https://oracle-cloud-infrastructure-python-sdk.readthedocs.io/en/latest/sdk_behaviors/retries.html +do_vcn_interactions_with_retries(virtual_network_client, compartment_id, oci.retry.DEFAULT_RETRY_STRATEGY) + +# We can also construct our own retry strategy by using the RetryStrategyBuilder +retry_strategy_via_constructor = oci.retry.RetryStrategyBuilder( + # Make up to 10 service calls + max_attempts_check=True, + max_attempts=10, + + # Don't exceed a total of 600 seconds for all service calls + total_elapsed_time_check=True, + total_elapsed_time_seconds=600, + + # Wait 45 seconds between attempts + retry_max_wait_between_calls_seconds=45, + + # Use 2 seconds as the base number for doing sleep time calculations + retry_base_sleep_time_seconds=2, + + # Retry on certain service errors: + # + # - 5xx code received for the request + # - Any 429 (this is signified by the empty array in the retry config) + # - 400s where the code is QuotaExceeded or LimitExceeded + service_error_check=True, + service_error_retry_on_any_5xx=True, + service_error_retry_config={ + 400: ['QuotaExceeded', 'LimitExceeded'], + 429: [] + }, + + # Use exponential backoff and retry with full jitter, but on throttles use + # exponential backoff and retry with equal jitter + backoff_type=oci.retry.BACKOFF_FULL_JITTER_EQUAL_ON_THROTTLE_VALUE +).get_retry_strategy() +do_vcn_interactions_with_retries(virtual_network_client, compartment_id, retry_strategy_via_constructor) + +# In addition to providing options in the constructor, we can create a RetryStrategyBuilder +# and use its add_* methods to enable different options. It also includes no_* methods to disable +# options +retry_strategy_builder = oci.retry.RetryStrategyBuilder() +retry_strategy_builder.add_max_attempts(max_attempts=10) \ + .add_total_elapsed_time(total_elapsed_time_seconds=600) \ + .add_service_error_check( + service_error_retry_on_any_5xx=True, + service_error_retry_config={429: []}) +do_vcn_interactions_with_retries(virtual_network_client, compartment_id, retry_strategy_builder.get_retry_strategy()) diff --git a/src/oci/audit/audit_client.py b/src/oci/audit/audit_client.py index d87131c12a..ced314fc95 100644 --- a/src/oci/audit/audit_client.py +++ b/src/oci/audit/audit_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("audit", config, signer, audit_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def get_configuration(self, compartment_id, **kwargs): """ @@ -63,8 +64,12 @@ def get_configuration(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -141,8 +146,12 @@ def list_events(self, compartment_id, start_time, end_time, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -191,8 +200,12 @@ def update_configuration(self, compartment_id, update_configuration_details, **k "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/audit/models/audit_event.py b/src/oci/audit/models/audit_event.py index d14f4a2c3f..de27dc918f 100644 --- a/src/oci/audit/models/audit_event.py +++ b/src/oci/audit/models/audit_event.py @@ -11,7 +11,7 @@ class AuditEvent(object): def __init__(self, **kwargs): """ - Initializes a new AuditEvent object with values from values from keyword arguments. + Initializes a new AuditEvent object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param tenant_id: diff --git a/src/oci/audit/models/configuration.py b/src/oci/audit/models/configuration.py index 21374107a3..1678504aae 100644 --- a/src/oci/audit/models/configuration.py +++ b/src/oci/audit/models/configuration.py @@ -11,7 +11,7 @@ class Configuration(object): def __init__(self, **kwargs): """ - Initializes a new Configuration object with values from values from keyword arguments. + Initializes a new Configuration object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param retention_period_days: diff --git a/src/oci/audit/models/update_configuration_details.py b/src/oci/audit/models/update_configuration_details.py index 158b050bb2..b98c1c4ec3 100644 --- a/src/oci/audit/models/update_configuration_details.py +++ b/src/oci/audit/models/update_configuration_details.py @@ -11,7 +11,7 @@ class UpdateConfigurationDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateConfigurationDetails object with values from values from keyword arguments. + Initializes a new UpdateConfigurationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param retention_period_days: diff --git a/src/oci/base_client.py b/src/oci/base_client.py index b2223c0007..654a6badbc 100644 --- a/src/oci/base_client.py +++ b/src/oci/base_client.py @@ -281,7 +281,7 @@ def request(self, request): self.logger.debug("Response status: %s" % str(response.status_code)) if not 200 <= response.status_code <= 299: - self.raise_service_error(response) + self.raise_service_error(request, response) if stream: # Don't unpack a streaming response body @@ -430,7 +430,7 @@ def extract_list_item_type_from_swagger_type(self, swagger_type): return result - def raise_service_error(self, response): + def raise_service_error(self, request, response): deserialized_data = self.deserialize_response_data(response.content, 'object') service_code = None message = None @@ -438,12 +438,18 @@ def raise_service_error(self, response): if isinstance(deserialized_data, dict): service_code = deserialized_data.get('code') message = deserialized_data.get('message') + else: + # Deserialized data should be a string if we couldn't deserialize into a dict (i.e. it failed + # json.loads()). There could still be error information of value to the customer, so instead + # of black holing the message, just put it in the error + message = deserialized_data raise exceptions.ServiceError( response.status_code, service_code, response.headers, - message) + message, + original_request=request) def deserialize_response_data(self, response_data, response_type): """ diff --git a/src/oci/core/blockstorage_client.py b/src/oci/core/blockstorage_client.py index abf0ebf41b..11b65167cc 100644 --- a/src/oci/core/blockstorage_client.py +++ b/src/oci/core/blockstorage_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("blockstorage", config, signer, core_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_volume(self, create_volume_details, **kwargs): """ @@ -88,10 +89,14 @@ def create_volume(self, create_volume_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -152,10 +157,14 @@ def create_volume_backup(self, create_volume_backup_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -198,8 +207,12 @@ def create_volume_backup_policy_assignment(self, create_volume_backup_policy_ass "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -266,8 +279,12 @@ def delete_boot_volume(self, boot_volume_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -332,8 +349,12 @@ def delete_volume(self, volume_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -393,8 +414,12 @@ def delete_volume_backup(self, volume_backup_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -454,8 +479,12 @@ def delete_volume_backup_policy_assignment(self, policy_assignment_id, **kwargs) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -504,8 +533,12 @@ def get_boot_volume(self, boot_volume_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -556,8 +589,12 @@ def get_volume(self, volume_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -608,8 +645,12 @@ def get_volume_backup(self, volume_backup_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -660,8 +701,12 @@ def get_volume_backup_policy(self, policy_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -724,8 +769,12 @@ def get_volume_backup_policy_asset_assignment(self, asset_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -776,8 +825,12 @@ def get_volume_backup_policy_assignment(self, policy_assignment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -844,8 +897,12 @@ def list_boot_volumes(self, availability_domain, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -902,8 +959,12 @@ def list_volume_backup_policies(self, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1024,8 +1085,12 @@ def list_volume_backups(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1148,8 +1213,12 @@ def list_volumes(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1214,8 +1283,12 @@ def update_boot_volume(self, boot_volume_id, update_boot_volume_details, **kwarg } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1283,8 +1356,12 @@ def update_volume(self, volume_id, update_volume_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1352,8 +1429,12 @@ def update_volume_backup(self, volume_backup_id, update_volume_backup_details, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/core/compute_client.py b/src/oci/core/compute_client.py index d902823f80..911ca7f62a 100644 --- a/src/oci/core/compute_client.py +++ b/src/oci/core/compute_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("compute", config, signer, core_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def attach_boot_volume(self, attach_boot_volume_details, **kwargs): """ @@ -71,10 +72,14 @@ def attach_boot_volume(self, attach_boot_volume_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -132,10 +137,14 @@ def attach_vnic(self, attach_vnic_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -189,10 +198,14 @@ def attach_volume(self, attach_volume_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -262,10 +275,14 @@ def capture_console_history(self, capture_console_history_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -346,10 +363,14 @@ def create_image(self, create_image_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -409,10 +430,14 @@ def create_instance_console_connection(self, create_instance_console_connection_ } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -474,8 +499,12 @@ def delete_console_history(self, instance_console_history_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -535,8 +564,12 @@ def delete_image(self, image_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -596,8 +629,12 @@ def delete_instance_console_connection(self, instance_console_connection_id, **k } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -660,8 +697,12 @@ def detach_boot_volume(self, boot_volume_attachment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -732,8 +773,12 @@ def detach_vnic(self, vnic_attachment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -796,8 +841,12 @@ def detach_volume(self, volume_attachment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -883,10 +932,14 @@ def export_image(self, image_id, export_image_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -939,8 +992,12 @@ def get_boot_volume_attachment(self, boot_volume_attachment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -993,8 +1050,12 @@ def get_console_history(self, instance_console_history_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1064,8 +1125,12 @@ def get_console_history_content(self, instance_console_history_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1118,8 +1183,12 @@ def get_image(self, image_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1170,8 +1239,12 @@ def get_instance(self, instance_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1222,8 +1295,12 @@ def get_instance_console_connection(self, instance_console_connection_id, **kwar "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1274,8 +1351,12 @@ def get_vnic_attachment(self, vnic_attachment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1326,8 +1407,12 @@ def get_volume_attachment(self, volume_attachment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1379,8 +1464,12 @@ def get_windows_instance_initial_credentials(self, instance_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1476,10 +1565,14 @@ def instance_action(self, instance_id, action, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1570,10 +1663,14 @@ def launch_instance(self, launch_instance_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1651,8 +1748,12 @@ def list_boot_volume_attachments(self, availability_domain, compartment_id, **kw "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1775,8 +1876,12 @@ def list_console_histories(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1917,8 +2022,12 @@ def list_images(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1988,8 +2097,12 @@ def list_instance_console_connections(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2114,8 +2227,12 @@ def list_instances(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2189,8 +2306,12 @@ def list_shapes(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2270,8 +2391,12 @@ def list_vnic_attachments(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2353,8 +2478,12 @@ def list_volume_attachments(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2433,8 +2562,12 @@ def terminate_instance(self, instance_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2499,8 +2632,12 @@ def update_console_history(self, instance_console_history_id, update_console_his } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2576,10 +2713,14 @@ def update_image(self, image_id, update_image_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2656,10 +2797,14 @@ def update_instance(self, instance_id, update_instance_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/core/models/__init__.py b/src/oci/core/models/__init__.py index a8d5f91096..41c94d9814 100644 --- a/src/oci/core/models/__init__.py +++ b/src/oci/core/models/__init__.py @@ -14,6 +14,7 @@ from .bulk_delete_virtual_circuit_public_prefixes_details import BulkDeleteVirtualCircuitPublicPrefixesDetails from .capture_console_history_details import CaptureConsoleHistoryDetails from .connect_local_peering_gateways_details import ConnectLocalPeeringGatewaysDetails +from .connect_remote_peering_connections_details import ConnectRemotePeeringConnectionsDetails from .console_history import ConsoleHistory from .cpe import Cpe from .create_cpe_details import CreateCpeDetails @@ -29,6 +30,7 @@ from .create_local_peering_gateway_details import CreateLocalPeeringGatewayDetails from .create_private_ip_details import CreatePrivateIpDetails from .create_public_ip_details import CreatePublicIpDetails +from .create_remote_peering_connection_details import CreateRemotePeeringConnectionDetails from .create_route_table_details import CreateRouteTableDetails from .create_security_list_details import CreateSecurityListDetails from .create_subnet_details import CreateSubnetDetails @@ -81,9 +83,11 @@ from .letter_of_authority import LetterOfAuthority from .local_peering_gateway import LocalPeeringGateway from .paravirtualized_volume_attachment import ParavirtualizedVolumeAttachment +from .peer_region_for_remote_peering import PeerRegionForRemotePeering from .port_range import PortRange from .private_ip import PrivateIp from .public_ip import PublicIp +from .remote_peering_connection import RemotePeeringConnection from .route_rule import RouteRule from .route_table import RouteTable from .security_list import SecurityList @@ -108,6 +112,7 @@ from .update_local_peering_gateway_details import UpdateLocalPeeringGatewayDetails from .update_private_ip_details import UpdatePrivateIpDetails from .update_public_ip_details import UpdatePublicIpDetails +from .update_remote_peering_connection_details import UpdateRemotePeeringConnectionDetails from .update_route_table_details import UpdateRouteTableDetails from .update_security_list_details import UpdateSecurityListDetails from .update_subnet_details import UpdateSubnetDetails @@ -145,6 +150,7 @@ "BulkDeleteVirtualCircuitPublicPrefixesDetails": BulkDeleteVirtualCircuitPublicPrefixesDetails, "CaptureConsoleHistoryDetails": CaptureConsoleHistoryDetails, "ConnectLocalPeeringGatewaysDetails": ConnectLocalPeeringGatewaysDetails, + "ConnectRemotePeeringConnectionsDetails": ConnectRemotePeeringConnectionsDetails, "ConsoleHistory": ConsoleHistory, "Cpe": Cpe, "CreateCpeDetails": CreateCpeDetails, @@ -160,6 +166,7 @@ "CreateLocalPeeringGatewayDetails": CreateLocalPeeringGatewayDetails, "CreatePrivateIpDetails": CreatePrivateIpDetails, "CreatePublicIpDetails": CreatePublicIpDetails, + "CreateRemotePeeringConnectionDetails": CreateRemotePeeringConnectionDetails, "CreateRouteTableDetails": CreateRouteTableDetails, "CreateSecurityListDetails": CreateSecurityListDetails, "CreateSubnetDetails": CreateSubnetDetails, @@ -212,9 +219,11 @@ "LetterOfAuthority": LetterOfAuthority, "LocalPeeringGateway": LocalPeeringGateway, "ParavirtualizedVolumeAttachment": ParavirtualizedVolumeAttachment, + "PeerRegionForRemotePeering": PeerRegionForRemotePeering, "PortRange": PortRange, "PrivateIp": PrivateIp, "PublicIp": PublicIp, + "RemotePeeringConnection": RemotePeeringConnection, "RouteRule": RouteRule, "RouteTable": RouteTable, "SecurityList": SecurityList, @@ -239,6 +248,7 @@ "UpdateLocalPeeringGatewayDetails": UpdateLocalPeeringGatewayDetails, "UpdatePrivateIpDetails": UpdatePrivateIpDetails, "UpdatePublicIpDetails": UpdatePublicIpDetails, + "UpdateRemotePeeringConnectionDetails": UpdateRemotePeeringConnectionDetails, "UpdateRouteTableDetails": UpdateRouteTableDetails, "UpdateSecurityListDetails": UpdateSecurityListDetails, "UpdateSubnetDetails": UpdateSubnetDetails, diff --git a/src/oci/core/models/attach_boot_volume_details.py b/src/oci/core/models/attach_boot_volume_details.py index c7c1866080..a646e00b99 100644 --- a/src/oci/core/models/attach_boot_volume_details.py +++ b/src/oci/core/models/attach_boot_volume_details.py @@ -11,7 +11,7 @@ class AttachBootVolumeDetails(object): def __init__(self, **kwargs): """ - Initializes a new AttachBootVolumeDetails object with values from values from keyword arguments. + Initializes a new AttachBootVolumeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param boot_volume_id: diff --git a/src/oci/core/models/attach_i_scsi_volume_details.py b/src/oci/core/models/attach_i_scsi_volume_details.py index 57fd3c294d..34f0736cb3 100644 --- a/src/oci/core/models/attach_i_scsi_volume_details.py +++ b/src/oci/core/models/attach_i_scsi_volume_details.py @@ -11,7 +11,7 @@ class AttachIScsiVolumeDetails(AttachVolumeDetails): def __init__(self, **kwargs): """ - Initializes a new AttachIScsiVolumeDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.AttachIScsiVolumeDetails.type` attribute + Initializes a new AttachIScsiVolumeDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.AttachIScsiVolumeDetails.type` attribute of this class is ``iscsi`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/attach_paravirtualized_volume_details.py b/src/oci/core/models/attach_paravirtualized_volume_details.py index aa853d1fd6..b7c0cf7fc1 100644 --- a/src/oci/core/models/attach_paravirtualized_volume_details.py +++ b/src/oci/core/models/attach_paravirtualized_volume_details.py @@ -11,7 +11,7 @@ class AttachParavirtualizedVolumeDetails(AttachVolumeDetails): def __init__(self, **kwargs): """ - Initializes a new AttachParavirtualizedVolumeDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.AttachParavirtualizedVolumeDetails.type` attribute + Initializes a new AttachParavirtualizedVolumeDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.AttachParavirtualizedVolumeDetails.type` attribute of this class is ``paravirtualized`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/attach_vnic_details.py b/src/oci/core/models/attach_vnic_details.py index 638a8a7e39..671812b009 100644 --- a/src/oci/core/models/attach_vnic_details.py +++ b/src/oci/core/models/attach_vnic_details.py @@ -11,7 +11,7 @@ class AttachVnicDetails(object): def __init__(self, **kwargs): """ - Initializes a new AttachVnicDetails object with values from values from keyword arguments. + Initializes a new AttachVnicDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param create_vnic_details: diff --git a/src/oci/core/models/attach_volume_details.py b/src/oci/core/models/attach_volume_details.py index e2e6585752..18061855a6 100644 --- a/src/oci/core/models/attach_volume_details.py +++ b/src/oci/core/models/attach_volume_details.py @@ -11,7 +11,7 @@ class AttachVolumeDetails(object): def __init__(self, **kwargs): """ - Initializes a new AttachVolumeDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new AttachVolumeDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.AttachIScsiVolumeDetails` diff --git a/src/oci/core/models/boot_volume.py b/src/oci/core/models/boot_volume.py index 27a91eae9f..cfea68ac75 100644 --- a/src/oci/core/models/boot_volume.py +++ b/src/oci/core/models/boot_volume.py @@ -11,7 +11,7 @@ class BootVolume(object): def __init__(self, **kwargs): """ - Initializes a new BootVolume object with values from values from keyword arguments. + Initializes a new BootVolume object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/boot_volume_attachment.py b/src/oci/core/models/boot_volume_attachment.py index 494ea5a80d..ce3ae2a746 100644 --- a/src/oci/core/models/boot_volume_attachment.py +++ b/src/oci/core/models/boot_volume_attachment.py @@ -11,7 +11,7 @@ class BootVolumeAttachment(object): def __init__(self, **kwargs): """ - Initializes a new BootVolumeAttachment object with values from values from keyword arguments. + Initializes a new BootVolumeAttachment object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/bulk_add_virtual_circuit_public_prefixes_details.py b/src/oci/core/models/bulk_add_virtual_circuit_public_prefixes_details.py index c7eaa785d8..0b0c23782c 100644 --- a/src/oci/core/models/bulk_add_virtual_circuit_public_prefixes_details.py +++ b/src/oci/core/models/bulk_add_virtual_circuit_public_prefixes_details.py @@ -11,7 +11,7 @@ class BulkAddVirtualCircuitPublicPrefixesDetails(object): def __init__(self, **kwargs): """ - Initializes a new BulkAddVirtualCircuitPublicPrefixesDetails object with values from values from keyword arguments. + Initializes a new BulkAddVirtualCircuitPublicPrefixesDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param public_prefixes: diff --git a/src/oci/core/models/bulk_delete_virtual_circuit_public_prefixes_details.py b/src/oci/core/models/bulk_delete_virtual_circuit_public_prefixes_details.py index 972433dd98..9d2979fc65 100644 --- a/src/oci/core/models/bulk_delete_virtual_circuit_public_prefixes_details.py +++ b/src/oci/core/models/bulk_delete_virtual_circuit_public_prefixes_details.py @@ -11,7 +11,7 @@ class BulkDeleteVirtualCircuitPublicPrefixesDetails(object): def __init__(self, **kwargs): """ - Initializes a new BulkDeleteVirtualCircuitPublicPrefixesDetails object with values from values from keyword arguments. + Initializes a new BulkDeleteVirtualCircuitPublicPrefixesDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param public_prefixes: diff --git a/src/oci/core/models/capture_console_history_details.py b/src/oci/core/models/capture_console_history_details.py index 279414b466..9cc417a669 100644 --- a/src/oci/core/models/capture_console_history_details.py +++ b/src/oci/core/models/capture_console_history_details.py @@ -11,7 +11,7 @@ class CaptureConsoleHistoryDetails(object): def __init__(self, **kwargs): """ - Initializes a new CaptureConsoleHistoryDetails object with values from values from keyword arguments. + Initializes a new CaptureConsoleHistoryDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/connect_local_peering_gateways_details.py b/src/oci/core/models/connect_local_peering_gateways_details.py index 9c5ea1e148..741d98dc32 100644 --- a/src/oci/core/models/connect_local_peering_gateways_details.py +++ b/src/oci/core/models/connect_local_peering_gateways_details.py @@ -11,7 +11,7 @@ class ConnectLocalPeeringGatewaysDetails(object): def __init__(self, **kwargs): """ - Initializes a new ConnectLocalPeeringGatewaysDetails object with values from values from keyword arguments. + Initializes a new ConnectLocalPeeringGatewaysDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param peer_id: diff --git a/src/oci/core/models/connect_remote_peering_connections_details.py b/src/oci/core/models/connect_remote_peering_connections_details.py new file mode 100644 index 0000000000..0f5ae3a324 --- /dev/null +++ b/src/oci/core/models/connect_remote_peering_connections_details.py @@ -0,0 +1,101 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + + +from ...util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from ...decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ConnectRemotePeeringConnectionsDetails(object): + + def __init__(self, **kwargs): + """ + Initializes a new ConnectRemotePeeringConnectionsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param peer_id: + The value to assign to the peer_id property of this ConnectRemotePeeringConnectionsDetails. + :type peer_id: str + + :param peer_region_name: + The value to assign to the peer_region_name property of this ConnectRemotePeeringConnectionsDetails. + :type peer_region_name: str + + """ + self.swagger_types = { + 'peer_id': 'str', + 'peer_region_name': 'str' + } + + self.attribute_map = { + 'peer_id': 'peerId', + 'peer_region_name': 'peerRegionName' + } + + self._peer_id = None + self._peer_region_name = None + + @property + def peer_id(self): + """ + **[Required]** Gets the peer_id of this ConnectRemotePeeringConnectionsDetails. + The OCID of the RPC you want to peer with. + + + :return: The peer_id of this ConnectRemotePeeringConnectionsDetails. + :rtype: str + """ + return self._peer_id + + @peer_id.setter + def peer_id(self, peer_id): + """ + Sets the peer_id of this ConnectRemotePeeringConnectionsDetails. + The OCID of the RPC you want to peer with. + + + :param peer_id: The peer_id of this ConnectRemotePeeringConnectionsDetails. + :type: str + """ + self._peer_id = peer_id + + @property + def peer_region_name(self): + """ + **[Required]** Gets the peer_region_name of this ConnectRemotePeeringConnectionsDetails. + The name of the region that contains the RPC you want to peer with. + + Example: `us-ashburn-1` + + + :return: The peer_region_name of this ConnectRemotePeeringConnectionsDetails. + :rtype: str + """ + return self._peer_region_name + + @peer_region_name.setter + def peer_region_name(self, peer_region_name): + """ + Sets the peer_region_name of this ConnectRemotePeeringConnectionsDetails. + The name of the region that contains the RPC you want to peer with. + + Example: `us-ashburn-1` + + + :param peer_region_name: The peer_region_name of this ConnectRemotePeeringConnectionsDetails. + :type: str + """ + self._peer_region_name = peer_region_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/core/models/console_history.py b/src/oci/core/models/console_history.py index aa4ad606e2..333143da6d 100644 --- a/src/oci/core/models/console_history.py +++ b/src/oci/core/models/console_history.py @@ -11,7 +11,7 @@ class ConsoleHistory(object): def __init__(self, **kwargs): """ - Initializes a new ConsoleHistory object with values from values from keyword arguments. + Initializes a new ConsoleHistory object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/cpe.py b/src/oci/core/models/cpe.py index ff00415ca5..6fec196a86 100644 --- a/src/oci/core/models/cpe.py +++ b/src/oci/core/models/cpe.py @@ -11,7 +11,7 @@ class Cpe(object): def __init__(self, **kwargs): """ - Initializes a new Cpe object with values from values from keyword arguments. + Initializes a new Cpe object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_cpe_details.py b/src/oci/core/models/create_cpe_details.py index 0ad34e5bfa..41709e8d87 100644 --- a/src/oci/core/models/create_cpe_details.py +++ b/src/oci/core/models/create_cpe_details.py @@ -11,7 +11,7 @@ class CreateCpeDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCpeDetails object with values from values from keyword arguments. + Initializes a new CreateCpeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_cross_connect_details.py b/src/oci/core/models/create_cross_connect_details.py index a75929224c..63f40f7791 100644 --- a/src/oci/core/models/create_cross_connect_details.py +++ b/src/oci/core/models/create_cross_connect_details.py @@ -11,7 +11,7 @@ class CreateCrossConnectDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCrossConnectDetails object with values from values from keyword arguments. + Initializes a new CreateCrossConnectDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_cross_connect_group_details.py b/src/oci/core/models/create_cross_connect_group_details.py index 3181e59b5f..e9cca2bc8b 100644 --- a/src/oci/core/models/create_cross_connect_group_details.py +++ b/src/oci/core/models/create_cross_connect_group_details.py @@ -11,7 +11,7 @@ class CreateCrossConnectGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCrossConnectGroupDetails object with values from values from keyword arguments. + Initializes a new CreateCrossConnectGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_dhcp_details.py b/src/oci/core/models/create_dhcp_details.py index 06c6718ace..d218a2b613 100644 --- a/src/oci/core/models/create_dhcp_details.py +++ b/src/oci/core/models/create_dhcp_details.py @@ -11,7 +11,7 @@ class CreateDhcpDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDhcpDetails object with values from values from keyword arguments. + Initializes a new CreateDhcpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_drg_attachment_details.py b/src/oci/core/models/create_drg_attachment_details.py index 66ab989bdb..7a10405e4d 100644 --- a/src/oci/core/models/create_drg_attachment_details.py +++ b/src/oci/core/models/create_drg_attachment_details.py @@ -11,7 +11,7 @@ class CreateDrgAttachmentDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDrgAttachmentDetails object with values from values from keyword arguments. + Initializes a new CreateDrgAttachmentDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/create_drg_details.py b/src/oci/core/models/create_drg_details.py index d2b8398765..659f1053a3 100644 --- a/src/oci/core/models/create_drg_details.py +++ b/src/oci/core/models/create_drg_details.py @@ -11,7 +11,7 @@ class CreateDrgDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDrgDetails object with values from values from keyword arguments. + Initializes a new CreateDrgDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_image_details.py b/src/oci/core/models/create_image_details.py index 8ea6b83d2e..e31c13cf73 100644 --- a/src/oci/core/models/create_image_details.py +++ b/src/oci/core/models/create_image_details.py @@ -11,7 +11,7 @@ class CreateImageDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateImageDetails object with values from values from keyword arguments. + Initializes a new CreateImageDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_instance_console_connection_details.py b/src/oci/core/models/create_instance_console_connection_details.py index bca71dbc71..8bead22151 100644 --- a/src/oci/core/models/create_instance_console_connection_details.py +++ b/src/oci/core/models/create_instance_console_connection_details.py @@ -11,7 +11,7 @@ class CreateInstanceConsoleConnectionDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateInstanceConsoleConnectionDetails object with values from values from keyword arguments. + Initializes a new CreateInstanceConsoleConnectionDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/create_internet_gateway_details.py b/src/oci/core/models/create_internet_gateway_details.py index 1dc458c2c2..0f08f3a190 100644 --- a/src/oci/core/models/create_internet_gateway_details.py +++ b/src/oci/core/models/create_internet_gateway_details.py @@ -11,7 +11,7 @@ class CreateInternetGatewayDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateInternetGatewayDetails object with values from values from keyword arguments. + Initializes a new CreateInternetGatewayDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_ip_sec_connection_details.py b/src/oci/core/models/create_ip_sec_connection_details.py index bae9c63df4..455999c4cb 100644 --- a/src/oci/core/models/create_ip_sec_connection_details.py +++ b/src/oci/core/models/create_ip_sec_connection_details.py @@ -11,7 +11,7 @@ class CreateIPSecConnectionDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateIPSecConnectionDetails object with values from values from keyword arguments. + Initializes a new CreateIPSecConnectionDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_local_peering_gateway_details.py b/src/oci/core/models/create_local_peering_gateway_details.py index ebbb7b14e5..d81779e1d1 100644 --- a/src/oci/core/models/create_local_peering_gateway_details.py +++ b/src/oci/core/models/create_local_peering_gateway_details.py @@ -11,7 +11,7 @@ class CreateLocalPeeringGatewayDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateLocalPeeringGatewayDetails object with values from values from keyword arguments. + Initializes a new CreateLocalPeeringGatewayDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_private_ip_details.py b/src/oci/core/models/create_private_ip_details.py index 0e2782e199..c0f09bf7cd 100644 --- a/src/oci/core/models/create_private_ip_details.py +++ b/src/oci/core/models/create_private_ip_details.py @@ -11,7 +11,7 @@ class CreatePrivateIpDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreatePrivateIpDetails object with values from values from keyword arguments. + Initializes a new CreatePrivateIpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/create_public_ip_details.py b/src/oci/core/models/create_public_ip_details.py index b0db6f2789..498e2be792 100644 --- a/src/oci/core/models/create_public_ip_details.py +++ b/src/oci/core/models/create_public_ip_details.py @@ -11,7 +11,7 @@ class CreatePublicIpDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreatePublicIpDetails object with values from values from keyword arguments. + Initializes a new CreatePublicIpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_remote_peering_connection_details.py b/src/oci/core/models/create_remote_peering_connection_details.py new file mode 100644 index 0000000000..574986d471 --- /dev/null +++ b/src/oci/core/models/create_remote_peering_connection_details.py @@ -0,0 +1,130 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + + +from ...util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from ...decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateRemotePeeringConnectionDetails(object): + + def __init__(self, **kwargs): + """ + Initializes a new CreateRemotePeeringConnectionDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param compartment_id: + The value to assign to the compartment_id property of this CreateRemotePeeringConnectionDetails. + :type compartment_id: str + + :param display_name: + The value to assign to the display_name property of this CreateRemotePeeringConnectionDetails. + :type display_name: str + + :param drg_id: + The value to assign to the drg_id property of this CreateRemotePeeringConnectionDetails. + :type drg_id: str + + """ + self.swagger_types = { + 'compartment_id': 'str', + 'display_name': 'str', + 'drg_id': 'str' + } + + self.attribute_map = { + 'compartment_id': 'compartmentId', + 'display_name': 'displayName', + 'drg_id': 'drgId' + } + + self._compartment_id = None + self._display_name = None + self._drg_id = None + + @property + def compartment_id(self): + """ + **[Required]** Gets the compartment_id of this CreateRemotePeeringConnectionDetails. + The OCID of the compartment to contain the RPC. + + + :return: The compartment_id of this CreateRemotePeeringConnectionDetails. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this CreateRemotePeeringConnectionDetails. + The OCID of the compartment to contain the RPC. + + + :param compartment_id: The compartment_id of this CreateRemotePeeringConnectionDetails. + :type: str + """ + self._compartment_id = compartment_id + + @property + def display_name(self): + """ + Gets the display_name of this CreateRemotePeeringConnectionDetails. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :return: The display_name of this CreateRemotePeeringConnectionDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this CreateRemotePeeringConnectionDetails. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :param display_name: The display_name of this CreateRemotePeeringConnectionDetails. + :type: str + """ + self._display_name = display_name + + @property + def drg_id(self): + """ + **[Required]** Gets the drg_id of this CreateRemotePeeringConnectionDetails. + The OCID of the DRG the RPC belongs to. + + + :return: The drg_id of this CreateRemotePeeringConnectionDetails. + :rtype: str + """ + return self._drg_id + + @drg_id.setter + def drg_id(self, drg_id): + """ + Sets the drg_id of this CreateRemotePeeringConnectionDetails. + The OCID of the DRG the RPC belongs to. + + + :param drg_id: The drg_id of this CreateRemotePeeringConnectionDetails. + :type: str + """ + self._drg_id = drg_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/core/models/create_route_table_details.py b/src/oci/core/models/create_route_table_details.py index 802269eeee..0d34fd9bfc 100644 --- a/src/oci/core/models/create_route_table_details.py +++ b/src/oci/core/models/create_route_table_details.py @@ -11,7 +11,7 @@ class CreateRouteTableDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateRouteTableDetails object with values from values from keyword arguments. + Initializes a new CreateRouteTableDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_security_list_details.py b/src/oci/core/models/create_security_list_details.py index 66c34bdbcd..afd58c43fd 100644 --- a/src/oci/core/models/create_security_list_details.py +++ b/src/oci/core/models/create_security_list_details.py @@ -11,7 +11,7 @@ class CreateSecurityListDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSecurityListDetails object with values from values from keyword arguments. + Initializes a new CreateSecurityListDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/create_subnet_details.py b/src/oci/core/models/create_subnet_details.py index 21c4d733ee..47fede1698 100644 --- a/src/oci/core/models/create_subnet_details.py +++ b/src/oci/core/models/create_subnet_details.py @@ -11,7 +11,7 @@ class CreateSubnetDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSubnetDetails object with values from values from keyword arguments. + Initializes a new CreateSubnetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/create_vcn_details.py b/src/oci/core/models/create_vcn_details.py index fec696dc57..524cb92f2b 100644 --- a/src/oci/core/models/create_vcn_details.py +++ b/src/oci/core/models/create_vcn_details.py @@ -11,7 +11,7 @@ class CreateVcnDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVcnDetails object with values from values from keyword arguments. + Initializes a new CreateVcnDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/create_virtual_circuit_details.py b/src/oci/core/models/create_virtual_circuit_details.py index cffe96fcda..999ef53b58 100644 --- a/src/oci/core/models/create_virtual_circuit_details.py +++ b/src/oci/core/models/create_virtual_circuit_details.py @@ -11,7 +11,7 @@ class CreateVirtualCircuitDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVirtualCircuitDetails object with values from values from keyword arguments. + Initializes a new CreateVirtualCircuitDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param bandwidth_shape_name: diff --git a/src/oci/core/models/create_virtual_circuit_public_prefix_details.py b/src/oci/core/models/create_virtual_circuit_public_prefix_details.py index b6fd37631c..75e49a5fa1 100644 --- a/src/oci/core/models/create_virtual_circuit_public_prefix_details.py +++ b/src/oci/core/models/create_virtual_circuit_public_prefix_details.py @@ -11,7 +11,7 @@ class CreateVirtualCircuitPublicPrefixDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVirtualCircuitPublicPrefixDetails object with values from values from keyword arguments. + Initializes a new CreateVirtualCircuitPublicPrefixDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/create_vnic_details.py b/src/oci/core/models/create_vnic_details.py index 4303774b46..f65b730ed5 100644 --- a/src/oci/core/models/create_vnic_details.py +++ b/src/oci/core/models/create_vnic_details.py @@ -11,7 +11,7 @@ class CreateVnicDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVnicDetails object with values from values from keyword arguments. + Initializes a new CreateVnicDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param assign_public_ip: diff --git a/src/oci/core/models/create_volume_backup_details.py b/src/oci/core/models/create_volume_backup_details.py index 7a33b4d79a..587f1ad846 100644 --- a/src/oci/core/models/create_volume_backup_details.py +++ b/src/oci/core/models/create_volume_backup_details.py @@ -11,7 +11,7 @@ class CreateVolumeBackupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVolumeBackupDetails object with values from values from keyword arguments. + Initializes a new CreateVolumeBackupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/create_volume_backup_policy_assignment_details.py b/src/oci/core/models/create_volume_backup_policy_assignment_details.py index 24560caa1a..886b4a4703 100644 --- a/src/oci/core/models/create_volume_backup_policy_assignment_details.py +++ b/src/oci/core/models/create_volume_backup_policy_assignment_details.py @@ -11,7 +11,7 @@ class CreateVolumeBackupPolicyAssignmentDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVolumeBackupPolicyAssignmentDetails object with values from values from keyword arguments. + Initializes a new CreateVolumeBackupPolicyAssignmentDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param asset_id: diff --git a/src/oci/core/models/create_volume_details.py b/src/oci/core/models/create_volume_details.py index 6025d4eb0f..39aff096f0 100644 --- a/src/oci/core/models/create_volume_details.py +++ b/src/oci/core/models/create_volume_details.py @@ -11,7 +11,7 @@ class CreateVolumeDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateVolumeDetails object with values from values from keyword arguments. + Initializes a new CreateVolumeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/cross_connect.py b/src/oci/core/models/cross_connect.py index 7d763f036b..67c67d2b90 100644 --- a/src/oci/core/models/cross_connect.py +++ b/src/oci/core/models/cross_connect.py @@ -11,7 +11,7 @@ class CrossConnect(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnect object with values from values from keyword arguments. + Initializes a new CrossConnect object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/cross_connect_group.py b/src/oci/core/models/cross_connect_group.py index b0f53323a2..9f6b071a1d 100644 --- a/src/oci/core/models/cross_connect_group.py +++ b/src/oci/core/models/cross_connect_group.py @@ -11,7 +11,7 @@ class CrossConnectGroup(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnectGroup object with values from values from keyword arguments. + Initializes a new CrossConnectGroup object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/cross_connect_location.py b/src/oci/core/models/cross_connect_location.py index d416414c9a..16e45cd43f 100644 --- a/src/oci/core/models/cross_connect_location.py +++ b/src/oci/core/models/cross_connect_location.py @@ -11,7 +11,7 @@ class CrossConnectLocation(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnectLocation object with values from values from keyword arguments. + Initializes a new CrossConnectLocation object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/core/models/cross_connect_mapping.py b/src/oci/core/models/cross_connect_mapping.py index 0b4eeebec1..79ef0db033 100644 --- a/src/oci/core/models/cross_connect_mapping.py +++ b/src/oci/core/models/cross_connect_mapping.py @@ -11,7 +11,7 @@ class CrossConnectMapping(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnectMapping object with values from values from keyword arguments. + Initializes a new CrossConnectMapping object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param bgp_md5_auth_key: diff --git a/src/oci/core/models/cross_connect_port_speed_shape.py b/src/oci/core/models/cross_connect_port_speed_shape.py index 1ed878494d..fce783e5b7 100644 --- a/src/oci/core/models/cross_connect_port_speed_shape.py +++ b/src/oci/core/models/cross_connect_port_speed_shape.py @@ -11,7 +11,7 @@ class CrossConnectPortSpeedShape(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnectPortSpeedShape object with values from values from keyword arguments. + Initializes a new CrossConnectPortSpeedShape object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/core/models/cross_connect_status.py b/src/oci/core/models/cross_connect_status.py index ae14d1cd5b..87212625f1 100644 --- a/src/oci/core/models/cross_connect_status.py +++ b/src/oci/core/models/cross_connect_status.py @@ -11,7 +11,7 @@ class CrossConnectStatus(object): def __init__(self, **kwargs): """ - Initializes a new CrossConnectStatus object with values from values from keyword arguments. + Initializes a new CrossConnectStatus object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cross_connect_id: diff --git a/src/oci/core/models/delete_virtual_circuit_public_prefix_details.py b/src/oci/core/models/delete_virtual_circuit_public_prefix_details.py index cdeee81c60..e9dcf998b5 100644 --- a/src/oci/core/models/delete_virtual_circuit_public_prefix_details.py +++ b/src/oci/core/models/delete_virtual_circuit_public_prefix_details.py @@ -11,7 +11,7 @@ class DeleteVirtualCircuitPublicPrefixDetails(object): def __init__(self, **kwargs): """ - Initializes a new DeleteVirtualCircuitPublicPrefixDetails object with values from values from keyword arguments. + Initializes a new DeleteVirtualCircuitPublicPrefixDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/dhcp_dns_option.py b/src/oci/core/models/dhcp_dns_option.py index 359d7057c8..515bd8cb67 100644 --- a/src/oci/core/models/dhcp_dns_option.py +++ b/src/oci/core/models/dhcp_dns_option.py @@ -11,7 +11,7 @@ class DhcpDnsOption(DhcpOption): def __init__(self, **kwargs): """ - Initializes a new DhcpDnsOption object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.DhcpDnsOption.type` attribute + Initializes a new DhcpDnsOption object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.DhcpDnsOption.type` attribute of this class is ``DomainNameServer`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/dhcp_option.py b/src/oci/core/models/dhcp_option.py index ea074736ac..bccb7033cd 100644 --- a/src/oci/core/models/dhcp_option.py +++ b/src/oci/core/models/dhcp_option.py @@ -11,7 +11,7 @@ class DhcpOption(object): def __init__(self, **kwargs): """ - Initializes a new DhcpOption object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new DhcpOption object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.DhcpDnsOption` diff --git a/src/oci/core/models/dhcp_options.py b/src/oci/core/models/dhcp_options.py index 603f277e3d..9443d4d568 100644 --- a/src/oci/core/models/dhcp_options.py +++ b/src/oci/core/models/dhcp_options.py @@ -11,7 +11,7 @@ class DhcpOptions(object): def __init__(self, **kwargs): """ - Initializes a new DhcpOptions object with values from values from keyword arguments. + Initializes a new DhcpOptions object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/dhcp_search_domain_option.py b/src/oci/core/models/dhcp_search_domain_option.py index 72439ae851..631ac47b6f 100644 --- a/src/oci/core/models/dhcp_search_domain_option.py +++ b/src/oci/core/models/dhcp_search_domain_option.py @@ -11,7 +11,7 @@ class DhcpSearchDomainOption(DhcpOption): def __init__(self, **kwargs): """ - Initializes a new DhcpSearchDomainOption object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.DhcpSearchDomainOption.type` attribute + Initializes a new DhcpSearchDomainOption object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.DhcpSearchDomainOption.type` attribute of this class is ``SearchDomain`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/drg.py b/src/oci/core/models/drg.py index d04ec0c5f6..25a89f804c 100644 --- a/src/oci/core/models/drg.py +++ b/src/oci/core/models/drg.py @@ -11,7 +11,7 @@ class Drg(object): def __init__(self, **kwargs): """ - Initializes a new Drg object with values from values from keyword arguments. + Initializes a new Drg object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/drg_attachment.py b/src/oci/core/models/drg_attachment.py index 54974b85e9..d704abf9f8 100644 --- a/src/oci/core/models/drg_attachment.py +++ b/src/oci/core/models/drg_attachment.py @@ -11,7 +11,7 @@ class DrgAttachment(object): def __init__(self, **kwargs): """ - Initializes a new DrgAttachment object with values from values from keyword arguments. + Initializes a new DrgAttachment object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/egress_security_rule.py b/src/oci/core/models/egress_security_rule.py index 5ddcb95cd0..0098fa49af 100644 --- a/src/oci/core/models/egress_security_rule.py +++ b/src/oci/core/models/egress_security_rule.py @@ -11,7 +11,7 @@ class EgressSecurityRule(object): def __init__(self, **kwargs): """ - Initializes a new EgressSecurityRule object with values from values from keyword arguments. + Initializes a new EgressSecurityRule object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param destination: diff --git a/src/oci/core/models/export_image_details.py b/src/oci/core/models/export_image_details.py index 8222f8904c..d59eacb913 100644 --- a/src/oci/core/models/export_image_details.py +++ b/src/oci/core/models/export_image_details.py @@ -11,7 +11,7 @@ class ExportImageDetails(object): def __init__(self, **kwargs): """ - Initializes a new ExportImageDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new ExportImageDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.ExportImageViaObjectStorageUriDetails` diff --git a/src/oci/core/models/export_image_via_object_storage_tuple_details.py b/src/oci/core/models/export_image_via_object_storage_tuple_details.py index e2215bfda6..19b9148f16 100644 --- a/src/oci/core/models/export_image_via_object_storage_tuple_details.py +++ b/src/oci/core/models/export_image_via_object_storage_tuple_details.py @@ -11,7 +11,7 @@ class ExportImageViaObjectStorageTupleDetails(ExportImageDetails): def __init__(self, **kwargs): """ - Initializes a new ExportImageViaObjectStorageTupleDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ExportImageViaObjectStorageTupleDetails.destination_type` attribute + Initializes a new ExportImageViaObjectStorageTupleDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ExportImageViaObjectStorageTupleDetails.destination_type` attribute of this class is ``objectStorageTuple`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/export_image_via_object_storage_uri_details.py b/src/oci/core/models/export_image_via_object_storage_uri_details.py index 8cdd675c11..8e45191d9c 100644 --- a/src/oci/core/models/export_image_via_object_storage_uri_details.py +++ b/src/oci/core/models/export_image_via_object_storage_uri_details.py @@ -11,7 +11,7 @@ class ExportImageViaObjectStorageUriDetails(ExportImageDetails): def __init__(self, **kwargs): """ - Initializes a new ExportImageViaObjectStorageUriDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ExportImageViaObjectStorageUriDetails.destination_type` attribute + Initializes a new ExportImageViaObjectStorageUriDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ExportImageViaObjectStorageUriDetails.destination_type` attribute of this class is ``objectStorageUri`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/fast_connect_provider_service.py b/src/oci/core/models/fast_connect_provider_service.py index bd47d7fae9..bfceca7672 100644 --- a/src/oci/core/models/fast_connect_provider_service.py +++ b/src/oci/core/models/fast_connect_provider_service.py @@ -11,7 +11,7 @@ class FastConnectProviderService(object): def __init__(self, **kwargs): """ - Initializes a new FastConnectProviderService object with values from values from keyword arguments. + Initializes a new FastConnectProviderService object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/core/models/get_public_ip_by_ip_address_details.py b/src/oci/core/models/get_public_ip_by_ip_address_details.py index 4ffc1e426d..ada17823c6 100644 --- a/src/oci/core/models/get_public_ip_by_ip_address_details.py +++ b/src/oci/core/models/get_public_ip_by_ip_address_details.py @@ -11,7 +11,7 @@ class GetPublicIpByIpAddressDetails(object): def __init__(self, **kwargs): """ - Initializes a new GetPublicIpByIpAddressDetails object with values from values from keyword arguments. + Initializes a new GetPublicIpByIpAddressDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ip_address: diff --git a/src/oci/core/models/get_public_ip_by_private_ip_id_details.py b/src/oci/core/models/get_public_ip_by_private_ip_id_details.py index 0c138fe8dd..3a2d269cea 100644 --- a/src/oci/core/models/get_public_ip_by_private_ip_id_details.py +++ b/src/oci/core/models/get_public_ip_by_private_ip_id_details.py @@ -11,7 +11,7 @@ class GetPublicIpByPrivateIpIdDetails(object): def __init__(self, **kwargs): """ - Initializes a new GetPublicIpByPrivateIpIdDetails object with values from values from keyword arguments. + Initializes a new GetPublicIpByPrivateIpIdDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param private_ip_id: diff --git a/src/oci/core/models/i_scsi_volume_attachment.py b/src/oci/core/models/i_scsi_volume_attachment.py index e7a426ef54..52c04c3d95 100644 --- a/src/oci/core/models/i_scsi_volume_attachment.py +++ b/src/oci/core/models/i_scsi_volume_attachment.py @@ -11,7 +11,7 @@ class IScsiVolumeAttachment(VolumeAttachment): def __init__(self, **kwargs): """ - Initializes a new IScsiVolumeAttachment object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.IScsiVolumeAttachment.attachment_type` attribute + Initializes a new IScsiVolumeAttachment object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.IScsiVolumeAttachment.attachment_type` attribute of this class is ``iscsi`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/icmp_options.py b/src/oci/core/models/icmp_options.py index 22f8aef94b..b5bd9f5f5c 100644 --- a/src/oci/core/models/icmp_options.py +++ b/src/oci/core/models/icmp_options.py @@ -11,7 +11,7 @@ class IcmpOptions(object): def __init__(self, **kwargs): """ - Initializes a new IcmpOptions object with values from values from keyword arguments. + Initializes a new IcmpOptions object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param code: diff --git a/src/oci/core/models/image.py b/src/oci/core/models/image.py index 8e62dc84f3..60b7c3c153 100644 --- a/src/oci/core/models/image.py +++ b/src/oci/core/models/image.py @@ -11,7 +11,7 @@ class Image(object): def __init__(self, **kwargs): """ - Initializes a new Image object with values from values from keyword arguments. + Initializes a new Image object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param base_image_id: diff --git a/src/oci/core/models/image_source_details.py b/src/oci/core/models/image_source_details.py index ddb0e34a25..505538dbce 100644 --- a/src/oci/core/models/image_source_details.py +++ b/src/oci/core/models/image_source_details.py @@ -11,7 +11,7 @@ class ImageSourceDetails(object): def __init__(self, **kwargs): """ - Initializes a new ImageSourceDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new ImageSourceDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.ImageSourceViaObjectStorageTupleDetails` diff --git a/src/oci/core/models/image_source_via_object_storage_tuple_details.py b/src/oci/core/models/image_source_via_object_storage_tuple_details.py index ad0b55366e..cebc1a0c96 100644 --- a/src/oci/core/models/image_source_via_object_storage_tuple_details.py +++ b/src/oci/core/models/image_source_via_object_storage_tuple_details.py @@ -11,7 +11,7 @@ class ImageSourceViaObjectStorageTupleDetails(ImageSourceDetails): def __init__(self, **kwargs): """ - Initializes a new ImageSourceViaObjectStorageTupleDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ImageSourceViaObjectStorageTupleDetails.source_type` attribute + Initializes a new ImageSourceViaObjectStorageTupleDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ImageSourceViaObjectStorageTupleDetails.source_type` attribute of this class is ``objectStorageTuple`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/image_source_via_object_storage_uri_details.py b/src/oci/core/models/image_source_via_object_storage_uri_details.py index 87f504df4d..23811fbd91 100644 --- a/src/oci/core/models/image_source_via_object_storage_uri_details.py +++ b/src/oci/core/models/image_source_via_object_storage_uri_details.py @@ -11,7 +11,7 @@ class ImageSourceViaObjectStorageUriDetails(ImageSourceDetails): def __init__(self, **kwargs): """ - Initializes a new ImageSourceViaObjectStorageUriDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ImageSourceViaObjectStorageUriDetails.source_type` attribute + Initializes a new ImageSourceViaObjectStorageUriDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ImageSourceViaObjectStorageUriDetails.source_type` attribute of this class is ``objectStorageUri`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/ingress_security_rule.py b/src/oci/core/models/ingress_security_rule.py index 1662cba2de..3cb5d3a305 100644 --- a/src/oci/core/models/ingress_security_rule.py +++ b/src/oci/core/models/ingress_security_rule.py @@ -11,7 +11,7 @@ class IngressSecurityRule(object): def __init__(self, **kwargs): """ - Initializes a new IngressSecurityRule object with values from values from keyword arguments. + Initializes a new IngressSecurityRule object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param icmp_options: diff --git a/src/oci/core/models/instance.py b/src/oci/core/models/instance.py index 4e095697b2..553f334799 100644 --- a/src/oci/core/models/instance.py +++ b/src/oci/core/models/instance.py @@ -11,7 +11,7 @@ class Instance(object): def __init__(self, **kwargs): """ - Initializes a new Instance object with values from values from keyword arguments. + Initializes a new Instance object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/instance_console_connection.py b/src/oci/core/models/instance_console_connection.py index 081a57b2ba..b064be36ba 100644 --- a/src/oci/core/models/instance_console_connection.py +++ b/src/oci/core/models/instance_console_connection.py @@ -11,7 +11,7 @@ class InstanceConsoleConnection(object): def __init__(self, **kwargs): """ - Initializes a new InstanceConsoleConnection object with values from values from keyword arguments. + Initializes a new InstanceConsoleConnection object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/instance_credentials.py b/src/oci/core/models/instance_credentials.py index 2be90057ec..4a9239635c 100644 --- a/src/oci/core/models/instance_credentials.py +++ b/src/oci/core/models/instance_credentials.py @@ -11,7 +11,7 @@ class InstanceCredentials(object): def __init__(self, **kwargs): """ - Initializes a new InstanceCredentials object with values from values from keyword arguments. + Initializes a new InstanceCredentials object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param password: diff --git a/src/oci/core/models/instance_source_details.py b/src/oci/core/models/instance_source_details.py index e19048ba99..cb5c31038f 100644 --- a/src/oci/core/models/instance_source_details.py +++ b/src/oci/core/models/instance_source_details.py @@ -11,7 +11,7 @@ class InstanceSourceDetails(object): def __init__(self, **kwargs): """ - Initializes a new InstanceSourceDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new InstanceSourceDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.InstanceSourceViaImageDetails` diff --git a/src/oci/core/models/instance_source_via_boot_volume_details.py b/src/oci/core/models/instance_source_via_boot_volume_details.py index f208d0b557..2ae01cb2d6 100644 --- a/src/oci/core/models/instance_source_via_boot_volume_details.py +++ b/src/oci/core/models/instance_source_via_boot_volume_details.py @@ -11,7 +11,7 @@ class InstanceSourceViaBootVolumeDetails(InstanceSourceDetails): def __init__(self, **kwargs): """ - Initializes a new InstanceSourceViaBootVolumeDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.InstanceSourceViaBootVolumeDetails.source_type` attribute + Initializes a new InstanceSourceViaBootVolumeDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.InstanceSourceViaBootVolumeDetails.source_type` attribute of this class is ``bootVolume`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/instance_source_via_image_details.py b/src/oci/core/models/instance_source_via_image_details.py index 127955e077..e417c2502a 100644 --- a/src/oci/core/models/instance_source_via_image_details.py +++ b/src/oci/core/models/instance_source_via_image_details.py @@ -11,7 +11,7 @@ class InstanceSourceViaImageDetails(InstanceSourceDetails): def __init__(self, **kwargs): """ - Initializes a new InstanceSourceViaImageDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.InstanceSourceViaImageDetails.source_type` attribute + Initializes a new InstanceSourceViaImageDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.InstanceSourceViaImageDetails.source_type` attribute of this class is ``image`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/internet_gateway.py b/src/oci/core/models/internet_gateway.py index ee38cee46e..e9180e4362 100644 --- a/src/oci/core/models/internet_gateway.py +++ b/src/oci/core/models/internet_gateway.py @@ -11,7 +11,7 @@ class InternetGateway(object): def __init__(self, **kwargs): """ - Initializes a new InternetGateway object with values from values from keyword arguments. + Initializes a new InternetGateway object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/ip_sec_connection.py b/src/oci/core/models/ip_sec_connection.py index d45d0f5ee0..f15ee200af 100644 --- a/src/oci/core/models/ip_sec_connection.py +++ b/src/oci/core/models/ip_sec_connection.py @@ -11,7 +11,7 @@ class IPSecConnection(object): def __init__(self, **kwargs): """ - Initializes a new IPSecConnection object with values from values from keyword arguments. + Initializes a new IPSecConnection object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/ip_sec_connection_device_config.py b/src/oci/core/models/ip_sec_connection_device_config.py index 5f0b76e859..8fab2930b4 100644 --- a/src/oci/core/models/ip_sec_connection_device_config.py +++ b/src/oci/core/models/ip_sec_connection_device_config.py @@ -11,7 +11,7 @@ class IPSecConnectionDeviceConfig(object): def __init__(self, **kwargs): """ - Initializes a new IPSecConnectionDeviceConfig object with values from values from keyword arguments. + Initializes a new IPSecConnectionDeviceConfig object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/ip_sec_connection_device_status.py b/src/oci/core/models/ip_sec_connection_device_status.py index 812d181430..c9be1a1555 100644 --- a/src/oci/core/models/ip_sec_connection_device_status.py +++ b/src/oci/core/models/ip_sec_connection_device_status.py @@ -11,7 +11,7 @@ class IPSecConnectionDeviceStatus(object): def __init__(self, **kwargs): """ - Initializes a new IPSecConnectionDeviceStatus object with values from values from keyword arguments. + Initializes a new IPSecConnectionDeviceStatus object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/launch_instance_details.py b/src/oci/core/models/launch_instance_details.py index c5788acbac..1311261e18 100644 --- a/src/oci/core/models/launch_instance_details.py +++ b/src/oci/core/models/launch_instance_details.py @@ -11,7 +11,7 @@ class LaunchInstanceDetails(object): def __init__(self, **kwargs): """ - Initializes a new LaunchInstanceDetails object with values from values from keyword arguments. + Initializes a new LaunchInstanceDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/launch_options.py b/src/oci/core/models/launch_options.py index 3d14fdb486..d98eeca08d 100644 --- a/src/oci/core/models/launch_options.py +++ b/src/oci/core/models/launch_options.py @@ -11,7 +11,7 @@ class LaunchOptions(object): def __init__(self, **kwargs): """ - Initializes a new LaunchOptions object with values from values from keyword arguments. + Initializes a new LaunchOptions object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param boot_volume_type: diff --git a/src/oci/core/models/letter_of_authority.py b/src/oci/core/models/letter_of_authority.py index feb4acde53..405384423c 100644 --- a/src/oci/core/models/letter_of_authority.py +++ b/src/oci/core/models/letter_of_authority.py @@ -11,7 +11,7 @@ class LetterOfAuthority(object): def __init__(self, **kwargs): """ - Initializes a new LetterOfAuthority object with values from values from keyword arguments. + Initializes a new LetterOfAuthority object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param authorized_entity_name: diff --git a/src/oci/core/models/local_peering_gateway.py b/src/oci/core/models/local_peering_gateway.py index 80247503e0..9cc6841d4d 100644 --- a/src/oci/core/models/local_peering_gateway.py +++ b/src/oci/core/models/local_peering_gateway.py @@ -11,7 +11,7 @@ class LocalPeeringGateway(object): def __init__(self, **kwargs): """ - Initializes a new LocalPeeringGateway object with values from values from keyword arguments. + Initializes a new LocalPeeringGateway object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/paravirtualized_volume_attachment.py b/src/oci/core/models/paravirtualized_volume_attachment.py index 9db8a9f3f4..9d58f48e84 100644 --- a/src/oci/core/models/paravirtualized_volume_attachment.py +++ b/src/oci/core/models/paravirtualized_volume_attachment.py @@ -11,7 +11,7 @@ class ParavirtualizedVolumeAttachment(VolumeAttachment): def __init__(self, **kwargs): """ - Initializes a new ParavirtualizedVolumeAttachment object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ParavirtualizedVolumeAttachment.attachment_type` attribute + Initializes a new ParavirtualizedVolumeAttachment object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.ParavirtualizedVolumeAttachment.attachment_type` attribute of this class is ``paravirtualized`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/peer_region_for_remote_peering.py b/src/oci/core/models/peer_region_for_remote_peering.py new file mode 100644 index 0000000000..389bf5ee90 --- /dev/null +++ b/src/oci/core/models/peer_region_for_remote_peering.py @@ -0,0 +1,70 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + + +from ...util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from ...decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PeerRegionForRemotePeering(object): + + def __init__(self, **kwargs): + """ + Initializes a new PeerRegionForRemotePeering object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param name: + The value to assign to the name property of this PeerRegionForRemotePeering. + :type name: str + + """ + self.swagger_types = { + 'name': 'str' + } + + self.attribute_map = { + 'name': 'name' + } + + self._name = None + + @property + def name(self): + """ + **[Required]** Gets the name of this PeerRegionForRemotePeering. + The region's name. + + Example: `us-phoenix-1` + + + :return: The name of this PeerRegionForRemotePeering. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """ + Sets the name of this PeerRegionForRemotePeering. + The region's name. + + Example: `us-phoenix-1` + + + :param name: The name of this PeerRegionForRemotePeering. + :type: str + """ + self._name = name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/core/models/port_range.py b/src/oci/core/models/port_range.py index 89bda9028a..e3c054e87c 100644 --- a/src/oci/core/models/port_range.py +++ b/src/oci/core/models/port_range.py @@ -11,7 +11,7 @@ class PortRange(object): def __init__(self, **kwargs): """ - Initializes a new PortRange object with values from values from keyword arguments. + Initializes a new PortRange object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param max: diff --git a/src/oci/core/models/private_ip.py b/src/oci/core/models/private_ip.py index 729ceaa00b..41d18041ae 100644 --- a/src/oci/core/models/private_ip.py +++ b/src/oci/core/models/private_ip.py @@ -11,7 +11,7 @@ class PrivateIp(object): def __init__(self, **kwargs): """ - Initializes a new PrivateIp object with values from values from keyword arguments. + Initializes a new PrivateIp object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/public_ip.py b/src/oci/core/models/public_ip.py index 173117bdee..3ed6299426 100644 --- a/src/oci/core/models/public_ip.py +++ b/src/oci/core/models/public_ip.py @@ -11,7 +11,7 @@ class PublicIp(object): def __init__(self, **kwargs): """ - Initializes a new PublicIp object with values from values from keyword arguments. + Initializes a new PublicIp object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/remote_peering_connection.py b/src/oci/core/models/remote_peering_connection.py new file mode 100644 index 0000000000..1ec9fb6eb9 --- /dev/null +++ b/src/oci/core/models/remote_peering_connection.py @@ -0,0 +1,410 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + + +from ...util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from ...decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RemotePeeringConnection(object): + + def __init__(self, **kwargs): + """ + Initializes a new RemotePeeringConnection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param compartment_id: + The value to assign to the compartment_id property of this RemotePeeringConnection. + :type compartment_id: str + + :param display_name: + The value to assign to the display_name property of this RemotePeeringConnection. + :type display_name: str + + :param drg_id: + The value to assign to the drg_id property of this RemotePeeringConnection. + :type drg_id: str + + :param id: + The value to assign to the id property of this RemotePeeringConnection. + :type id: str + + :param is_cross_tenancy_peering: + The value to assign to the is_cross_tenancy_peering property of this RemotePeeringConnection. + :type is_cross_tenancy_peering: bool + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this RemotePeeringConnection. + Allowed values for this property are: "AVAILABLE", "PROVISIONING", "TERMINATING", "TERMINATED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_state: str + + :param peer_id: + The value to assign to the peer_id property of this RemotePeeringConnection. + :type peer_id: str + + :param peer_region_name: + The value to assign to the peer_region_name property of this RemotePeeringConnection. + :type peer_region_name: str + + :param peer_tenancy_id: + The value to assign to the peer_tenancy_id property of this RemotePeeringConnection. + :type peer_tenancy_id: str + + :param peering_status: + The value to assign to the peering_status property of this RemotePeeringConnection. + Allowed values for this property are: "INVALID", "NEW", "PENDING", "PEERED", "REVOKED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type peering_status: str + + :param time_created: + The value to assign to the time_created property of this RemotePeeringConnection. + :type time_created: datetime + + """ + self.swagger_types = { + 'compartment_id': 'str', + 'display_name': 'str', + 'drg_id': 'str', + 'id': 'str', + 'is_cross_tenancy_peering': 'bool', + 'lifecycle_state': 'str', + 'peer_id': 'str', + 'peer_region_name': 'str', + 'peer_tenancy_id': 'str', + 'peering_status': 'str', + 'time_created': 'datetime' + } + + self.attribute_map = { + 'compartment_id': 'compartmentId', + 'display_name': 'displayName', + 'drg_id': 'drgId', + 'id': 'id', + 'is_cross_tenancy_peering': 'isCrossTenancyPeering', + 'lifecycle_state': 'lifecycleState', + 'peer_id': 'peerId', + 'peer_region_name': 'peerRegionName', + 'peer_tenancy_id': 'peerTenancyId', + 'peering_status': 'peeringStatus', + 'time_created': 'timeCreated' + } + + self._compartment_id = None + self._display_name = None + self._drg_id = None + self._id = None + self._is_cross_tenancy_peering = None + self._lifecycle_state = None + self._peer_id = None + self._peer_region_name = None + self._peer_tenancy_id = None + self._peering_status = None + self._time_created = None + + @property + def compartment_id(self): + """ + **[Required]** Gets the compartment_id of this RemotePeeringConnection. + The OCID of the compartment that contains the RPC. + + + :return: The compartment_id of this RemotePeeringConnection. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this RemotePeeringConnection. + The OCID of the compartment that contains the RPC. + + + :param compartment_id: The compartment_id of this RemotePeeringConnection. + :type: str + """ + self._compartment_id = compartment_id + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this RemotePeeringConnection. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :return: The display_name of this RemotePeeringConnection. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this RemotePeeringConnection. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :param display_name: The display_name of this RemotePeeringConnection. + :type: str + """ + self._display_name = display_name + + @property + def drg_id(self): + """ + **[Required]** Gets the drg_id of this RemotePeeringConnection. + The OCID of the DRG that this RPC belongs to. + + + :return: The drg_id of this RemotePeeringConnection. + :rtype: str + """ + return self._drg_id + + @drg_id.setter + def drg_id(self, drg_id): + """ + Sets the drg_id of this RemotePeeringConnection. + The OCID of the DRG that this RPC belongs to. + + + :param drg_id: The drg_id of this RemotePeeringConnection. + :type: str + """ + self._drg_id = drg_id + + @property + def id(self): + """ + **[Required]** Gets the id of this RemotePeeringConnection. + The OCID of the RPC. + + + :return: The id of this RemotePeeringConnection. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this RemotePeeringConnection. + The OCID of the RPC. + + + :param id: The id of this RemotePeeringConnection. + :type: str + """ + self._id = id + + @property + def is_cross_tenancy_peering(self): + """ + **[Required]** Gets the is_cross_tenancy_peering of this RemotePeeringConnection. + Whether the VCN at the other end of the peering is in a different tenancy. + + Example: `false` + + + :return: The is_cross_tenancy_peering of this RemotePeeringConnection. + :rtype: bool + """ + return self._is_cross_tenancy_peering + + @is_cross_tenancy_peering.setter + def is_cross_tenancy_peering(self, is_cross_tenancy_peering): + """ + Sets the is_cross_tenancy_peering of this RemotePeeringConnection. + Whether the VCN at the other end of the peering is in a different tenancy. + + Example: `false` + + + :param is_cross_tenancy_peering: The is_cross_tenancy_peering of this RemotePeeringConnection. + :type: bool + """ + self._is_cross_tenancy_peering = is_cross_tenancy_peering + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this RemotePeeringConnection. + The RPC's current lifecycle state. + + Allowed values for this property are: "AVAILABLE", "PROVISIONING", "TERMINATING", "TERMINATED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_state of this RemotePeeringConnection. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this RemotePeeringConnection. + The RPC's current lifecycle state. + + + :param lifecycle_state: The lifecycle_state of this RemotePeeringConnection. + :type: str + """ + allowed_values = ["AVAILABLE", "PROVISIONING", "TERMINATING", "TERMINATED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + lifecycle_state = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_state = lifecycle_state + + @property + def peer_id(self): + """ + Gets the peer_id of this RemotePeeringConnection. + If this RPC is peered, this value is the OCID of the other RPC. + + + :return: The peer_id of this RemotePeeringConnection. + :rtype: str + """ + return self._peer_id + + @peer_id.setter + def peer_id(self, peer_id): + """ + Sets the peer_id of this RemotePeeringConnection. + If this RPC is peered, this value is the OCID of the other RPC. + + + :param peer_id: The peer_id of this RemotePeeringConnection. + :type: str + """ + self._peer_id = peer_id + + @property + def peer_region_name(self): + """ + Gets the peer_region_name of this RemotePeeringConnection. + If this RPC is peered, this value is the region that contains the other RPC. + + Example: `us-ashburn-1` + + + :return: The peer_region_name of this RemotePeeringConnection. + :rtype: str + """ + return self._peer_region_name + + @peer_region_name.setter + def peer_region_name(self, peer_region_name): + """ + Sets the peer_region_name of this RemotePeeringConnection. + If this RPC is peered, this value is the region that contains the other RPC. + + Example: `us-ashburn-1` + + + :param peer_region_name: The peer_region_name of this RemotePeeringConnection. + :type: str + """ + self._peer_region_name = peer_region_name + + @property + def peer_tenancy_id(self): + """ + Gets the peer_tenancy_id of this RemotePeeringConnection. + If this RPC is peered, this value is the OCID of the other RPC's tenancy. + + + :return: The peer_tenancy_id of this RemotePeeringConnection. + :rtype: str + """ + return self._peer_tenancy_id + + @peer_tenancy_id.setter + def peer_tenancy_id(self, peer_tenancy_id): + """ + Sets the peer_tenancy_id of this RemotePeeringConnection. + If this RPC is peered, this value is the OCID of the other RPC's tenancy. + + + :param peer_tenancy_id: The peer_tenancy_id of this RemotePeeringConnection. + :type: str + """ + self._peer_tenancy_id = peer_tenancy_id + + @property + def peering_status(self): + """ + **[Required]** Gets the peering_status of this RemotePeeringConnection. + Whether the RPC is peered with another RPC. `NEW` means the RPC has not yet been + peered. `PENDING` means the peering is being established. `REVOKED` means the + RPC at the other end of the peering has been deleted. + + Allowed values for this property are: "INVALID", "NEW", "PENDING", "PEERED", "REVOKED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The peering_status of this RemotePeeringConnection. + :rtype: str + """ + return self._peering_status + + @peering_status.setter + def peering_status(self, peering_status): + """ + Sets the peering_status of this RemotePeeringConnection. + Whether the RPC is peered with another RPC. `NEW` means the RPC has not yet been + peered. `PENDING` means the peering is being established. `REVOKED` means the + RPC at the other end of the peering has been deleted. + + + :param peering_status: The peering_status of this RemotePeeringConnection. + :type: str + """ + allowed_values = ["INVALID", "NEW", "PENDING", "PEERED", "REVOKED"] + if not value_allowed_none_or_none_sentinel(peering_status, allowed_values): + peering_status = 'UNKNOWN_ENUM_VALUE' + self._peering_status = peering_status + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this RemotePeeringConnection. + The date and time the RPC was created, in the format defined by RFC3339. + + Example: `2016-08-25T21:10:29.600Z` + + + :return: The time_created of this RemotePeeringConnection. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this RemotePeeringConnection. + The date and time the RPC was created, in the format defined by RFC3339. + + Example: `2016-08-25T21:10:29.600Z` + + + :param time_created: The time_created of this RemotePeeringConnection. + :type: datetime + """ + self._time_created = time_created + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/core/models/route_rule.py b/src/oci/core/models/route_rule.py index 9cc646c0a5..d19b11473d 100644 --- a/src/oci/core/models/route_rule.py +++ b/src/oci/core/models/route_rule.py @@ -11,7 +11,7 @@ class RouteRule(object): def __init__(self, **kwargs): """ - Initializes a new RouteRule object with values from values from keyword arguments. + Initializes a new RouteRule object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/route_table.py b/src/oci/core/models/route_table.py index a97c9fd119..4a5b85e9e6 100644 --- a/src/oci/core/models/route_table.py +++ b/src/oci/core/models/route_table.py @@ -11,7 +11,7 @@ class RouteTable(object): def __init__(self, **kwargs): """ - Initializes a new RouteTable object with values from values from keyword arguments. + Initializes a new RouteTable object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/security_list.py b/src/oci/core/models/security_list.py index 9cf8007537..7ca3a2061f 100644 --- a/src/oci/core/models/security_list.py +++ b/src/oci/core/models/security_list.py @@ -11,7 +11,7 @@ class SecurityList(object): def __init__(self, **kwargs): """ - Initializes a new SecurityList object with values from values from keyword arguments. + Initializes a new SecurityList object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/shape.py b/src/oci/core/models/shape.py index a666a401aa..334703b549 100644 --- a/src/oci/core/models/shape.py +++ b/src/oci/core/models/shape.py @@ -11,7 +11,7 @@ class Shape(object): def __init__(self, **kwargs): """ - Initializes a new Shape object with values from values from keyword arguments. + Initializes a new Shape object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param shape: diff --git a/src/oci/core/models/subnet.py b/src/oci/core/models/subnet.py index 3f284dfb98..c0f59d5894 100644 --- a/src/oci/core/models/subnet.py +++ b/src/oci/core/models/subnet.py @@ -11,7 +11,7 @@ class Subnet(object): def __init__(self, **kwargs): """ - Initializes a new Subnet object with values from values from keyword arguments. + Initializes a new Subnet object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/tcp_options.py b/src/oci/core/models/tcp_options.py index ce8ee20353..32139b50fe 100644 --- a/src/oci/core/models/tcp_options.py +++ b/src/oci/core/models/tcp_options.py @@ -11,7 +11,7 @@ class TcpOptions(object): def __init__(self, **kwargs): """ - Initializes a new TcpOptions object with values from values from keyword arguments. + Initializes a new TcpOptions object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param destination_port_range: diff --git a/src/oci/core/models/tunnel_config.py b/src/oci/core/models/tunnel_config.py index a2cfba4144..e9299a834e 100644 --- a/src/oci/core/models/tunnel_config.py +++ b/src/oci/core/models/tunnel_config.py @@ -11,7 +11,7 @@ class TunnelConfig(object): def __init__(self, **kwargs): """ - Initializes a new TunnelConfig object with values from values from keyword arguments. + Initializes a new TunnelConfig object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ip_address: diff --git a/src/oci/core/models/tunnel_status.py b/src/oci/core/models/tunnel_status.py index c06a84a800..66192ffabd 100644 --- a/src/oci/core/models/tunnel_status.py +++ b/src/oci/core/models/tunnel_status.py @@ -11,7 +11,7 @@ class TunnelStatus(object): def __init__(self, **kwargs): """ - Initializes a new TunnelStatus object with values from values from keyword arguments. + Initializes a new TunnelStatus object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ip_address: diff --git a/src/oci/core/models/udp_options.py b/src/oci/core/models/udp_options.py index c8ee24695a..15435de597 100644 --- a/src/oci/core/models/udp_options.py +++ b/src/oci/core/models/udp_options.py @@ -11,7 +11,7 @@ class UdpOptions(object): def __init__(self, **kwargs): """ - Initializes a new UdpOptions object with values from values from keyword arguments. + Initializes a new UdpOptions object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param destination_port_range: diff --git a/src/oci/core/models/update_boot_volume_details.py b/src/oci/core/models/update_boot_volume_details.py index 95e1b2d699..bf0c86020c 100644 --- a/src/oci/core/models/update_boot_volume_details.py +++ b/src/oci/core/models/update_boot_volume_details.py @@ -11,7 +11,7 @@ class UpdateBootVolumeDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateBootVolumeDetails object with values from values from keyword arguments. + Initializes a new UpdateBootVolumeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_console_history_details.py b/src/oci/core/models/update_console_history_details.py index d2f3016e7a..a2cbdcb120 100644 --- a/src/oci/core/models/update_console_history_details.py +++ b/src/oci/core/models/update_console_history_details.py @@ -11,7 +11,7 @@ class UpdateConsoleHistoryDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateConsoleHistoryDetails object with values from values from keyword arguments. + Initializes a new UpdateConsoleHistoryDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_cpe_details.py b/src/oci/core/models/update_cpe_details.py index 81fe9ef614..ee3b9ebe96 100644 --- a/src/oci/core/models/update_cpe_details.py +++ b/src/oci/core/models/update_cpe_details.py @@ -11,7 +11,7 @@ class UpdateCpeDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateCpeDetails object with values from values from keyword arguments. + Initializes a new UpdateCpeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_cross_connect_details.py b/src/oci/core/models/update_cross_connect_details.py index 75f4662335..727d232b35 100644 --- a/src/oci/core/models/update_cross_connect_details.py +++ b/src/oci/core/models/update_cross_connect_details.py @@ -11,7 +11,7 @@ class UpdateCrossConnectDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateCrossConnectDetails object with values from values from keyword arguments. + Initializes a new UpdateCrossConnectDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_cross_connect_group_details.py b/src/oci/core/models/update_cross_connect_group_details.py index ab947eed45..060604c560 100644 --- a/src/oci/core/models/update_cross_connect_group_details.py +++ b/src/oci/core/models/update_cross_connect_group_details.py @@ -11,7 +11,7 @@ class UpdateCrossConnectGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateCrossConnectGroupDetails object with values from values from keyword arguments. + Initializes a new UpdateCrossConnectGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_dhcp_details.py b/src/oci/core/models/update_dhcp_details.py index 273f8b94b0..9c30dc4305 100644 --- a/src/oci/core/models/update_dhcp_details.py +++ b/src/oci/core/models/update_dhcp_details.py @@ -11,7 +11,7 @@ class UpdateDhcpDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDhcpDetails object with values from values from keyword arguments. + Initializes a new UpdateDhcpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_drg_attachment_details.py b/src/oci/core/models/update_drg_attachment_details.py index e2883077e4..56c98ea51f 100644 --- a/src/oci/core/models/update_drg_attachment_details.py +++ b/src/oci/core/models/update_drg_attachment_details.py @@ -11,7 +11,7 @@ class UpdateDrgAttachmentDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDrgAttachmentDetails object with values from values from keyword arguments. + Initializes a new UpdateDrgAttachmentDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_drg_details.py b/src/oci/core/models/update_drg_details.py index c83dcb0b72..2453dfbfd5 100644 --- a/src/oci/core/models/update_drg_details.py +++ b/src/oci/core/models/update_drg_details.py @@ -11,7 +11,7 @@ class UpdateDrgDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDrgDetails object with values from values from keyword arguments. + Initializes a new UpdateDrgDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_image_details.py b/src/oci/core/models/update_image_details.py index 4e13ebf9db..656c203421 100644 --- a/src/oci/core/models/update_image_details.py +++ b/src/oci/core/models/update_image_details.py @@ -11,7 +11,7 @@ class UpdateImageDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateImageDetails object with values from values from keyword arguments. + Initializes a new UpdateImageDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_instance_details.py b/src/oci/core/models/update_instance_details.py index e61b307f68..fea20f6264 100644 --- a/src/oci/core/models/update_instance_details.py +++ b/src/oci/core/models/update_instance_details.py @@ -11,7 +11,7 @@ class UpdateInstanceDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateInstanceDetails object with values from values from keyword arguments. + Initializes a new UpdateInstanceDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_internet_gateway_details.py b/src/oci/core/models/update_internet_gateway_details.py index 0c52d9b1b5..074724c152 100644 --- a/src/oci/core/models/update_internet_gateway_details.py +++ b/src/oci/core/models/update_internet_gateway_details.py @@ -11,7 +11,7 @@ class UpdateInternetGatewayDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateInternetGatewayDetails object with values from values from keyword arguments. + Initializes a new UpdateInternetGatewayDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_ip_sec_connection_details.py b/src/oci/core/models/update_ip_sec_connection_details.py index 0ff3c8c2d8..ab55ef3fa3 100644 --- a/src/oci/core/models/update_ip_sec_connection_details.py +++ b/src/oci/core/models/update_ip_sec_connection_details.py @@ -11,7 +11,7 @@ class UpdateIPSecConnectionDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateIPSecConnectionDetails object with values from values from keyword arguments. + Initializes a new UpdateIPSecConnectionDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_local_peering_gateway_details.py b/src/oci/core/models/update_local_peering_gateway_details.py index 052e101685..e941de5b61 100644 --- a/src/oci/core/models/update_local_peering_gateway_details.py +++ b/src/oci/core/models/update_local_peering_gateway_details.py @@ -11,7 +11,7 @@ class UpdateLocalPeeringGatewayDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateLocalPeeringGatewayDetails object with values from values from keyword arguments. + Initializes a new UpdateLocalPeeringGatewayDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_private_ip_details.py b/src/oci/core/models/update_private_ip_details.py index da42100c77..014476b1c1 100644 --- a/src/oci/core/models/update_private_ip_details.py +++ b/src/oci/core/models/update_private_ip_details.py @@ -11,7 +11,7 @@ class UpdatePrivateIpDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdatePrivateIpDetails object with values from values from keyword arguments. + Initializes a new UpdatePrivateIpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_public_ip_details.py b/src/oci/core/models/update_public_ip_details.py index 78d6bbb772..78d4ec3844 100644 --- a/src/oci/core/models/update_public_ip_details.py +++ b/src/oci/core/models/update_public_ip_details.py @@ -11,7 +11,7 @@ class UpdatePublicIpDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdatePublicIpDetails object with values from values from keyword arguments. + Initializes a new UpdatePublicIpDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_remote_peering_connection_details.py b/src/oci/core/models/update_remote_peering_connection_details.py new file mode 100644 index 0000000000..23ae75b487 --- /dev/null +++ b/src/oci/core/models/update_remote_peering_connection_details.py @@ -0,0 +1,68 @@ +# coding: utf-8 +# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + + +from ...util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from ...decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateRemotePeeringConnectionDetails(object): + + def __init__(self, **kwargs): + """ + Initializes a new UpdateRemotePeeringConnectionDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param display_name: + The value to assign to the display_name property of this UpdateRemotePeeringConnectionDetails. + :type display_name: str + + """ + self.swagger_types = { + 'display_name': 'str' + } + + self.attribute_map = { + 'display_name': 'displayName' + } + + self._display_name = None + + @property + def display_name(self): + """ + Gets the display_name of this UpdateRemotePeeringConnectionDetails. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :return: The display_name of this UpdateRemotePeeringConnectionDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this UpdateRemotePeeringConnectionDetails. + A user-friendly name. Does not have to be unique, and it's changeable. + Avoid entering confidential information. + + + :param display_name: The display_name of this UpdateRemotePeeringConnectionDetails. + :type: str + """ + self._display_name = display_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/core/models/update_route_table_details.py b/src/oci/core/models/update_route_table_details.py index 879ac07073..0a2143eaa1 100644 --- a/src/oci/core/models/update_route_table_details.py +++ b/src/oci/core/models/update_route_table_details.py @@ -11,7 +11,7 @@ class UpdateRouteTableDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateRouteTableDetails object with values from values from keyword arguments. + Initializes a new UpdateRouteTableDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_security_list_details.py b/src/oci/core/models/update_security_list_details.py index e57be04725..2d49c154a9 100644 --- a/src/oci/core/models/update_security_list_details.py +++ b/src/oci/core/models/update_security_list_details.py @@ -11,7 +11,7 @@ class UpdateSecurityListDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateSecurityListDetails object with values from values from keyword arguments. + Initializes a new UpdateSecurityListDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_subnet_details.py b/src/oci/core/models/update_subnet_details.py index 22a74c27ac..0908a04f98 100644 --- a/src/oci/core/models/update_subnet_details.py +++ b/src/oci/core/models/update_subnet_details.py @@ -11,7 +11,7 @@ class UpdateSubnetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateSubnetDetails object with values from values from keyword arguments. + Initializes a new UpdateSubnetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_vcn_details.py b/src/oci/core/models/update_vcn_details.py index fb66952d29..da8fa4ef50 100644 --- a/src/oci/core/models/update_vcn_details.py +++ b/src/oci/core/models/update_vcn_details.py @@ -11,7 +11,7 @@ class UpdateVcnDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateVcnDetails object with values from values from keyword arguments. + Initializes a new UpdateVcnDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_virtual_circuit_details.py b/src/oci/core/models/update_virtual_circuit_details.py index b32408653a..09cc475df0 100644 --- a/src/oci/core/models/update_virtual_circuit_details.py +++ b/src/oci/core/models/update_virtual_circuit_details.py @@ -11,7 +11,7 @@ class UpdateVirtualCircuitDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateVirtualCircuitDetails object with values from values from keyword arguments. + Initializes a new UpdateVirtualCircuitDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param bandwidth_shape_name: diff --git a/src/oci/core/models/update_vnic_details.py b/src/oci/core/models/update_vnic_details.py index 9317f6813e..7ff29025e4 100644 --- a/src/oci/core/models/update_vnic_details.py +++ b/src/oci/core/models/update_vnic_details.py @@ -11,7 +11,7 @@ class UpdateVnicDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateVnicDetails object with values from values from keyword arguments. + Initializes a new UpdateVnicDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/update_volume_backup_details.py b/src/oci/core/models/update_volume_backup_details.py index 443d416f7f..38110ac1f3 100644 --- a/src/oci/core/models/update_volume_backup_details.py +++ b/src/oci/core/models/update_volume_backup_details.py @@ -11,7 +11,7 @@ class UpdateVolumeBackupDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateVolumeBackupDetails object with values from values from keyword arguments. + Initializes a new UpdateVolumeBackupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/update_volume_details.py b/src/oci/core/models/update_volume_details.py index bb623e8a23..e54b4b65de 100644 --- a/src/oci/core/models/update_volume_details.py +++ b/src/oci/core/models/update_volume_details.py @@ -11,7 +11,7 @@ class UpdateVolumeDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateVolumeDetails object with values from values from keyword arguments. + Initializes a new UpdateVolumeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param defined_tags: diff --git a/src/oci/core/models/vcn.py b/src/oci/core/models/vcn.py index ca96e3fb62..8e6e872b19 100644 --- a/src/oci/core/models/vcn.py +++ b/src/oci/core/models/vcn.py @@ -11,7 +11,7 @@ class Vcn(object): def __init__(self, **kwargs): """ - Initializes a new Vcn object with values from values from keyword arguments. + Initializes a new Vcn object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/virtual_circuit.py b/src/oci/core/models/virtual_circuit.py index d2e0897d8d..82f008d95c 100644 --- a/src/oci/core/models/virtual_circuit.py +++ b/src/oci/core/models/virtual_circuit.py @@ -11,7 +11,7 @@ class VirtualCircuit(object): def __init__(self, **kwargs): """ - Initializes a new VirtualCircuit object with values from values from keyword arguments. + Initializes a new VirtualCircuit object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param bandwidth_shape_name: diff --git a/src/oci/core/models/virtual_circuit_bandwidth_shape.py b/src/oci/core/models/virtual_circuit_bandwidth_shape.py index ff089dc473..68ff05de47 100644 --- a/src/oci/core/models/virtual_circuit_bandwidth_shape.py +++ b/src/oci/core/models/virtual_circuit_bandwidth_shape.py @@ -11,7 +11,7 @@ class VirtualCircuitBandwidthShape(object): def __init__(self, **kwargs): """ - Initializes a new VirtualCircuitBandwidthShape object with values from values from keyword arguments. + Initializes a new VirtualCircuitBandwidthShape object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param bandwidth_in_mbps: diff --git a/src/oci/core/models/virtual_circuit_public_prefix.py b/src/oci/core/models/virtual_circuit_public_prefix.py index 0cf2bf6e5c..9cd9a22395 100644 --- a/src/oci/core/models/virtual_circuit_public_prefix.py +++ b/src/oci/core/models/virtual_circuit_public_prefix.py @@ -11,7 +11,7 @@ class VirtualCircuitPublicPrefix(object): def __init__(self, **kwargs): """ - Initializes a new VirtualCircuitPublicPrefix object with values from values from keyword arguments. + Initializes a new VirtualCircuitPublicPrefix object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cidr_block: diff --git a/src/oci/core/models/vnic.py b/src/oci/core/models/vnic.py index d1ae3d30c3..7f5c729d9f 100644 --- a/src/oci/core/models/vnic.py +++ b/src/oci/core/models/vnic.py @@ -11,7 +11,7 @@ class Vnic(object): def __init__(self, **kwargs): """ - Initializes a new Vnic object with values from values from keyword arguments. + Initializes a new Vnic object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/vnic_attachment.py b/src/oci/core/models/vnic_attachment.py index fef883048e..19f25da7e6 100644 --- a/src/oci/core/models/vnic_attachment.py +++ b/src/oci/core/models/vnic_attachment.py @@ -11,7 +11,7 @@ class VnicAttachment(object): def __init__(self, **kwargs): """ - Initializes a new VnicAttachment object with values from values from keyword arguments. + Initializes a new VnicAttachment object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/volume.py b/src/oci/core/models/volume.py index 4e1f2de293..00abde197a 100644 --- a/src/oci/core/models/volume.py +++ b/src/oci/core/models/volume.py @@ -11,7 +11,7 @@ class Volume(object): def __init__(self, **kwargs): """ - Initializes a new Volume object with values from values from keyword arguments. + Initializes a new Volume object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/core/models/volume_attachment.py b/src/oci/core/models/volume_attachment.py index 0095c5c678..b85b5bd0e1 100644 --- a/src/oci/core/models/volume_attachment.py +++ b/src/oci/core/models/volume_attachment.py @@ -11,7 +11,7 @@ class VolumeAttachment(object): def __init__(self, **kwargs): """ - Initializes a new VolumeAttachment object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new VolumeAttachment object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.IScsiVolumeAttachment` diff --git a/src/oci/core/models/volume_backup.py b/src/oci/core/models/volume_backup.py index 203c1c5a72..b71e5b107c 100644 --- a/src/oci/core/models/volume_backup.py +++ b/src/oci/core/models/volume_backup.py @@ -11,7 +11,7 @@ class VolumeBackup(object): def __init__(self, **kwargs): """ - Initializes a new VolumeBackup object with values from values from keyword arguments. + Initializes a new VolumeBackup object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/core/models/volume_backup_policy.py b/src/oci/core/models/volume_backup_policy.py index df7adeef01..dc8acdf5f3 100644 --- a/src/oci/core/models/volume_backup_policy.py +++ b/src/oci/core/models/volume_backup_policy.py @@ -11,7 +11,7 @@ class VolumeBackupPolicy(object): def __init__(self, **kwargs): """ - Initializes a new VolumeBackupPolicy object with values from values from keyword arguments. + Initializes a new VolumeBackupPolicy object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/core/models/volume_backup_policy_assignment.py b/src/oci/core/models/volume_backup_policy_assignment.py index ae35a369b6..aae1e8f32c 100644 --- a/src/oci/core/models/volume_backup_policy_assignment.py +++ b/src/oci/core/models/volume_backup_policy_assignment.py @@ -11,7 +11,7 @@ class VolumeBackupPolicyAssignment(object): def __init__(self, **kwargs): """ - Initializes a new VolumeBackupPolicyAssignment object with values from values from keyword arguments. + Initializes a new VolumeBackupPolicyAssignment object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param asset_id: diff --git a/src/oci/core/models/volume_backup_schedule.py b/src/oci/core/models/volume_backup_schedule.py index 72ef69a69b..276b3a2db7 100644 --- a/src/oci/core/models/volume_backup_schedule.py +++ b/src/oci/core/models/volume_backup_schedule.py @@ -11,7 +11,7 @@ class VolumeBackupSchedule(object): def __init__(self, **kwargs): """ - Initializes a new VolumeBackupSchedule object with values from values from keyword arguments. + Initializes a new VolumeBackupSchedule object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup_type: diff --git a/src/oci/core/models/volume_source_details.py b/src/oci/core/models/volume_source_details.py index cac9bdde56..698524bdba 100644 --- a/src/oci/core/models/volume_source_details.py +++ b/src/oci/core/models/volume_source_details.py @@ -11,7 +11,7 @@ class VolumeSourceDetails(object): def __init__(self, **kwargs): """ - Initializes a new VolumeSourceDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new VolumeSourceDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.core.models.VolumeSourceFromVolumeDetails` diff --git a/src/oci/core/models/volume_source_from_volume_backup_details.py b/src/oci/core/models/volume_source_from_volume_backup_details.py index 2dc86a37dd..6eb4b60594 100644 --- a/src/oci/core/models/volume_source_from_volume_backup_details.py +++ b/src/oci/core/models/volume_source_from_volume_backup_details.py @@ -11,7 +11,7 @@ class VolumeSourceFromVolumeBackupDetails(VolumeSourceDetails): def __init__(self, **kwargs): """ - Initializes a new VolumeSourceFromVolumeBackupDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.VolumeSourceFromVolumeBackupDetails.type` attribute + Initializes a new VolumeSourceFromVolumeBackupDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.VolumeSourceFromVolumeBackupDetails.type` attribute of this class is ``volumeBackup`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/models/volume_source_from_volume_details.py b/src/oci/core/models/volume_source_from_volume_details.py index ce817d4d37..d46e1d313e 100644 --- a/src/oci/core/models/volume_source_from_volume_details.py +++ b/src/oci/core/models/volume_source_from_volume_details.py @@ -11,7 +11,7 @@ class VolumeSourceFromVolumeDetails(VolumeSourceDetails): def __init__(self, **kwargs): """ - Initializes a new VolumeSourceFromVolumeDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.core.models.VolumeSourceFromVolumeDetails.type` attribute + Initializes a new VolumeSourceFromVolumeDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.core.models.VolumeSourceFromVolumeDetails.type` attribute of this class is ``volume`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/core/virtual_network_client.py b/src/oci/core/virtual_network_client.py index b3789b04fb..846233ae29 100644 --- a/src/oci/core/virtual_network_client.py +++ b/src/oci/core/virtual_network_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("virtual_network", config, signer, core_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def bulk_add_virtual_circuit_public_prefixes(self, virtual_circuit_id, bulk_add_virtual_circuit_public_prefixes_details, **kwargs): """ @@ -74,8 +75,12 @@ def bulk_add_virtual_circuit_public_prefixes(self, virtual_circuit_id, bulk_add_ "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -132,8 +137,12 @@ def bulk_delete_virtual_circuit_public_prefixes(self, virtual_circuit_id, bulk_d "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -196,8 +205,12 @@ def connect_local_peering_gateways(self, local_peering_gateway_id, connect_local "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -212,6 +225,70 @@ def connect_local_peering_gateways(self, local_peering_gateway_id, connect_local header_params=header_params, body=connect_local_peering_gateways_details) + def connect_remote_peering_connections(self, remote_peering_connection_id, connect_remote_peering_connections_details, **kwargs): + """ + ConnectRemotePeeringConnections + Connects this RPC to another one in a different region. + + This operation must be called by the VCN administrator who is designated as + the *requestor* in the peering relationship. The *acceptor* must implement + an Identity and Access Management (IAM) policy that gives the requestor permission + to connect to RPCs in the acceptor's compartment. Without that permission, this + operation will fail. For more information, see + `VCN Peering`__. + + __ https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Tasks/VCNpeering.htm + + + :param str remote_peering_connection_id: (required) + The OCID of the remote peering connection (RPC). + + :param ConnectRemotePeeringConnectionsDetails connect_remote_peering_connections_details: (required) + Details to connect peering connection with peering connection from remote region + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/remotePeeringConnections/{remotePeeringConnectionId}/actions/connect" + method = "POST" + + expected_kwargs = ["retry_strategy"] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "connect_remote_peering_connections got unknown kwargs: {!r}".format(extra_kwargs)) + + path_params = { + "remotePeeringConnectionId": remote_peering_connection_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError('Parameter {} cannot be None, whitespace or empty string'.format(k)) + + header_params = { + "accept": "application/json", + "content-type": "application/json" + } + + if kwargs.get('retry_strategy'): + return kwargs['retry_strategy'].make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=connect_remote_peering_connections_details) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=connect_remote_peering_connections_details) + def create_cpe(self, create_cpe_details, **kwargs): """ CreateCpe @@ -270,10 +347,14 @@ def create_cpe(self, create_cpe_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -349,10 +430,14 @@ def create_cross_connect(self, create_cross_connect_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -424,10 +509,14 @@ def create_cross_connect_group(self, create_cross_connect_group_details, **kwarg } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -495,10 +584,14 @@ def create_dhcp_options(self, create_dhcp_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -567,10 +660,14 @@ def create_drg(self, create_drg_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -637,10 +734,14 @@ def create_drg_attachment(self, create_drg_attachment_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -718,10 +819,14 @@ def create_internet_gateway(self, create_internet_gateway_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -805,10 +910,14 @@ def create_ip_sec_connection(self, create_ip_sec_connection_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -862,10 +971,14 @@ def create_local_peering_gateway(self, create_local_peering_gateway_details, **k } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -923,10 +1036,14 @@ def create_private_ip(self, create_private_ip_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1001,10 +1118,14 @@ def create_public_ip(self, create_public_ip_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1019,6 +1140,63 @@ def create_public_ip(self, create_public_ip_details, **kwargs): body=create_public_ip_details, response_type="PublicIp") + def create_remote_peering_connection(self, create_remote_peering_connection_details, **kwargs): + """ + CreateRemotePeeringConnection + Creates a new remote peering connection (RPC) for the specified DRG. + + + :param CreateRemotePeeringConnectionDetails create_remote_peering_connection_details: (required) + Request to create peering connection to remote region + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or + server error without risk of executing that same action again. Retry tokens expire after 24 + hours, but can be invalidated before then due to conflicting operations (for example, if a resource + has been deleted and purged from the system, then a retry of the original creation request + may be rejected). + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.RemotePeeringConnection` + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/remotePeeringConnections" + method = "POST" + + # Don't accept unknown kwargs + expected_kwargs = [ + "retry_strategy", + "opc_retry_token" + ] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "create_remote_peering_connection got unknown kwargs: {!r}".format(extra_kwargs)) + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + + if kwargs.get('retry_strategy'): + if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + return kwargs['retry_strategy'].make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + header_params=header_params, + body=create_remote_peering_connection_details, + response_type="RemotePeeringConnection") + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + header_params=header_params, + body=create_remote_peering_connection_details, + response_type="RemotePeeringConnection") + def create_route_table(self, create_route_table_details, **kwargs): """ CreateRouteTable @@ -1077,10 +1255,14 @@ def create_route_table(self, create_route_table_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1152,10 +1334,14 @@ def create_security_list(self, create_security_list_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1248,10 +1434,14 @@ def create_subnet(self, create_subnet_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1340,10 +1530,14 @@ def create_vcn(self, create_vcn_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1422,10 +1616,14 @@ def create_virtual_circuit(self, create_virtual_circuit_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1489,8 +1687,12 @@ def delete_cpe(self, cpe_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1551,8 +1753,12 @@ def delete_cross_connect(self, cross_connect_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1614,8 +1820,12 @@ def delete_cross_connect_group(self, cross_connect_group_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1679,8 +1889,12 @@ def delete_dhcp_options(self, dhcp_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1743,8 +1957,12 @@ def delete_drg(self, drg_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1806,8 +2024,12 @@ def delete_drg_attachment(self, drg_attachment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1871,8 +2093,12 @@ def delete_internet_gateway(self, ig_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1939,8 +2165,12 @@ def delete_ip_sec_connection(self, ipsc_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2003,8 +2233,12 @@ def delete_local_peering_gateway(self, local_peering_gateway_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2076,8 +2310,12 @@ def delete_private_ip(self, private_ip_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2147,6 +2385,74 @@ def delete_public_ip(self, public_ip_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy + if kwargs.get('retry_strategy'): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params) + + def delete_remote_peering_connection(self, remote_peering_connection_id, **kwargs): + """ + DeleteRemotePeeringConnection + Deletes the remote peering connection (RPC). + + This is an asynchronous operation; the RPC's `lifecycleState` changes to TERMINATING temporarily + until the RPC is completely removed. + + + :param str remote_peering_connection_id: (required) + The OCID of the remote peering connection (RPC). + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` + parameter to the value of the etag from a previous GET or POST response for that resource. The resource + will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/remotePeeringConnections/{remotePeeringConnectionId}" + method = "DELETE" + + # Don't accept unknown kwargs + expected_kwargs = [ + "retry_strategy", + "if_match" + ] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "delete_remote_peering_connection got unknown kwargs: {!r}".format(extra_kwargs)) + + path_params = { + "remotePeeringConnectionId": remote_peering_connection_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError('Parameter {} cannot be None, whitespace or empty string'.format(k)) + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + if kwargs.get('retry_strategy'): return kwargs['retry_strategy'].make_retrying_call( self.base_client.call_api, @@ -2212,8 +2518,12 @@ def delete_route_table(self, rt_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2277,8 +2587,12 @@ def delete_security_list(self, security_list_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2340,8 +2654,12 @@ def delete_subnet(self, subnet_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2403,8 +2721,12 @@ def delete_vcn(self, vcn_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2468,8 +2790,12 @@ def delete_virtual_circuit(self, virtual_circuit_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2518,8 +2844,12 @@ def get_cpe(self, cpe_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2570,8 +2900,12 @@ def get_cross_connect(self, cross_connect_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2622,8 +2956,12 @@ def get_cross_connect_group(self, cross_connect_group_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2674,8 +3012,12 @@ def get_cross_connect_letter_of_authority(self, cross_connect_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2726,8 +3068,12 @@ def get_cross_connect_status(self, cross_connect_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2778,8 +3124,12 @@ def get_dhcp_options(self, dhcp_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2830,8 +3180,12 @@ def get_drg(self, drg_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2882,8 +3236,12 @@ def get_drg_attachment(self, drg_attachment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2937,8 +3295,12 @@ def get_fast_connect_provider_service(self, provider_service_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2989,8 +3351,12 @@ def get_internet_gateway(self, ig_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3043,8 +3409,12 @@ def get_ip_sec_connection(self, ipsc_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3096,8 +3466,12 @@ def get_ip_sec_connection_device_config(self, ipsc_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3148,8 +3522,12 @@ def get_ip_sec_connection_device_status(self, ipsc_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3200,8 +3578,12 @@ def get_local_peering_gateway(self, local_peering_gateway_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3255,8 +3637,12 @@ def get_private_ip(self, private_ip_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3317,8 +3703,12 @@ def get_public_ip(self, public_ip_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3363,8 +3753,12 @@ def get_public_ip_by_ip_address(self, get_public_ip_by_ip_address_details, **kwa "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3395,20 +3789,76 @@ def get_public_ip_by_private_ip_id(self, get_public_ip_by_private_ip_id_details, of the target private IP. - :param GetPublicIpByPrivateIpIdDetails get_public_ip_by_private_ip_id_details: (required) - Private IP details for fetching the public IP. + :param GetPublicIpByPrivateIpIdDetails get_public_ip_by_private_ip_id_details: (required) + Private IP details for fetching the public IP. + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.PublicIp` + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/publicIps/actions/getByPrivateIpId" + method = "POST" + + expected_kwargs = ["retry_strategy"] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "get_public_ip_by_private_ip_id got unknown kwargs: {!r}".format(extra_kwargs)) + + header_params = { + "accept": "application/json", + "content-type": "application/json" + } + + retry_strategy = self.retry_strategy + if kwargs.get('retry_strategy'): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + header_params=header_params, + body=get_public_ip_by_private_ip_id_details, + response_type="PublicIp") + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + header_params=header_params, + body=get_public_ip_by_private_ip_id_details, + response_type="PublicIp") + + def get_remote_peering_connection(self, remote_peering_connection_id, **kwargs): + """ + GetRemotePeeringConnection + Get the specified remote peering connection's information. + + + :param str remote_peering_connection_id: (required) + The OCID of the remote peering connection (RPC). - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.PublicIp` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.RemotePeeringConnection` :rtype: :class:`~oci.response.Response` """ - resource_path = "/publicIps/actions/getByPrivateIpId" - method = "POST" + resource_path = "/remotePeeringConnections/{remotePeeringConnectionId}" + method = "GET" expected_kwargs = ["retry_strategy"] extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] if extra_kwargs: raise ValueError( - "get_public_ip_by_private_ip_id got unknown kwargs: {!r}".format(extra_kwargs)) + "get_remote_peering_connection got unknown kwargs: {!r}".format(extra_kwargs)) + + path_params = { + "remotePeeringConnectionId": remote_peering_connection_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError('Parameter {} cannot be None, whitespace or empty string'.format(k)) header_params = { "accept": "application/json", @@ -3420,16 +3870,16 @@ def get_public_ip_by_private_ip_id(self, get_public_ip_by_private_ip_id_details, self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=get_public_ip_by_private_ip_id_details, - response_type="PublicIp") + response_type="RemotePeeringConnection") else: return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=get_public_ip_by_private_ip_id_details, - response_type="PublicIp") + response_type="RemotePeeringConnection") def get_route_table(self, rt_id, **kwargs): """ @@ -3467,8 +3917,12 @@ def get_route_table(self, rt_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3519,8 +3973,12 @@ def get_security_list(self, security_list_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3571,8 +4029,12 @@ def get_subnet(self, subnet_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3623,8 +4085,12 @@ def get_vcn(self, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3675,8 +4141,12 @@ def get_virtual_circuit(self, virtual_circuit_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3730,8 +4200,12 @@ def get_vnic(self, vnic_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3746,6 +4220,46 @@ def get_vnic(self, vnic_id, **kwargs): header_params=header_params, response_type="Vnic") + def list_allowed_peer_regions_for_remote_peering(self, **kwargs): + """ + ListAllowedPeerRegionsForRemotePeering + Lists the regions that support remote VCN peering (which is peering across regions). + For more information, see `VCN Peering`__. + + __ https://docs.us-phoenix-1.oraclecloud.com/Content/Network/Tasks/VCNpeering.htm + + + :return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.core.models.PeerRegionForRemotePeering` + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/allowedPeerRegionsForRemotePeering" + method = "GET" + + expected_kwargs = ["retry_strategy"] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "list_allowed_peer_regions_for_remote_peering got unknown kwargs: {!r}".format(extra_kwargs)) + + header_params = { + "accept": "application/json", + "content-type": "application/json" + } + + if kwargs.get('retry_strategy'): + return kwargs['retry_strategy'].make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + header_params=header_params, + response_type="list[PeerRegionForRemotePeering]") + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + header_params=header_params, + response_type="list[PeerRegionForRemotePeering]") + def list_cpes(self, compartment_id, **kwargs): """ ListCpes @@ -3792,8 +4306,12 @@ def list_cpes(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3909,8 +4427,12 @@ def list_cross_connect_groups(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3972,8 +4494,12 @@ def list_cross_connect_locations(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4095,8 +4621,12 @@ def list_cross_connects(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4159,8 +4689,12 @@ def list_crossconnect_port_speed_shapes(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4282,8 +4816,12 @@ def list_dhcp_options(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4355,8 +4893,12 @@ def list_drg_attachments(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4417,8 +4959,12 @@ def list_drgs(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4487,8 +5033,12 @@ def list_fast_connect_provider_services(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4563,8 +5113,12 @@ def list_fast_connect_provider_virtual_circuit_bandwidth_shapes(self, provider_s "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4686,8 +5240,12 @@ def list_internet_gateways(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4759,8 +5317,12 @@ def list_ip_sec_connections(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4826,8 +5388,12 @@ def list_local_peering_gateways(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4913,8 +5479,12 @@ def list_private_ips(self, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5009,8 +5579,12 @@ def list_public_ips(self, scope, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5025,6 +5599,74 @@ def list_public_ips(self, scope, compartment_id, **kwargs): header_params=header_params, response_type="list[PublicIp]") + def list_remote_peering_connections(self, compartment_id, **kwargs): + """ + ListRemotePeeringConnections + Lists the remote peering connections (RPCs) for the specified DRG and compartment + (the RPC's compartment). + + + :param str compartment_id: (required) + The OCID of the compartment. + + :param str drg_id: (optional) + The OCID of the DRG. + + :param int limit: (optional) + The maximum number of items to return in a paginated \"List\" call. + + Example: `500` + + :param str page: (optional) + The value of the `opc-next-page` response header from the previous \"List\" call. + + :return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.core.models.RemotePeeringConnection` + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/remotePeeringConnections" + method = "GET" + + # Don't accept unknown kwargs + expected_kwargs = [ + "retry_strategy", + "drg_id", + "limit", + "page" + ] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "list_remote_peering_connections got unknown kwargs: {!r}".format(extra_kwargs)) + + query_params = { + "compartmentId": compartment_id, + "drgId": kwargs.get("drg_id", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing} + + header_params = { + "accept": "application/json", + "content-type": "application/json" + } + + if kwargs.get('retry_strategy'): + return kwargs['retry_strategy'].make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="list[RemotePeeringConnection]") + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="list[RemotePeeringConnection]") + def list_route_tables(self, compartment_id, vcn_id, **kwargs): """ ListRouteTables @@ -5132,8 +5774,12 @@ def list_route_tables(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5253,8 +5899,12 @@ def list_security_lists(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5374,8 +6024,12 @@ def list_subnets(self, compartment_id, vcn_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5491,8 +6145,12 @@ def list_vcns(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5553,8 +6211,12 @@ def list_virtual_circuit_bandwidth_shapes(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5628,8 +6290,12 @@ def list_virtual_circuit_public_prefixes(self, virtual_circuit_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5747,8 +6413,12 @@ def list_virtual_circuits(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5814,8 +6484,12 @@ def update_cpe(self, cpe_id, update_cpe_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5882,8 +6556,12 @@ def update_cross_connect(self, cross_connect_id, update_cross_connect_details, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -5951,8 +6629,12 @@ def update_cross_connect_group(self, cross_connect_group_id, update_cross_connec } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6022,8 +6704,12 @@ def update_dhcp_options(self, dhcp_id, update_dhcp_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6090,8 +6776,12 @@ def update_drg(self, drg_id, update_drg_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6159,8 +6849,12 @@ def update_drg_attachment(self, drg_attachment_id, update_drg_attachment_details } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6231,8 +6925,12 @@ def update_internet_gateway(self, ig_id, update_internet_gateway_details, **kwar } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6300,8 +6998,12 @@ def update_ip_sec_connection(self, ipsc_id, update_ip_sec_connection_details, ** } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6368,8 +7070,12 @@ def update_local_peering_gateway(self, local_peering_gateway_id, update_local_pe } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6445,8 +7151,12 @@ def update_private_ip(self, private_ip_id, update_private_ip_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6553,8 +7263,12 @@ def update_public_ip(self, public_ip_id, update_public_ip_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6571,6 +7285,74 @@ def update_public_ip(self, public_ip_id, update_public_ip_details, **kwargs): body=update_public_ip_details, response_type="PublicIp") + def update_remote_peering_connection(self, remote_peering_connection_id, update_remote_peering_connection_details, **kwargs): + """ + UpdateRemotePeeringConnection + Updates the specified remote peering connection (RPC). + + + :param str remote_peering_connection_id: (required) + The OCID of the remote peering connection (RPC). + + :param UpdateRemotePeeringConnectionDetails update_remote_peering_connection_details: (required) + Request to the update the peering connection to remote region + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` + parameter to the value of the etag from a previous GET or POST response for that resource. The resource + will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.core.models.RemotePeeringConnection` + :rtype: :class:`~oci.response.Response` + """ + resource_path = "/remotePeeringConnections/{remotePeeringConnectionId}" + method = "PUT" + + # Don't accept unknown kwargs + expected_kwargs = [ + "retry_strategy", + "if_match" + ] + extra_kwargs = [key for key in six.iterkeys(kwargs) if key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + "update_remote_peering_connection got unknown kwargs: {!r}".format(extra_kwargs)) + + path_params = { + "remotePeeringConnectionId": remote_peering_connection_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError('Parameter {} cannot be None, whitespace or empty string'.format(k)) + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + + if kwargs.get('retry_strategy'): + return kwargs['retry_strategy'].make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_remote_peering_connection_details, + response_type="RemotePeeringConnection") + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_remote_peering_connection_details, + response_type="RemotePeeringConnection") + def update_route_table(self, rt_id, update_route_table_details, **kwargs): """ UpdateRouteTable @@ -6624,8 +7406,12 @@ def update_route_table(self, rt_id, update_route_table_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6696,8 +7482,12 @@ def update_security_list(self, security_list_id, update_security_list_details, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6764,8 +7554,12 @@ def update_subnet(self, subnet_id, update_subnet_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6833,8 +7627,12 @@ def update_vcn(self, vcn_id, update_vcn_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6926,8 +7724,12 @@ def update_virtual_circuit(self, virtual_circuit_id, update_virtual_circuit_deta } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -6994,8 +7796,12 @@ def update_vnic(self, vnic_id, update_vnic_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/database/database_client.py b/src/oci/database/database_client.py index 7445d5baa9..4a0cb9c169 100644 --- a/src/oci/database/database_client.py +++ b/src/oci/database/database_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("database", config, signer, database_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_backup(self, create_backup_details, **kwargs): """ @@ -71,10 +72,14 @@ def create_backup(self, create_backup_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -153,10 +158,14 @@ def create_data_guard_association(self, database_id, create_data_guard_associati } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -212,10 +221,14 @@ def create_db_home(self, create_db_home_with_db_system_id_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -312,10 +325,14 @@ def db_node_action(self, db_node_id, action, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -379,8 +396,12 @@ def delete_backup(self, backup_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -451,8 +472,12 @@ def delete_db_home(self, db_home_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -529,8 +554,12 @@ def failover_data_guard_association(self, database_id, data_guard_association_id } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -583,8 +612,12 @@ def get_backup(self, backup_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -643,8 +676,12 @@ def get_data_guard_association(self, database_id, data_guard_association_id, **k "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -697,8 +734,12 @@ def get_database(self, database_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -751,8 +792,12 @@ def get_db_home(self, db_home_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -809,8 +854,12 @@ def get_db_home_patch(self, db_home_id, patch_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -867,8 +916,12 @@ def get_db_home_patch_history_entry(self, db_home_id, patch_history_entry_id, ** "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -921,8 +974,12 @@ def get_db_node(self, db_node_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -975,8 +1032,12 @@ def get_db_system(self, db_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1033,8 +1094,12 @@ def get_db_system_patch(self, db_system_id, patch_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1091,8 +1156,12 @@ def get_db_system_patch_history_entry(self, db_system_id, patch_history_entry_id "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1158,10 +1227,14 @@ def launch_db_system(self, launch_db_system_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1226,8 +1299,12 @@ def list_backups(self, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1297,8 +1374,12 @@ def list_data_guard_associations(self, database_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1367,8 +1448,12 @@ def list_databases(self, compartment_id, db_home_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1438,8 +1523,12 @@ def list_db_home_patch_history_entries(self, db_home_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1511,8 +1600,12 @@ def list_db_home_patches(self, db_home_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1581,8 +1674,12 @@ def list_db_homes(self, compartment_id, db_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1649,8 +1746,12 @@ def list_db_nodes(self, compartment_id, db_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1720,8 +1821,12 @@ def list_db_system_patch_history_entries(self, db_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1793,8 +1898,12 @@ def list_db_system_patches(self, db_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1861,8 +1970,12 @@ def list_db_system_shapes(self, availability_domain, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1928,8 +2041,12 @@ def list_db_systems(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1995,8 +2112,12 @@ def list_db_versions(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2069,8 +2190,12 @@ def reinstate_data_guard_association(self, database_id, data_guard_association_i } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2139,8 +2264,12 @@ def restore_database(self, database_id, restore_database_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2218,8 +2347,12 @@ def switchover_data_guard_association(self, database_id, data_guard_association_ } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2285,8 +2418,12 @@ def terminate_db_system(self, db_system_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2351,8 +2488,12 @@ def update_database(self, database_id, update_database_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2421,8 +2562,12 @@ def update_db_home(self, db_home_id, update_db_home_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2491,8 +2636,12 @@ def update_db_system(self, db_system_id, update_db_system_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/database/models/backup.py b/src/oci/database/models/backup.py index d76d8ab93d..7c77120d45 100644 --- a/src/oci/database/models/backup.py +++ b/src/oci/database/models/backup.py @@ -11,7 +11,7 @@ class Backup(object): def __init__(self, **kwargs): """ - Initializes a new Backup object with values from values from keyword arguments. + Initializes a new Backup object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/database/models/backup_summary.py b/src/oci/database/models/backup_summary.py index b2351007e8..2bf52505c8 100644 --- a/src/oci/database/models/backup_summary.py +++ b/src/oci/database/models/backup_summary.py @@ -11,7 +11,7 @@ class BackupSummary(object): def __init__(self, **kwargs): """ - Initializes a new BackupSummary object with values from values from keyword arguments. + Initializes a new BackupSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/database/models/create_backup_details.py b/src/oci/database/models/create_backup_details.py index 30449fe66c..26826556bd 100644 --- a/src/oci/database/models/create_backup_details.py +++ b/src/oci/database/models/create_backup_details.py @@ -11,7 +11,7 @@ class CreateBackupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateBackupDetails object with values from values from keyword arguments. + Initializes a new CreateBackupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database_id: diff --git a/src/oci/database/models/create_data_guard_association_details.py b/src/oci/database/models/create_data_guard_association_details.py index 5cad2a599a..d84d68e7df 100644 --- a/src/oci/database/models/create_data_guard_association_details.py +++ b/src/oci/database/models/create_data_guard_association_details.py @@ -11,7 +11,7 @@ class CreateDataGuardAssociationDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDataGuardAssociationDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new CreateDataGuardAssociationDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.database.models.CreateDataGuardAssociationToExistingDbSystemDetails` diff --git a/src/oci/database/models/create_data_guard_association_to_existing_db_system_details.py b/src/oci/database/models/create_data_guard_association_to_existing_db_system_details.py index 244e426f63..e44a7542d8 100644 --- a/src/oci/database/models/create_data_guard_association_to_existing_db_system_details.py +++ b/src/oci/database/models/create_data_guard_association_to_existing_db_system_details.py @@ -11,7 +11,7 @@ class CreateDataGuardAssociationToExistingDbSystemDetails(CreateDataGuardAssocia def __init__(self, **kwargs): """ - Initializes a new CreateDataGuardAssociationToExistingDbSystemDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDataGuardAssociationToExistingDbSystemDetails.creation_type` attribute + Initializes a new CreateDataGuardAssociationToExistingDbSystemDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDataGuardAssociationToExistingDbSystemDetails.creation_type` attribute of this class is ``ExistingDbSystem`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/database/models/create_database_details.py b/src/oci/database/models/create_database_details.py index a85212bb71..933c8f49d9 100644 --- a/src/oci/database/models/create_database_details.py +++ b/src/oci/database/models/create_database_details.py @@ -11,7 +11,7 @@ class CreateDatabaseDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDatabaseDetails object with values from values from keyword arguments. + Initializes a new CreateDatabaseDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param admin_password: diff --git a/src/oci/database/models/create_database_from_backup_details.py b/src/oci/database/models/create_database_from_backup_details.py index aa058c1e95..d19ec067e7 100644 --- a/src/oci/database/models/create_database_from_backup_details.py +++ b/src/oci/database/models/create_database_from_backup_details.py @@ -11,7 +11,7 @@ class CreateDatabaseFromBackupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDatabaseFromBackupDetails object with values from values from keyword arguments. + Initializes a new CreateDatabaseFromBackupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param admin_password: diff --git a/src/oci/database/models/create_db_home_details.py b/src/oci/database/models/create_db_home_details.py index 2fae6980aa..9853800633 100644 --- a/src/oci/database/models/create_db_home_details.py +++ b/src/oci/database/models/create_db_home_details.py @@ -11,7 +11,7 @@ class CreateDbHomeDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDbHomeDetails object with values from values from keyword arguments. + Initializes a new CreateDbHomeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database: diff --git a/src/oci/database/models/create_db_home_with_db_system_id_base.py b/src/oci/database/models/create_db_home_with_db_system_id_base.py index a859bfe136..01a43b30a6 100644 --- a/src/oci/database/models/create_db_home_with_db_system_id_base.py +++ b/src/oci/database/models/create_db_home_with_db_system_id_base.py @@ -11,7 +11,7 @@ class CreateDbHomeWithDbSystemIdBase(object): def __init__(self, **kwargs): """ - Initializes a new CreateDbHomeWithDbSystemIdBase object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new CreateDbHomeWithDbSystemIdBase object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.database.models.CreateDbHomeWithDbSystemIdFromBackupDetails` diff --git a/src/oci/database/models/create_db_home_with_db_system_id_details.py b/src/oci/database/models/create_db_home_with_db_system_id_details.py index 8d3fbd61a8..00d833a3af 100644 --- a/src/oci/database/models/create_db_home_with_db_system_id_details.py +++ b/src/oci/database/models/create_db_home_with_db_system_id_details.py @@ -11,7 +11,7 @@ class CreateDbHomeWithDbSystemIdDetails(CreateDbHomeWithDbSystemIdBase): def __init__(self, **kwargs): """ - Initializes a new CreateDbHomeWithDbSystemIdDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDbHomeWithDbSystemIdDetails.source` attribute + Initializes a new CreateDbHomeWithDbSystemIdDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDbHomeWithDbSystemIdDetails.source` attribute of this class is ``NONE`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/database/models/create_db_home_with_db_system_id_from_backup_details.py b/src/oci/database/models/create_db_home_with_db_system_id_from_backup_details.py index ea787a9101..2efcc7d7c5 100644 --- a/src/oci/database/models/create_db_home_with_db_system_id_from_backup_details.py +++ b/src/oci/database/models/create_db_home_with_db_system_id_from_backup_details.py @@ -11,7 +11,7 @@ class CreateDbHomeWithDbSystemIdFromBackupDetails(CreateDbHomeWithDbSystemIdBase def __init__(self, **kwargs): """ - Initializes a new CreateDbHomeWithDbSystemIdFromBackupDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDbHomeWithDbSystemIdFromBackupDetails.source` attribute + Initializes a new CreateDbHomeWithDbSystemIdFromBackupDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.database.models.CreateDbHomeWithDbSystemIdFromBackupDetails.source` attribute of this class is ``DB_BACKUP`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/database/models/data_guard_association.py b/src/oci/database/models/data_guard_association.py index be8a01623b..0de82ca58e 100644 --- a/src/oci/database/models/data_guard_association.py +++ b/src/oci/database/models/data_guard_association.py @@ -11,7 +11,7 @@ class DataGuardAssociation(object): def __init__(self, **kwargs): """ - Initializes a new DataGuardAssociation object with values from values from keyword arguments. + Initializes a new DataGuardAssociation object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param apply_lag: diff --git a/src/oci/database/models/data_guard_association_summary.py b/src/oci/database/models/data_guard_association_summary.py index 4dc89a48b1..6be99836ee 100644 --- a/src/oci/database/models/data_guard_association_summary.py +++ b/src/oci/database/models/data_guard_association_summary.py @@ -11,7 +11,7 @@ class DataGuardAssociationSummary(object): def __init__(self, **kwargs): """ - Initializes a new DataGuardAssociationSummary object with values from values from keyword arguments. + Initializes a new DataGuardAssociationSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param apply_lag: diff --git a/src/oci/database/models/database.py b/src/oci/database/models/database.py index c10a862b2d..af425004ee 100644 --- a/src/oci/database/models/database.py +++ b/src/oci/database/models/database.py @@ -11,7 +11,7 @@ class Database(object): def __init__(self, **kwargs): """ - Initializes a new Database object with values from values from keyword arguments. + Initializes a new Database object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param character_set: diff --git a/src/oci/database/models/database_summary.py b/src/oci/database/models/database_summary.py index 39c0c6c2c1..04d311cfdf 100644 --- a/src/oci/database/models/database_summary.py +++ b/src/oci/database/models/database_summary.py @@ -11,7 +11,7 @@ class DatabaseSummary(object): def __init__(self, **kwargs): """ - Initializes a new DatabaseSummary object with values from values from keyword arguments. + Initializes a new DatabaseSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param character_set: diff --git a/src/oci/database/models/db_backup_config.py b/src/oci/database/models/db_backup_config.py index b20629e1e7..0eab2f6aff 100644 --- a/src/oci/database/models/db_backup_config.py +++ b/src/oci/database/models/db_backup_config.py @@ -11,7 +11,7 @@ class DbBackupConfig(object): def __init__(self, **kwargs): """ - Initializes a new DbBackupConfig object with values from values from keyword arguments. + Initializes a new DbBackupConfig object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param auto_backup_enabled: diff --git a/src/oci/database/models/db_home.py b/src/oci/database/models/db_home.py index cf2cae431f..6a60d301d8 100644 --- a/src/oci/database/models/db_home.py +++ b/src/oci/database/models/db_home.py @@ -11,7 +11,7 @@ class DbHome(object): def __init__(self, **kwargs): """ - Initializes a new DbHome object with values from values from keyword arguments. + Initializes a new DbHome object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/database/models/db_home_summary.py b/src/oci/database/models/db_home_summary.py index 03ac7202f2..1faf09078b 100644 --- a/src/oci/database/models/db_home_summary.py +++ b/src/oci/database/models/db_home_summary.py @@ -11,7 +11,7 @@ class DbHomeSummary(object): def __init__(self, **kwargs): """ - Initializes a new DbHomeSummary object with values from values from keyword arguments. + Initializes a new DbHomeSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/database/models/db_node.py b/src/oci/database/models/db_node.py index bf2cca12d1..b124ef470a 100644 --- a/src/oci/database/models/db_node.py +++ b/src/oci/database/models/db_node.py @@ -11,7 +11,7 @@ class DbNode(object): def __init__(self, **kwargs): """ - Initializes a new DbNode object with values from values from keyword arguments. + Initializes a new DbNode object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup_vnic_id: diff --git a/src/oci/database/models/db_node_summary.py b/src/oci/database/models/db_node_summary.py index 9c4cb7412e..16f259734c 100644 --- a/src/oci/database/models/db_node_summary.py +++ b/src/oci/database/models/db_node_summary.py @@ -11,7 +11,7 @@ class DbNodeSummary(object): def __init__(self, **kwargs): """ - Initializes a new DbNodeSummary object with values from values from keyword arguments. + Initializes a new DbNodeSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup_vnic_id: diff --git a/src/oci/database/models/db_system.py b/src/oci/database/models/db_system.py index 09f067b40a..0127c56f39 100644 --- a/src/oci/database/models/db_system.py +++ b/src/oci/database/models/db_system.py @@ -11,7 +11,7 @@ class DbSystem(object): def __init__(self, **kwargs): """ - Initializes a new DbSystem object with values from values from keyword arguments. + Initializes a new DbSystem object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/database/models/db_system_shape_summary.py b/src/oci/database/models/db_system_shape_summary.py index 8abba971da..c55688d848 100644 --- a/src/oci/database/models/db_system_shape_summary.py +++ b/src/oci/database/models/db_system_shape_summary.py @@ -11,13 +11,29 @@ class DbSystemShapeSummary(object): def __init__(self, **kwargs): """ - Initializes a new DbSystemShapeSummary object with values from values from keyword arguments. + Initializes a new DbSystemShapeSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param available_core_count: The value to assign to the available_core_count property of this DbSystemShapeSummary. :type available_core_count: int + :param core_count_increment: + The value to assign to the core_count_increment property of this DbSystemShapeSummary. + :type core_count_increment: int + + :param maximum_node_count: + The value to assign to the maximum_node_count property of this DbSystemShapeSummary. + :type maximum_node_count: int + + :param minimum_core_count: + The value to assign to the minimum_core_count property of this DbSystemShapeSummary. + :type minimum_core_count: int + + :param minimum_node_count: + The value to assign to the minimum_node_count property of this DbSystemShapeSummary. + :type minimum_node_count: int + :param name: The value to assign to the name property of this DbSystemShapeSummary. :type name: str @@ -29,17 +45,29 @@ def __init__(self, **kwargs): """ self.swagger_types = { 'available_core_count': 'int', + 'core_count_increment': 'int', + 'maximum_node_count': 'int', + 'minimum_core_count': 'int', + 'minimum_node_count': 'int', 'name': 'str', 'shape': 'str' } self.attribute_map = { 'available_core_count': 'availableCoreCount', + 'core_count_increment': 'coreCountIncrement', + 'maximum_node_count': 'maximumNodeCount', + 'minimum_core_count': 'minimumCoreCount', + 'minimum_node_count': 'minimumNodeCount', 'name': 'name', 'shape': 'shape' } self._available_core_count = None + self._core_count_increment = None + self._maximum_node_count = None + self._minimum_core_count = None + self._minimum_node_count = None self._name = None self._shape = None @@ -47,7 +75,7 @@ def __init__(self, **kwargs): def available_core_count(self): """ **[Required]** Gets the available_core_count of this DbSystemShapeSummary. - The maximum number of CPU cores that can be enabled on the DB System. + The maximum number of CPU cores that can be enabled on the DB System for this shape. :return: The available_core_count of this DbSystemShapeSummary. @@ -59,7 +87,7 @@ def available_core_count(self): def available_core_count(self, available_core_count): """ Sets the available_core_count of this DbSystemShapeSummary. - The maximum number of CPU cores that can be enabled on the DB System. + The maximum number of CPU cores that can be enabled on the DB System for this shape. :param available_core_count: The available_core_count of this DbSystemShapeSummary. @@ -67,6 +95,102 @@ def available_core_count(self, available_core_count): """ self._available_core_count = available_core_count + @property + def core_count_increment(self): + """ + Gets the core_count_increment of this DbSystemShapeSummary. + The discrete number by which the CPU core count for this shape can be increased or decreased. + + + :return: The core_count_increment of this DbSystemShapeSummary. + :rtype: int + """ + return self._core_count_increment + + @core_count_increment.setter + def core_count_increment(self, core_count_increment): + """ + Sets the core_count_increment of this DbSystemShapeSummary. + The discrete number by which the CPU core count for this shape can be increased or decreased. + + + :param core_count_increment: The core_count_increment of this DbSystemShapeSummary. + :type: int + """ + self._core_count_increment = core_count_increment + + @property + def maximum_node_count(self): + """ + Gets the maximum_node_count of this DbSystemShapeSummary. + The maximum number of database nodes available for this shape. + + + :return: The maximum_node_count of this DbSystemShapeSummary. + :rtype: int + """ + return self._maximum_node_count + + @maximum_node_count.setter + def maximum_node_count(self, maximum_node_count): + """ + Sets the maximum_node_count of this DbSystemShapeSummary. + The maximum number of database nodes available for this shape. + + + :param maximum_node_count: The maximum_node_count of this DbSystemShapeSummary. + :type: int + """ + self._maximum_node_count = maximum_node_count + + @property + def minimum_core_count(self): + """ + Gets the minimum_core_count of this DbSystemShapeSummary. + The minimum number of CPU cores that can be enabled on the DB System for this shape. + + + :return: The minimum_core_count of this DbSystemShapeSummary. + :rtype: int + """ + return self._minimum_core_count + + @minimum_core_count.setter + def minimum_core_count(self, minimum_core_count): + """ + Sets the minimum_core_count of this DbSystemShapeSummary. + The minimum number of CPU cores that can be enabled on the DB System for this shape. + + + :param minimum_core_count: The minimum_core_count of this DbSystemShapeSummary. + :type: int + """ + self._minimum_core_count = minimum_core_count + + @property + def minimum_node_count(self): + """ + Gets the minimum_node_count of this DbSystemShapeSummary. + The minimum number of database nodes available for this shape. + + + :return: The minimum_node_count of this DbSystemShapeSummary. + :rtype: int + """ + return self._minimum_node_count + + @minimum_node_count.setter + def minimum_node_count(self, minimum_node_count): + """ + Sets the minimum_node_count of this DbSystemShapeSummary. + The minimum number of database nodes available for this shape. + + + :param minimum_node_count: The minimum_node_count of this DbSystemShapeSummary. + :type: int + """ + self._minimum_node_count = minimum_node_count + @property def name(self): """ diff --git a/src/oci/database/models/db_system_summary.py b/src/oci/database/models/db_system_summary.py index b6a4713d98..46fa1bbf56 100644 --- a/src/oci/database/models/db_system_summary.py +++ b/src/oci/database/models/db_system_summary.py @@ -11,7 +11,7 @@ class DbSystemSummary(object): def __init__(self, **kwargs): """ - Initializes a new DbSystemSummary object with values from values from keyword arguments. + Initializes a new DbSystemSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/database/models/db_version_summary.py b/src/oci/database/models/db_version_summary.py index 0cd9cbbd46..3ffe54d932 100644 --- a/src/oci/database/models/db_version_summary.py +++ b/src/oci/database/models/db_version_summary.py @@ -11,7 +11,7 @@ class DbVersionSummary(object): def __init__(self, **kwargs): """ - Initializes a new DbVersionSummary object with values from values from keyword arguments. + Initializes a new DbVersionSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param supports_pdb: diff --git a/src/oci/database/models/failover_data_guard_association_details.py b/src/oci/database/models/failover_data_guard_association_details.py index 586d86c457..d255da4a85 100644 --- a/src/oci/database/models/failover_data_guard_association_details.py +++ b/src/oci/database/models/failover_data_guard_association_details.py @@ -11,7 +11,7 @@ class FailoverDataGuardAssociationDetails(object): def __init__(self, **kwargs): """ - Initializes a new FailoverDataGuardAssociationDetails object with values from values from keyword arguments. + Initializes a new FailoverDataGuardAssociationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database_admin_password: diff --git a/src/oci/database/models/launch_db_system_details.py b/src/oci/database/models/launch_db_system_details.py index eff12791ff..bd58e62da3 100644 --- a/src/oci/database/models/launch_db_system_details.py +++ b/src/oci/database/models/launch_db_system_details.py @@ -11,7 +11,7 @@ class LaunchDbSystemDetails(object): def __init__(self, **kwargs): """ - Initializes a new LaunchDbSystemDetails object with values from values from keyword arguments. + Initializes a new LaunchDbSystemDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/database/models/patch.py b/src/oci/database/models/patch.py index e8b5599593..4e4069b8be 100644 --- a/src/oci/database/models/patch.py +++ b/src/oci/database/models/patch.py @@ -11,7 +11,7 @@ class Patch(object): def __init__(self, **kwargs): """ - Initializes a new Patch object with values from values from keyword arguments. + Initializes a new Patch object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param available_actions: diff --git a/src/oci/database/models/patch_details.py b/src/oci/database/models/patch_details.py index 271e6c8d77..a8818de324 100644 --- a/src/oci/database/models/patch_details.py +++ b/src/oci/database/models/patch_details.py @@ -11,7 +11,7 @@ class PatchDetails(object): def __init__(self, **kwargs): """ - Initializes a new PatchDetails object with values from values from keyword arguments. + Initializes a new PatchDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param action: diff --git a/src/oci/database/models/patch_history_entry.py b/src/oci/database/models/patch_history_entry.py index 7f52324ed6..03a0236ac5 100644 --- a/src/oci/database/models/patch_history_entry.py +++ b/src/oci/database/models/patch_history_entry.py @@ -11,7 +11,7 @@ class PatchHistoryEntry(object): def __init__(self, **kwargs): """ - Initializes a new PatchHistoryEntry object with values from values from keyword arguments. + Initializes a new PatchHistoryEntry object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param action: diff --git a/src/oci/database/models/patch_history_entry_summary.py b/src/oci/database/models/patch_history_entry_summary.py index 825a0dfbfc..2a63af15ac 100644 --- a/src/oci/database/models/patch_history_entry_summary.py +++ b/src/oci/database/models/patch_history_entry_summary.py @@ -11,7 +11,7 @@ class PatchHistoryEntrySummary(object): def __init__(self, **kwargs): """ - Initializes a new PatchHistoryEntrySummary object with values from values from keyword arguments. + Initializes a new PatchHistoryEntrySummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param action: diff --git a/src/oci/database/models/patch_summary.py b/src/oci/database/models/patch_summary.py index 3bcc2a5864..546b47ddeb 100644 --- a/src/oci/database/models/patch_summary.py +++ b/src/oci/database/models/patch_summary.py @@ -11,7 +11,7 @@ class PatchSummary(object): def __init__(self, **kwargs): """ - Initializes a new PatchSummary object with values from values from keyword arguments. + Initializes a new PatchSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param available_actions: diff --git a/src/oci/database/models/reinstate_data_guard_association_details.py b/src/oci/database/models/reinstate_data_guard_association_details.py index 5962d6b823..f4993cbefa 100644 --- a/src/oci/database/models/reinstate_data_guard_association_details.py +++ b/src/oci/database/models/reinstate_data_guard_association_details.py @@ -11,7 +11,7 @@ class ReinstateDataGuardAssociationDetails(object): def __init__(self, **kwargs): """ - Initializes a new ReinstateDataGuardAssociationDetails object with values from values from keyword arguments. + Initializes a new ReinstateDataGuardAssociationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database_admin_password: diff --git a/src/oci/database/models/restore_database_details.py b/src/oci/database/models/restore_database_details.py index 458869898a..3c5416f427 100644 --- a/src/oci/database/models/restore_database_details.py +++ b/src/oci/database/models/restore_database_details.py @@ -11,7 +11,7 @@ class RestoreDatabaseDetails(object): def __init__(self, **kwargs): """ - Initializes a new RestoreDatabaseDetails object with values from values from keyword arguments. + Initializes a new RestoreDatabaseDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database_scn: diff --git a/src/oci/database/models/switchover_data_guard_association_details.py b/src/oci/database/models/switchover_data_guard_association_details.py index 0f77b0fb0e..e15076ba8b 100644 --- a/src/oci/database/models/switchover_data_guard_association_details.py +++ b/src/oci/database/models/switchover_data_guard_association_details.py @@ -11,7 +11,7 @@ class SwitchoverDataGuardAssociationDetails(object): def __init__(self, **kwargs): """ - Initializes a new SwitchoverDataGuardAssociationDetails object with values from values from keyword arguments. + Initializes a new SwitchoverDataGuardAssociationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param database_admin_password: diff --git a/src/oci/database/models/update_database_details.py b/src/oci/database/models/update_database_details.py index 76b487525f..4079781269 100644 --- a/src/oci/database/models/update_database_details.py +++ b/src/oci/database/models/update_database_details.py @@ -11,7 +11,7 @@ class UpdateDatabaseDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDatabaseDetails object with values from values from keyword arguments. + Initializes a new UpdateDatabaseDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param db_backup_config: diff --git a/src/oci/database/models/update_db_home_details.py b/src/oci/database/models/update_db_home_details.py index b64e180d87..000b51085c 100644 --- a/src/oci/database/models/update_db_home_details.py +++ b/src/oci/database/models/update_db_home_details.py @@ -11,7 +11,7 @@ class UpdateDbHomeDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDbHomeDetails object with values from values from keyword arguments. + Initializes a new UpdateDbHomeDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param db_version: diff --git a/src/oci/database/models/update_db_system_details.py b/src/oci/database/models/update_db_system_details.py index aef2ebe3e9..cc6cbef452 100644 --- a/src/oci/database/models/update_db_system_details.py +++ b/src/oci/database/models/update_db_system_details.py @@ -11,7 +11,7 @@ class UpdateDbSystemDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDbSystemDetails object with values from values from keyword arguments. + Initializes a new UpdateDbSystemDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cpu_core_count: diff --git a/src/oci/dns/dns_client.py b/src/oci/dns/dns_client.py index fb2152a19f..613bbfac82 100644 --- a/src/oci/dns/dns_client.py +++ b/src/oci/dns/dns_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("dns", config, signer, dns_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_zone(self, create_zone_details, **kwargs): """ @@ -71,8 +72,12 @@ def create_zone(self, create_zone_details, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -159,8 +164,12 @@ def delete_domain_records(self, zone_name_or_id, domain, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -249,8 +258,12 @@ def delete_rr_set(self, zone_name_or_id, domain, rtype, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -332,8 +345,12 @@ def delete_zone(self, zone_name_or_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -469,8 +486,12 @@ def get_domain_records(self, zone_name_or_id, domain, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -575,8 +596,12 @@ def get_rr_set(self, zone_name_or_id, domain, rtype, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -658,8 +683,12 @@ def get_zone(self, zone_name_or_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -807,8 +836,12 @@ def get_zone_records(self, zone_name_or_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -954,8 +987,12 @@ def list_zones(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1043,8 +1080,12 @@ def patch_domain_records(self, zone_name_or_id, domain, patch_domain_records_det } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1140,8 +1181,12 @@ def patch_rr_set(self, zone_name_or_id, domain, rtype, patch_rr_set_details, **k } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1232,8 +1277,12 @@ def patch_zone_records(self, zone_name_or_id, patch_zone_records_details, **kwar } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1330,8 +1379,12 @@ def update_domain_records(self, zone_name_or_id, domain, update_domain_records_d } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1427,8 +1480,12 @@ def update_rr_set(self, zone_name_or_id, domain, rtype, update_rr_set_details, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1520,8 +1577,12 @@ def update_zone(self, zone_name_or_id, update_zone_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1613,8 +1674,12 @@ def update_zone_records(self, zone_name_or_id, update_zone_records_details, **kw } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/dns/models/create_zone_details.py b/src/oci/dns/models/create_zone_details.py index 5290b4b35f..fbc938cca7 100644 --- a/src/oci/dns/models/create_zone_details.py +++ b/src/oci/dns/models/create_zone_details.py @@ -11,7 +11,7 @@ class CreateZoneDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateZoneDetails object with values from values from keyword arguments. + Initializes a new CreateZoneDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/dns/models/external_master.py b/src/oci/dns/models/external_master.py index 60baf0ab5a..ffa1820bcc 100644 --- a/src/oci/dns/models/external_master.py +++ b/src/oci/dns/models/external_master.py @@ -11,7 +11,7 @@ class ExternalMaster(object): def __init__(self, **kwargs): """ - Initializes a new ExternalMaster object with values from values from keyword arguments. + Initializes a new ExternalMaster object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param address: diff --git a/src/oci/dns/models/patch_domain_records_details.py b/src/oci/dns/models/patch_domain_records_details.py index 6b5eee4d05..60171122d4 100644 --- a/src/oci/dns/models/patch_domain_records_details.py +++ b/src/oci/dns/models/patch_domain_records_details.py @@ -11,7 +11,7 @@ class PatchDomainRecordsDetails(object): def __init__(self, **kwargs): """ - Initializes a new PatchDomainRecordsDetails object with values from values from keyword arguments. + Initializes a new PatchDomainRecordsDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/patch_rr_set_details.py b/src/oci/dns/models/patch_rr_set_details.py index fee7f14d19..d4eac16d16 100644 --- a/src/oci/dns/models/patch_rr_set_details.py +++ b/src/oci/dns/models/patch_rr_set_details.py @@ -11,7 +11,7 @@ class PatchRRSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new PatchRRSetDetails object with values from values from keyword arguments. + Initializes a new PatchRRSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/patch_zone_records_details.py b/src/oci/dns/models/patch_zone_records_details.py index 316db46405..b868485fc2 100644 --- a/src/oci/dns/models/patch_zone_records_details.py +++ b/src/oci/dns/models/patch_zone_records_details.py @@ -11,7 +11,7 @@ class PatchZoneRecordsDetails(object): def __init__(self, **kwargs): """ - Initializes a new PatchZoneRecordsDetails object with values from values from keyword arguments. + Initializes a new PatchZoneRecordsDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/record.py b/src/oci/dns/models/record.py index b751bd7ec0..eb007f2b5a 100644 --- a/src/oci/dns/models/record.py +++ b/src/oci/dns/models/record.py @@ -11,7 +11,7 @@ class Record(object): def __init__(self, **kwargs): """ - Initializes a new Record object with values from values from keyword arguments. + Initializes a new Record object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param domain: diff --git a/src/oci/dns/models/record_collection.py b/src/oci/dns/models/record_collection.py index f6d0b160dd..e3d01d9c21 100644 --- a/src/oci/dns/models/record_collection.py +++ b/src/oci/dns/models/record_collection.py @@ -11,7 +11,7 @@ class RecordCollection(object): def __init__(self, **kwargs): """ - Initializes a new RecordCollection object with values from values from keyword arguments. + Initializes a new RecordCollection object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/record_details.py b/src/oci/dns/models/record_details.py index 9cf826d1c0..8410ba85ba 100644 --- a/src/oci/dns/models/record_details.py +++ b/src/oci/dns/models/record_details.py @@ -11,7 +11,7 @@ class RecordDetails(object): def __init__(self, **kwargs): """ - Initializes a new RecordDetails object with values from values from keyword arguments. + Initializes a new RecordDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param domain: diff --git a/src/oci/dns/models/record_operation.py b/src/oci/dns/models/record_operation.py index 9a73c18b0e..08e0fc340b 100644 --- a/src/oci/dns/models/record_operation.py +++ b/src/oci/dns/models/record_operation.py @@ -11,7 +11,7 @@ class RecordOperation(object): def __init__(self, **kwargs): """ - Initializes a new RecordOperation object with values from values from keyword arguments. + Initializes a new RecordOperation object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param domain: diff --git a/src/oci/dns/models/rr_set.py b/src/oci/dns/models/rr_set.py index 6a821fc947..932bf90ccb 100644 --- a/src/oci/dns/models/rr_set.py +++ b/src/oci/dns/models/rr_set.py @@ -11,7 +11,7 @@ class RRSet(object): def __init__(self, **kwargs): """ - Initializes a new RRSet object with values from values from keyword arguments. + Initializes a new RRSet object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/tsig.py b/src/oci/dns/models/tsig.py index fccaf1cbf2..7785e12237 100644 --- a/src/oci/dns/models/tsig.py +++ b/src/oci/dns/models/tsig.py @@ -11,7 +11,7 @@ class TSIG(object): def __init__(self, **kwargs): """ - Initializes a new TSIG object with values from values from keyword arguments. + Initializes a new TSIG object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/dns/models/update_domain_records_details.py b/src/oci/dns/models/update_domain_records_details.py index 4081d1e88b..d013c89351 100644 --- a/src/oci/dns/models/update_domain_records_details.py +++ b/src/oci/dns/models/update_domain_records_details.py @@ -11,7 +11,7 @@ class UpdateDomainRecordsDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDomainRecordsDetails object with values from values from keyword arguments. + Initializes a new UpdateDomainRecordsDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/update_rr_set_details.py b/src/oci/dns/models/update_rr_set_details.py index e8ef7c3dc3..4939882b69 100644 --- a/src/oci/dns/models/update_rr_set_details.py +++ b/src/oci/dns/models/update_rr_set_details.py @@ -11,7 +11,7 @@ class UpdateRRSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateRRSetDetails object with values from values from keyword arguments. + Initializes a new UpdateRRSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/update_zone_details.py b/src/oci/dns/models/update_zone_details.py index 66cd09e257..0de95ee440 100644 --- a/src/oci/dns/models/update_zone_details.py +++ b/src/oci/dns/models/update_zone_details.py @@ -11,7 +11,7 @@ class UpdateZoneDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateZoneDetails object with values from values from keyword arguments. + Initializes a new UpdateZoneDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param external_masters: diff --git a/src/oci/dns/models/update_zone_records_details.py b/src/oci/dns/models/update_zone_records_details.py index 80bbbfd30e..834b5fd357 100644 --- a/src/oci/dns/models/update_zone_records_details.py +++ b/src/oci/dns/models/update_zone_records_details.py @@ -11,7 +11,7 @@ class UpdateZoneRecordsDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateZoneRecordsDetails object with values from values from keyword arguments. + Initializes a new UpdateZoneRecordsDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param items: diff --git a/src/oci/dns/models/zone.py b/src/oci/dns/models/zone.py index 8b235b0ce4..55b3be7469 100644 --- a/src/oci/dns/models/zone.py +++ b/src/oci/dns/models/zone.py @@ -11,7 +11,7 @@ class Zone(object): def __init__(self, **kwargs): """ - Initializes a new Zone object with values from values from keyword arguments. + Initializes a new Zone object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/dns/models/zone_summary.py b/src/oci/dns/models/zone_summary.py index f78dc9dc48..3f068412f2 100644 --- a/src/oci/dns/models/zone_summary.py +++ b/src/oci/dns/models/zone_summary.py @@ -11,7 +11,7 @@ class ZoneSummary(object): def __init__(self, **kwargs): """ - Initializes a new ZoneSummary object with values from values from keyword arguments. + Initializes a new ZoneSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/email/email_client.py b/src/oci/email/email_client.py index a013866a75..b37c6148bd 100644 --- a/src/oci/email/email_client.py +++ b/src/oci/email/email_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("email", config, signer, email_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_sender(self, create_sender_details, **kwargs): """ @@ -58,8 +59,12 @@ def create_sender(self, create_sender_details, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -100,8 +105,12 @@ def create_suppression(self, create_suppression_details, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -153,8 +162,12 @@ def delete_sender(self, sender_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -204,8 +217,12 @@ def delete_suppression(self, suppression_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -254,8 +271,12 @@ def get_sender(self, sender_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -307,8 +328,12 @@ def get_suppression(self, suppression_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -418,8 +443,12 @@ def list_senders(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -541,8 +570,12 @@ def list_suppressions(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/email/models/create_sender_details.py b/src/oci/email/models/create_sender_details.py index 0c4cd1b313..8d69d073f6 100644 --- a/src/oci/email/models/create_sender_details.py +++ b/src/oci/email/models/create_sender_details.py @@ -11,7 +11,7 @@ class CreateSenderDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSenderDetails object with values from values from keyword arguments. + Initializes a new CreateSenderDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/email/models/create_suppression_details.py b/src/oci/email/models/create_suppression_details.py index c9502f8cf6..3cdb10be7d 100644 --- a/src/oci/email/models/create_suppression_details.py +++ b/src/oci/email/models/create_suppression_details.py @@ -11,7 +11,7 @@ class CreateSuppressionDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSuppressionDetails object with values from values from keyword arguments. + Initializes a new CreateSuppressionDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/email/models/sender.py b/src/oci/email/models/sender.py index b7f1b77156..896ec36b35 100644 --- a/src/oci/email/models/sender.py +++ b/src/oci/email/models/sender.py @@ -11,7 +11,7 @@ class Sender(object): def __init__(self, **kwargs): """ - Initializes a new Sender object with values from values from keyword arguments. + Initializes a new Sender object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param email_address: diff --git a/src/oci/email/models/sender_summary.py b/src/oci/email/models/sender_summary.py index 40ff2b2396..fa5fa10d08 100644 --- a/src/oci/email/models/sender_summary.py +++ b/src/oci/email/models/sender_summary.py @@ -11,7 +11,7 @@ class SenderSummary(object): def __init__(self, **kwargs): """ - Initializes a new SenderSummary object with values from values from keyword arguments. + Initializes a new SenderSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param email_address: diff --git a/src/oci/email/models/suppression.py b/src/oci/email/models/suppression.py index 911c06e2c6..2fe96ee877 100644 --- a/src/oci/email/models/suppression.py +++ b/src/oci/email/models/suppression.py @@ -11,7 +11,7 @@ class Suppression(object): def __init__(self, **kwargs): """ - Initializes a new Suppression object with values from values from keyword arguments. + Initializes a new Suppression object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param email_address: diff --git a/src/oci/email/models/suppression_summary.py b/src/oci/email/models/suppression_summary.py index 2f8098b0b4..24ebe243dd 100644 --- a/src/oci/email/models/suppression_summary.py +++ b/src/oci/email/models/suppression_summary.py @@ -11,7 +11,7 @@ class SuppressionSummary(object): def __init__(self, **kwargs): """ - Initializes a new SuppressionSummary object with values from values from keyword arguments. + Initializes a new SuppressionSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param email_address: diff --git a/src/oci/exceptions.py b/src/oci/exceptions.py index f41a98a0d2..987db5d980 100644 --- a/src/oci/exceptions.py +++ b/src/oci/exceptions.py @@ -5,22 +5,32 @@ class ServiceError(Exception): """The service returned an error response.""" - def __init__(self, status, code, headers, message): + def __init__(self, status, code, headers, message, **kwargs): self.status = status self.code = code self.headers = headers self.message = message + self.original_request = kwargs.get('original_request') + self.request_id = self._get_opc_request_id() if not message: message = "The service returned error code %s" % self.status super(ServiceError, self).__init__({ - "opc-request-id": headers.get("opc-request-id"), + "opc-request-id": self.request_id, "code": code, "message": message, "status": status }) + def _get_opc_request_id(self): + if self.headers.get("opc-request-id"): + return self.headers.get("opc-request-id") + elif self.original_request and self.original_request.header_params: + return self.original_request.header_params.get("opc-request-id") + else: + return None + class ClientError(Exception): """A client-side error occurred..""" diff --git a/src/oci/file_storage/file_storage_client.py b/src/oci/file_storage/file_storage_client.py index 0e7fdaffe0..d0a18bf15b 100644 --- a/src/oci/file_storage/file_storage_client.py +++ b/src/oci/file_storage/file_storage_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("file_storage", config, signer, file_storage_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_export(self, create_export_details, **kwargs): """ @@ -72,10 +73,14 @@ def create_export(self, create_export_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -157,10 +162,14 @@ def create_file_system(self, create_file_system_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -190,6 +199,9 @@ def create_mount_target(self, create_mount_target_details, **kwargs): client mount commands. These private IP addresses are listed in the privateIpIds property of the mount target and are highly available. Mount targets also consume additional IP addresses in their subnet. + Do not use /30 or smaller subnets for mount target creation because they + do not have sufficient available IP addresses. + Allow at least three IP addresses for each mount target. For information about access control and compartments, see `Overview of the IAM @@ -245,10 +257,14 @@ def create_mount_target(self, create_mount_target_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -303,10 +319,14 @@ def create_snapshot(self, create_snapshot_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -370,8 +390,12 @@ def delete_export(self, export_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -435,8 +459,12 @@ def delete_file_system(self, file_system_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -499,8 +527,12 @@ def delete_mount_target(self, mount_target_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -562,8 +594,12 @@ def delete_snapshot(self, snapshot_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -612,8 +648,12 @@ def get_export(self, export_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -664,8 +704,12 @@ def get_export_set(self, export_set_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -716,8 +760,12 @@ def get_file_system(self, file_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -768,8 +816,12 @@ def get_mount_target(self, mount_target_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -820,8 +872,12 @@ def get_snapshot(self, snapshot_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -948,8 +1004,12 @@ def list_export_sets(self, compartment_id, availability_domain, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1074,8 +1134,12 @@ def list_exports(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1202,8 +1266,12 @@ def list_file_systems(self, compartment_id, availability_domain, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1335,8 +1403,12 @@ def list_mount_targets(self, compartment_id, availability_domain, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1433,8 +1505,12 @@ def list_snapshots(self, file_system_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1501,8 +1577,12 @@ def update_export_set(self, export_set_id, update_export_set_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1572,8 +1652,12 @@ def update_file_system(self, file_system_id, update_file_system_details, **kwarg } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1642,8 +1726,12 @@ def update_mount_target(self, mount_target_id, update_mount_target_details, **kw } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/file_storage/models/create_export_details.py b/src/oci/file_storage/models/create_export_details.py index 06910a6e88..19b1bb4981 100644 --- a/src/oci/file_storage/models/create_export_details.py +++ b/src/oci/file_storage/models/create_export_details.py @@ -11,7 +11,7 @@ class CreateExportDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateExportDetails object with values from values from keyword arguments. + Initializes a new CreateExportDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param export_set_id: diff --git a/src/oci/file_storage/models/create_file_system_details.py b/src/oci/file_storage/models/create_file_system_details.py index 2b5fc035d8..4c99b8b47c 100644 --- a/src/oci/file_storage/models/create_file_system_details.py +++ b/src/oci/file_storage/models/create_file_system_details.py @@ -11,7 +11,7 @@ class CreateFileSystemDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateFileSystemDetails object with values from values from keyword arguments. + Initializes a new CreateFileSystemDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/create_mount_target_details.py b/src/oci/file_storage/models/create_mount_target_details.py index 7aed1e17f5..6697e4541e 100644 --- a/src/oci/file_storage/models/create_mount_target_details.py +++ b/src/oci/file_storage/models/create_mount_target_details.py @@ -11,7 +11,7 @@ class CreateMountTargetDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateMountTargetDetails object with values from values from keyword arguments. + Initializes a new CreateMountTargetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/create_snapshot_details.py b/src/oci/file_storage/models/create_snapshot_details.py index 4a4a29c1f0..1a8f97cd8a 100644 --- a/src/oci/file_storage/models/create_snapshot_details.py +++ b/src/oci/file_storage/models/create_snapshot_details.py @@ -11,7 +11,7 @@ class CreateSnapshotDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSnapshotDetails object with values from values from keyword arguments. + Initializes a new CreateSnapshotDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param file_system_id: diff --git a/src/oci/file_storage/models/export.py b/src/oci/file_storage/models/export.py index 03e964f9fd..ae680ee3fe 100644 --- a/src/oci/file_storage/models/export.py +++ b/src/oci/file_storage/models/export.py @@ -11,7 +11,7 @@ class Export(object): def __init__(self, **kwargs): """ - Initializes a new Export object with values from values from keyword arguments. + Initializes a new Export object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param export_set_id: diff --git a/src/oci/file_storage/models/export_set.py b/src/oci/file_storage/models/export_set.py index 753413288d..6b64fbf78c 100644 --- a/src/oci/file_storage/models/export_set.py +++ b/src/oci/file_storage/models/export_set.py @@ -11,7 +11,7 @@ class ExportSet(object): def __init__(self, **kwargs): """ - Initializes a new ExportSet object with values from values from keyword arguments. + Initializes a new ExportSet object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/export_set_summary.py b/src/oci/file_storage/models/export_set_summary.py index cd337098bb..c40f2d52ea 100644 --- a/src/oci/file_storage/models/export_set_summary.py +++ b/src/oci/file_storage/models/export_set_summary.py @@ -11,7 +11,7 @@ class ExportSetSummary(object): def __init__(self, **kwargs): """ - Initializes a new ExportSetSummary object with values from values from keyword arguments. + Initializes a new ExportSetSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/export_summary.py b/src/oci/file_storage/models/export_summary.py index 97b4d06fb9..6b02d03bc7 100644 --- a/src/oci/file_storage/models/export_summary.py +++ b/src/oci/file_storage/models/export_summary.py @@ -11,7 +11,7 @@ class ExportSummary(object): def __init__(self, **kwargs): """ - Initializes a new ExportSummary object with values from values from keyword arguments. + Initializes a new ExportSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param export_set_id: diff --git a/src/oci/file_storage/models/file_system.py b/src/oci/file_storage/models/file_system.py index 2af42ddc4d..23c9609065 100644 --- a/src/oci/file_storage/models/file_system.py +++ b/src/oci/file_storage/models/file_system.py @@ -11,7 +11,7 @@ class FileSystem(object): def __init__(self, **kwargs): """ - Initializes a new FileSystem object with values from values from keyword arguments. + Initializes a new FileSystem object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/file_system_summary.py b/src/oci/file_storage/models/file_system_summary.py index 954514d020..c9bd763f6e 100644 --- a/src/oci/file_storage/models/file_system_summary.py +++ b/src/oci/file_storage/models/file_system_summary.py @@ -11,7 +11,7 @@ class FileSystemSummary(object): def __init__(self, **kwargs): """ - Initializes a new FileSystemSummary object with values from values from keyword arguments. + Initializes a new FileSystemSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/mount_target.py b/src/oci/file_storage/models/mount_target.py index dbfd5f6fa0..505fb213cc 100644 --- a/src/oci/file_storage/models/mount_target.py +++ b/src/oci/file_storage/models/mount_target.py @@ -11,7 +11,7 @@ class MountTarget(object): def __init__(self, **kwargs): """ - Initializes a new MountTarget object with values from values from keyword arguments. + Initializes a new MountTarget object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/mount_target_summary.py b/src/oci/file_storage/models/mount_target_summary.py index a47128d427..083bce7d7f 100644 --- a/src/oci/file_storage/models/mount_target_summary.py +++ b/src/oci/file_storage/models/mount_target_summary.py @@ -11,7 +11,7 @@ class MountTargetSummary(object): def __init__(self, **kwargs): """ - Initializes a new MountTargetSummary object with values from values from keyword arguments. + Initializes a new MountTargetSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param availability_domain: diff --git a/src/oci/file_storage/models/snapshot.py b/src/oci/file_storage/models/snapshot.py index f6400221e7..83ef9834b3 100644 --- a/src/oci/file_storage/models/snapshot.py +++ b/src/oci/file_storage/models/snapshot.py @@ -11,7 +11,7 @@ class Snapshot(object): def __init__(self, **kwargs): """ - Initializes a new Snapshot object with values from values from keyword arguments. + Initializes a new Snapshot object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param file_system_id: diff --git a/src/oci/file_storage/models/snapshot_summary.py b/src/oci/file_storage/models/snapshot_summary.py index af87446cb3..ef93f21648 100644 --- a/src/oci/file_storage/models/snapshot_summary.py +++ b/src/oci/file_storage/models/snapshot_summary.py @@ -11,7 +11,7 @@ class SnapshotSummary(object): def __init__(self, **kwargs): """ - Initializes a new SnapshotSummary object with values from values from keyword arguments. + Initializes a new SnapshotSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param file_system_id: diff --git a/src/oci/file_storage/models/update_export_set_details.py b/src/oci/file_storage/models/update_export_set_details.py index 79ee7e8e37..fb78b70f59 100644 --- a/src/oci/file_storage/models/update_export_set_details.py +++ b/src/oci/file_storage/models/update_export_set_details.py @@ -11,7 +11,7 @@ class UpdateExportSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateExportSetDetails object with values from values from keyword arguments. + Initializes a new UpdateExportSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/file_storage/models/update_file_system_details.py b/src/oci/file_storage/models/update_file_system_details.py index 4e54dc2db7..5dd2a94c17 100644 --- a/src/oci/file_storage/models/update_file_system_details.py +++ b/src/oci/file_storage/models/update_file_system_details.py @@ -11,7 +11,7 @@ class UpdateFileSystemDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateFileSystemDetails object with values from values from keyword arguments. + Initializes a new UpdateFileSystemDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/file_storage/models/update_mount_target_details.py b/src/oci/file_storage/models/update_mount_target_details.py index d8a2caf5cf..7f4c156549 100644 --- a/src/oci/file_storage/models/update_mount_target_details.py +++ b/src/oci/file_storage/models/update_mount_target_details.py @@ -11,7 +11,7 @@ class UpdateMountTargetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateMountTargetDetails object with values from values from keyword arguments. + Initializes a new UpdateMountTargetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/identity/identity_client.py b/src/oci/identity/identity_client.py index 1faa4858ff..89b1aa69ad 100644 --- a/src/oci/identity/identity_client.py +++ b/src/oci/identity/identity_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("identity", config, signer, identity_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def add_user_to_group(self, add_user_to_group_details, **kwargs): """ @@ -74,10 +75,14 @@ def add_user_to_group(self, add_user_to_group_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -152,10 +157,14 @@ def create_compartment(self, create_compartment_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -234,10 +243,14 @@ def create_customer_secret_key(self, create_customer_secret_key_details, user_id } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -313,10 +326,14 @@ def create_dynamic_group(self, create_dynamic_group_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -393,10 +410,14 @@ def create_group(self, create_group_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -470,10 +491,14 @@ def create_identity_provider(self, create_identity_provider_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -541,10 +566,14 @@ def create_idp_group_mapping(self, create_idp_group_mapping_details, identity_pr } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -622,10 +651,14 @@ def create_or_reset_ui_password(self, user_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -699,10 +732,14 @@ def create_policy(self, create_policy_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -769,10 +806,14 @@ def create_region_subscription(self, create_region_subscription_details, tenancy } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -844,10 +885,14 @@ def create_smtp_credential(self, create_smtp_credential_details, user_id, **kwar } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -927,10 +972,14 @@ def create_swift_password(self, create_swift_password_details, user_id, **kwargs } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1010,10 +1059,14 @@ def create_tag(self, tag_namespace_id, create_tag_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1087,10 +1140,14 @@ def create_tag_namespace(self, create_tag_namespace_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1182,10 +1239,14 @@ def create_user(self, create_user_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1256,8 +1317,12 @@ def delete_api_key(self, user_id, fingerprint, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1321,8 +1386,12 @@ def delete_customer_secret_key(self, user_id, customer_secret_key_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1382,8 +1451,12 @@ def delete_dynamic_group(self, dynamic_group_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1443,8 +1516,12 @@ def delete_group(self, group_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1505,8 +1582,12 @@ def delete_identity_provider(self, identity_provider_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1570,8 +1651,12 @@ def delete_idp_group_mapping(self, identity_provider_id, mapping_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1631,8 +1716,12 @@ def delete_policy(self, policy_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1696,8 +1785,12 @@ def delete_smtp_credential(self, user_id, smtp_credential_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1761,8 +1854,12 @@ def delete_swift_password(self, user_id, swift_password_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1822,8 +1919,12 @@ def delete_user(self, user_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1879,8 +1980,12 @@ def get_compartment(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1931,8 +2036,12 @@ def get_dynamic_group(self, dynamic_group_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1987,8 +2096,12 @@ def get_group(self, group_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2039,8 +2152,12 @@ def get_identity_provider(self, identity_provider_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2095,8 +2212,12 @@ def get_idp_group_mapping(self, identity_provider_id, mapping_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2147,8 +2268,12 @@ def get_policy(self, policy_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2203,8 +2328,12 @@ def get_tag(self, tag_namespace_id, tag_name, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2255,8 +2384,12 @@ def get_tag_namespace(self, tag_namespace_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2307,8 +2440,12 @@ def get_tenancy(self, tenancy_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2359,8 +2496,12 @@ def get_user(self, user_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2411,8 +2552,12 @@ def get_user_group_membership(self, user_group_membership_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2466,8 +2611,12 @@ def list_api_keys(self, user_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2517,8 +2666,12 @@ def list_availability_domains(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2581,8 +2734,12 @@ def list_compartments(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2634,8 +2791,12 @@ def list_customer_secret_keys(self, user_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2698,8 +2859,12 @@ def list_dynamic_groups(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2762,8 +2927,12 @@ def list_groups(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2833,8 +3002,12 @@ def list_identity_providers(self, protocol, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2902,8 +3075,12 @@ def list_idp_group_mappings(self, identity_provider_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2970,8 +3147,12 @@ def list_policies(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3022,8 +3203,12 @@ def list_region_subscriptions(self, tenancy_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3061,8 +3246,12 @@ def list_regions(self, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3112,8 +3301,12 @@ def list_smtp_credentials(self, user_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3165,8 +3358,12 @@ def list_swift_passwords(self, user_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3231,8 +3428,12 @@ def list_tag_namespaces(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3300,8 +3501,12 @@ def list_tags(self, tag_namespace_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3383,8 +3588,12 @@ def list_user_group_memberships(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3447,8 +3656,12 @@ def list_users(self, compartment_id, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3510,8 +3723,12 @@ def remove_user_from_group(self, user_group_membership_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3574,8 +3791,12 @@ def update_compartment(self, compartment_id, update_compartment_details, **kwarg } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3646,8 +3867,12 @@ def update_customer_secret_key(self, user_id, customer_secret_key_id, update_cus } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3714,8 +3939,12 @@ def update_dynamic_group(self, dynamic_group_id, update_dynamic_group_details, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3782,8 +4011,12 @@ def update_group(self, group_id, update_group_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3850,8 +4083,12 @@ def update_identity_provider(self, identity_provider_id, update_identity_provide } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3922,8 +4159,12 @@ def update_idp_group_mapping(self, identity_provider_id, mapping_id, update_idp_ } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -3992,8 +4233,12 @@ def update_policy(self, policy_id, update_policy_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4064,8 +4309,12 @@ def update_smtp_credential(self, user_id, smtp_credential_id, update_smtp_creden } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4136,8 +4385,12 @@ def update_swift_password(self, user_id, swift_password_id, update_swift_passwor } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4197,8 +4450,12 @@ def update_tag(self, tag_namespace_id, tag_name, update_tag_details, **kwargs): "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4264,8 +4521,12 @@ def update_tag_namespace(self, tag_namespace_id, update_tag_namespace_details, * "content-type": "application/json" } + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4332,8 +4593,12 @@ def update_user(self, user_id, update_user_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4400,8 +4665,12 @@ def update_user_state(self, user_id, update_state_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -4484,10 +4753,14 @@ def upload_api_key(self, user_id, create_api_key_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/identity/models/add_user_to_group_details.py b/src/oci/identity/models/add_user_to_group_details.py index 9c0a4a9e9b..96f4c75fd1 100644 --- a/src/oci/identity/models/add_user_to_group_details.py +++ b/src/oci/identity/models/add_user_to_group_details.py @@ -11,7 +11,7 @@ class AddUserToGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new AddUserToGroupDetails object with values from values from keyword arguments. + Initializes a new AddUserToGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param user_id: diff --git a/src/oci/identity/models/api_key.py b/src/oci/identity/models/api_key.py index bf5f8d3ef6..7a37c4301f 100644 --- a/src/oci/identity/models/api_key.py +++ b/src/oci/identity/models/api_key.py @@ -11,7 +11,7 @@ class ApiKey(object): def __init__(self, **kwargs): """ - Initializes a new ApiKey object with values from values from keyword arguments. + Initializes a new ApiKey object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param key_id: diff --git a/src/oci/identity/models/availability_domain.py b/src/oci/identity/models/availability_domain.py index 6391106081..aaaed62aee 100644 --- a/src/oci/identity/models/availability_domain.py +++ b/src/oci/identity/models/availability_domain.py @@ -11,7 +11,7 @@ class AvailabilityDomain(object): def __init__(self, **kwargs): """ - Initializes a new AvailabilityDomain object with values from values from keyword arguments. + Initializes a new AvailabilityDomain object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/identity/models/compartment.py b/src/oci/identity/models/compartment.py index 61489e26e3..7780325250 100644 --- a/src/oci/identity/models/compartment.py +++ b/src/oci/identity/models/compartment.py @@ -11,7 +11,7 @@ class Compartment(object): def __init__(self, **kwargs): """ - Initializes a new Compartment object with values from values from keyword arguments. + Initializes a new Compartment object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/create_api_key_details.py b/src/oci/identity/models/create_api_key_details.py index f97a92de53..3fb3ae2c6e 100644 --- a/src/oci/identity/models/create_api_key_details.py +++ b/src/oci/identity/models/create_api_key_details.py @@ -11,7 +11,7 @@ class CreateApiKeyDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateApiKeyDetails object with values from values from keyword arguments. + Initializes a new CreateApiKeyDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param key: diff --git a/src/oci/identity/models/create_compartment_details.py b/src/oci/identity/models/create_compartment_details.py index 4535505249..b591abe21c 100644 --- a/src/oci/identity/models/create_compartment_details.py +++ b/src/oci/identity/models/create_compartment_details.py @@ -11,7 +11,7 @@ class CreateCompartmentDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCompartmentDetails object with values from values from keyword arguments. + Initializes a new CreateCompartmentDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/create_customer_secret_key_details.py b/src/oci/identity/models/create_customer_secret_key_details.py index dbb03f1fae..564de35dfe 100644 --- a/src/oci/identity/models/create_customer_secret_key_details.py +++ b/src/oci/identity/models/create_customer_secret_key_details.py @@ -11,7 +11,7 @@ class CreateCustomerSecretKeyDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCustomerSecretKeyDetails object with values from values from keyword arguments. + Initializes a new CreateCustomerSecretKeyDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/identity/models/create_dynamic_group_details.py b/src/oci/identity/models/create_dynamic_group_details.py index 311c7ce7fa..929fa35bb4 100644 --- a/src/oci/identity/models/create_dynamic_group_details.py +++ b/src/oci/identity/models/create_dynamic_group_details.py @@ -11,7 +11,7 @@ class CreateDynamicGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateDynamicGroupDetails object with values from values from keyword arguments. + Initializes a new CreateDynamicGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/create_group_details.py b/src/oci/identity/models/create_group_details.py index db7074a795..2f562dc3a4 100644 --- a/src/oci/identity/models/create_group_details.py +++ b/src/oci/identity/models/create_group_details.py @@ -11,7 +11,7 @@ class CreateGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateGroupDetails object with values from values from keyword arguments. + Initializes a new CreateGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/create_identity_provider_details.py b/src/oci/identity/models/create_identity_provider_details.py index 200243b2d1..330bbf243e 100644 --- a/src/oci/identity/models/create_identity_provider_details.py +++ b/src/oci/identity/models/create_identity_provider_details.py @@ -11,7 +11,7 @@ class CreateIdentityProviderDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateIdentityProviderDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new CreateIdentityProviderDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.identity.models.CreateSaml2IdentityProviderDetails` diff --git a/src/oci/identity/models/create_idp_group_mapping_details.py b/src/oci/identity/models/create_idp_group_mapping_details.py index 44aa9b52a6..438c9aadb3 100644 --- a/src/oci/identity/models/create_idp_group_mapping_details.py +++ b/src/oci/identity/models/create_idp_group_mapping_details.py @@ -11,7 +11,7 @@ class CreateIdpGroupMappingDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateIdpGroupMappingDetails object with values from values from keyword arguments. + Initializes a new CreateIdpGroupMappingDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param idp_group_name: diff --git a/src/oci/identity/models/create_policy_details.py b/src/oci/identity/models/create_policy_details.py index d9c80be1b2..0d703d9fa2 100644 --- a/src/oci/identity/models/create_policy_details.py +++ b/src/oci/identity/models/create_policy_details.py @@ -11,7 +11,7 @@ class CreatePolicyDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreatePolicyDetails object with values from values from keyword arguments. + Initializes a new CreatePolicyDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/create_region_subscription_details.py b/src/oci/identity/models/create_region_subscription_details.py index 4f849dee9a..3d38e69f3e 100644 --- a/src/oci/identity/models/create_region_subscription_details.py +++ b/src/oci/identity/models/create_region_subscription_details.py @@ -11,7 +11,7 @@ class CreateRegionSubscriptionDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateRegionSubscriptionDetails object with values from values from keyword arguments. + Initializes a new CreateRegionSubscriptionDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param region_key: @@ -39,6 +39,7 @@ def region_key(self): - `PHX` - `IAD` - `FRA` + - `LHR` Example: `PHX` @@ -58,6 +59,7 @@ def region_key(self, region_key): - `PHX` - `IAD` - `FRA` + - `LHR` Example: `PHX` diff --git a/src/oci/identity/models/create_saml2_identity_provider_details.py b/src/oci/identity/models/create_saml2_identity_provider_details.py index 8b9a85b96f..558ddea9dd 100644 --- a/src/oci/identity/models/create_saml2_identity_provider_details.py +++ b/src/oci/identity/models/create_saml2_identity_provider_details.py @@ -11,7 +11,7 @@ class CreateSaml2IdentityProviderDetails(CreateIdentityProviderDetails): def __init__(self, **kwargs): """ - Initializes a new CreateSaml2IdentityProviderDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.CreateSaml2IdentityProviderDetails.protocol` attribute + Initializes a new CreateSaml2IdentityProviderDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.CreateSaml2IdentityProviderDetails.protocol` attribute of this class is ``SAML2`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/identity/models/create_smtp_credential_details.py b/src/oci/identity/models/create_smtp_credential_details.py index fb56a5aad1..fd7f2d2649 100644 --- a/src/oci/identity/models/create_smtp_credential_details.py +++ b/src/oci/identity/models/create_smtp_credential_details.py @@ -11,7 +11,7 @@ class CreateSmtpCredentialDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSmtpCredentialDetails object with values from values from keyword arguments. + Initializes a new CreateSmtpCredentialDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/create_swift_password_details.py b/src/oci/identity/models/create_swift_password_details.py index f6fa1608c7..36eff1aa32 100644 --- a/src/oci/identity/models/create_swift_password_details.py +++ b/src/oci/identity/models/create_swift_password_details.py @@ -11,7 +11,7 @@ class CreateSwiftPasswordDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateSwiftPasswordDetails object with values from values from keyword arguments. + Initializes a new CreateSwiftPasswordDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/create_tag_details.py b/src/oci/identity/models/create_tag_details.py index 4953720e2e..b946e2e41b 100644 --- a/src/oci/identity/models/create_tag_details.py +++ b/src/oci/identity/models/create_tag_details.py @@ -11,7 +11,7 @@ class CreateTagDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateTagDetails object with values from values from keyword arguments. + Initializes a new CreateTagDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/identity/models/create_tag_namespace_details.py b/src/oci/identity/models/create_tag_namespace_details.py index 0260ebba43..349a5cd666 100644 --- a/src/oci/identity/models/create_tag_namespace_details.py +++ b/src/oci/identity/models/create_tag_namespace_details.py @@ -11,7 +11,7 @@ class CreateTagNamespaceDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateTagNamespaceDetails object with values from values from keyword arguments. + Initializes a new CreateTagNamespaceDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/create_user_details.py b/src/oci/identity/models/create_user_details.py index 371983fd8a..0d9cdb55ee 100644 --- a/src/oci/identity/models/create_user_details.py +++ b/src/oci/identity/models/create_user_details.py @@ -11,7 +11,7 @@ class CreateUserDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateUserDetails object with values from values from keyword arguments. + Initializes a new CreateUserDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/customer_secret_key.py b/src/oci/identity/models/customer_secret_key.py index 7990b206fc..9a70c8d546 100644 --- a/src/oci/identity/models/customer_secret_key.py +++ b/src/oci/identity/models/customer_secret_key.py @@ -11,7 +11,7 @@ class CustomerSecretKey(object): def __init__(self, **kwargs): """ - Initializes a new CustomerSecretKey object with values from values from keyword arguments. + Initializes a new CustomerSecretKey object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param key: diff --git a/src/oci/identity/models/customer_secret_key_summary.py b/src/oci/identity/models/customer_secret_key_summary.py index fb8d6f5172..f22d2ebb99 100644 --- a/src/oci/identity/models/customer_secret_key_summary.py +++ b/src/oci/identity/models/customer_secret_key_summary.py @@ -11,7 +11,7 @@ class CustomerSecretKeySummary(object): def __init__(self, **kwargs): """ - Initializes a new CustomerSecretKeySummary object with values from values from keyword arguments. + Initializes a new CustomerSecretKeySummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/dynamic_group.py b/src/oci/identity/models/dynamic_group.py index 93f8a99636..67bc0847f6 100644 --- a/src/oci/identity/models/dynamic_group.py +++ b/src/oci/identity/models/dynamic_group.py @@ -11,7 +11,7 @@ class DynamicGroup(object): def __init__(self, **kwargs): """ - Initializes a new DynamicGroup object with values from values from keyword arguments. + Initializes a new DynamicGroup object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/group.py b/src/oci/identity/models/group.py index f4a70a9359..4dbfe34d7e 100644 --- a/src/oci/identity/models/group.py +++ b/src/oci/identity/models/group.py @@ -11,7 +11,7 @@ class Group(object): def __init__(self, **kwargs): """ - Initializes a new Group object with values from values from keyword arguments. + Initializes a new Group object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/identity_provider.py b/src/oci/identity/models/identity_provider.py index d1e5d9940a..3a58b2ed34 100644 --- a/src/oci/identity/models/identity_provider.py +++ b/src/oci/identity/models/identity_provider.py @@ -11,7 +11,7 @@ class IdentityProvider(object): def __init__(self, **kwargs): """ - Initializes a new IdentityProvider object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new IdentityProvider object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.identity.models.Saml2IdentityProvider` diff --git a/src/oci/identity/models/idp_group_mapping.py b/src/oci/identity/models/idp_group_mapping.py index 76297793fe..9da2551865 100644 --- a/src/oci/identity/models/idp_group_mapping.py +++ b/src/oci/identity/models/idp_group_mapping.py @@ -11,7 +11,7 @@ class IdpGroupMapping(object): def __init__(self, **kwargs): """ - Initializes a new IdpGroupMapping object with values from values from keyword arguments. + Initializes a new IdpGroupMapping object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/policy.py b/src/oci/identity/models/policy.py index 831d61d9c1..abeadc8e95 100644 --- a/src/oci/identity/models/policy.py +++ b/src/oci/identity/models/policy.py @@ -11,7 +11,7 @@ class Policy(object): def __init__(self, **kwargs): """ - Initializes a new Policy object with values from values from keyword arguments. + Initializes a new Policy object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/region.py b/src/oci/identity/models/region.py index 30801eefae..0c823aec47 100644 --- a/src/oci/identity/models/region.py +++ b/src/oci/identity/models/region.py @@ -11,7 +11,7 @@ class Region(object): def __init__(self, **kwargs): """ - Initializes a new Region object with values from values from keyword arguments. + Initializes a new Region object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param key: @@ -46,6 +46,7 @@ def key(self): - `PHX` - `IAD` - `FRA` + - `LHR` :return: The key of this Region. @@ -63,6 +64,7 @@ def key(self, key): - `PHX` - `IAD` - `FRA` + - `LHR` :param key: The key of this Region. @@ -80,6 +82,7 @@ def name(self): - `us-phoenix-1` - `us-ashburn-1` - `eu-frankfurt-1` + - `uk-london-1` :return: The name of this Region. @@ -97,6 +100,7 @@ def name(self, name): - `us-phoenix-1` - `us-ashburn-1` - `eu-frankfurt-1` + - `uk-london-1` :param name: The name of this Region. diff --git a/src/oci/identity/models/region_subscription.py b/src/oci/identity/models/region_subscription.py index 3d6fd28b0c..11d6de90f5 100644 --- a/src/oci/identity/models/region_subscription.py +++ b/src/oci/identity/models/region_subscription.py @@ -11,7 +11,7 @@ class RegionSubscription(object): def __init__(self, **kwargs): """ - Initializes a new RegionSubscription object with values from values from keyword arguments. + Initializes a new RegionSubscription object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param region_key: @@ -62,6 +62,7 @@ def region_key(self): - `PHX` - `IAD` - `FRA` + - `LHR` :return: The region_key of this RegionSubscription. @@ -79,6 +80,7 @@ def region_key(self, region_key): - `PHX` - `IAD` - `FRA` + - `LHR` :param region_key: The region_key of this RegionSubscription. @@ -96,6 +98,7 @@ def region_name(self): - `us-phoenix-1` - `us-ashburn-1` - `eu-frankurt-1` + - `uk-london-1` :return: The region_name of this RegionSubscription. @@ -113,6 +116,7 @@ def region_name(self, region_name): - `us-phoenix-1` - `us-ashburn-1` - `eu-frankurt-1` + - `uk-london-1` :param region_name: The region_name of this RegionSubscription. diff --git a/src/oci/identity/models/saml2_identity_provider.py b/src/oci/identity/models/saml2_identity_provider.py index 644e3afb0b..0bb92e177d 100644 --- a/src/oci/identity/models/saml2_identity_provider.py +++ b/src/oci/identity/models/saml2_identity_provider.py @@ -11,7 +11,7 @@ class Saml2IdentityProvider(IdentityProvider): def __init__(self, **kwargs): """ - Initializes a new Saml2IdentityProvider object with values from values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.Saml2IdentityProvider.protocol` attribute + Initializes a new Saml2IdentityProvider object with values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.Saml2IdentityProvider.protocol` attribute of this class is ``SAML2`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/identity/models/smtp_credential.py b/src/oci/identity/models/smtp_credential.py index ed63adf217..713d8815d1 100644 --- a/src/oci/identity/models/smtp_credential.py +++ b/src/oci/identity/models/smtp_credential.py @@ -11,7 +11,7 @@ class SmtpCredential(object): def __init__(self, **kwargs): """ - Initializes a new SmtpCredential object with values from values from keyword arguments. + Initializes a new SmtpCredential object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param username: diff --git a/src/oci/identity/models/smtp_credential_summary.py b/src/oci/identity/models/smtp_credential_summary.py index 08c35c3271..bedebfdac7 100644 --- a/src/oci/identity/models/smtp_credential_summary.py +++ b/src/oci/identity/models/smtp_credential_summary.py @@ -11,7 +11,7 @@ class SmtpCredentialSummary(object): def __init__(self, **kwargs): """ - Initializes a new SmtpCredentialSummary object with values from values from keyword arguments. + Initializes a new SmtpCredentialSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param username: diff --git a/src/oci/identity/models/swift_password.py b/src/oci/identity/models/swift_password.py index 19c8098ac5..c1fd463df7 100644 --- a/src/oci/identity/models/swift_password.py +++ b/src/oci/identity/models/swift_password.py @@ -11,7 +11,7 @@ class SwiftPassword(object): def __init__(self, **kwargs): """ - Initializes a new SwiftPassword object with values from values from keyword arguments. + Initializes a new SwiftPassword object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param password: diff --git a/src/oci/identity/models/tag.py b/src/oci/identity/models/tag.py index 9d691c000d..3145a8bddb 100644 --- a/src/oci/identity/models/tag.py +++ b/src/oci/identity/models/tag.py @@ -11,7 +11,7 @@ class Tag(object): def __init__(self, **kwargs): """ - Initializes a new Tag object with values from values from keyword arguments. + Initializes a new Tag object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/tag_namespace.py b/src/oci/identity/models/tag_namespace.py index 64c559b2e9..39f8d0690b 100644 --- a/src/oci/identity/models/tag_namespace.py +++ b/src/oci/identity/models/tag_namespace.py @@ -11,7 +11,7 @@ class TagNamespace(object): def __init__(self, **kwargs): """ - Initializes a new TagNamespace object with values from values from keyword arguments. + Initializes a new TagNamespace object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/tag_namespace_summary.py b/src/oci/identity/models/tag_namespace_summary.py index 55bed481a0..952f3fa0db 100644 --- a/src/oci/identity/models/tag_namespace_summary.py +++ b/src/oci/identity/models/tag_namespace_summary.py @@ -11,7 +11,7 @@ class TagNamespaceSummary(object): def __init__(self, **kwargs): """ - Initializes a new TagNamespaceSummary object with values from values from keyword arguments. + Initializes a new TagNamespaceSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/tag_summary.py b/src/oci/identity/models/tag_summary.py index 8ce19875b2..6b926b49ee 100644 --- a/src/oci/identity/models/tag_summary.py +++ b/src/oci/identity/models/tag_summary.py @@ -11,7 +11,7 @@ class TagSummary(object): def __init__(self, **kwargs): """ - Initializes a new TagSummary object with values from values from keyword arguments. + Initializes a new TagSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param compartment_id: diff --git a/src/oci/identity/models/tenancy.py b/src/oci/identity/models/tenancy.py index 4eac72bbc4..e6239cf0fe 100644 --- a/src/oci/identity/models/tenancy.py +++ b/src/oci/identity/models/tenancy.py @@ -11,7 +11,7 @@ class Tenancy(object): def __init__(self, **kwargs): """ - Initializes a new Tenancy object with values from values from keyword arguments. + Initializes a new Tenancy object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: @@ -140,12 +140,16 @@ def description(self, description): def home_region_key(self): """ Gets the home_region_key of this Tenancy. - The region key for the tenancy's home region. + The region key for the tenancy's home region. For more information about regions, see + `Regions and Availability Domains`__. Allowed values are: - `IAD` - `PHX` - `FRA` + - `LHR` + + __ https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/regions.htm :return: The home_region_key of this Tenancy. @@ -157,12 +161,16 @@ def home_region_key(self): def home_region_key(self, home_region_key): """ Sets the home_region_key of this Tenancy. - The region key for the tenancy's home region. + The region key for the tenancy's home region. For more information about regions, see + `Regions and Availability Domains`__. Allowed values are: - `IAD` - `PHX` - `FRA` + - `LHR` + + __ https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/regions.htm :param home_region_key: The home_region_key of this Tenancy. diff --git a/src/oci/identity/models/ui_password.py b/src/oci/identity/models/ui_password.py index e9bc38ec91..9b5c54319c 100644 --- a/src/oci/identity/models/ui_password.py +++ b/src/oci/identity/models/ui_password.py @@ -11,7 +11,7 @@ class UIPassword(object): def __init__(self, **kwargs): """ - Initializes a new UIPassword object with values from values from keyword arguments. + Initializes a new UIPassword object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param password: diff --git a/src/oci/identity/models/update_compartment_details.py b/src/oci/identity/models/update_compartment_details.py index 3b89dfe248..6405ead165 100644 --- a/src/oci/identity/models/update_compartment_details.py +++ b/src/oci/identity/models/update_compartment_details.py @@ -11,7 +11,7 @@ class UpdateCompartmentDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateCompartmentDetails object with values from values from keyword arguments. + Initializes a new UpdateCompartmentDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_customer_secret_key_details.py b/src/oci/identity/models/update_customer_secret_key_details.py index 10551d4163..2a0084a6e4 100644 --- a/src/oci/identity/models/update_customer_secret_key_details.py +++ b/src/oci/identity/models/update_customer_secret_key_details.py @@ -11,7 +11,7 @@ class UpdateCustomerSecretKeyDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateCustomerSecretKeyDetails object with values from values from keyword arguments. + Initializes a new UpdateCustomerSecretKeyDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/identity/models/update_dynamic_group_details.py b/src/oci/identity/models/update_dynamic_group_details.py index f23aa0c111..6b1c4c0bfb 100644 --- a/src/oci/identity/models/update_dynamic_group_details.py +++ b/src/oci/identity/models/update_dynamic_group_details.py @@ -11,7 +11,7 @@ class UpdateDynamicGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateDynamicGroupDetails object with values from values from keyword arguments. + Initializes a new UpdateDynamicGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_group_details.py b/src/oci/identity/models/update_group_details.py index 027432ddc0..4c3ab0f2e2 100644 --- a/src/oci/identity/models/update_group_details.py +++ b/src/oci/identity/models/update_group_details.py @@ -11,7 +11,7 @@ class UpdateGroupDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateGroupDetails object with values from values from keyword arguments. + Initializes a new UpdateGroupDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_identity_provider_details.py b/src/oci/identity/models/update_identity_provider_details.py index 972400c32d..8140a9e29d 100644 --- a/src/oci/identity/models/update_identity_provider_details.py +++ b/src/oci/identity/models/update_identity_provider_details.py @@ -11,7 +11,7 @@ class UpdateIdentityProviderDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateIdentityProviderDetails object with values from values from keyword arguments. This class has the following subclasses and if you are using this class as input + Initializes a new UpdateIdentityProviderDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.identity.models.UpdateSaml2IdentityProviderDetails` diff --git a/src/oci/identity/models/update_idp_group_mapping_details.py b/src/oci/identity/models/update_idp_group_mapping_details.py index edf43f2c40..917e55274a 100644 --- a/src/oci/identity/models/update_idp_group_mapping_details.py +++ b/src/oci/identity/models/update_idp_group_mapping_details.py @@ -11,7 +11,7 @@ class UpdateIdpGroupMappingDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateIdpGroupMappingDetails object with values from values from keyword arguments. + Initializes a new UpdateIdpGroupMappingDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param idp_group_name: diff --git a/src/oci/identity/models/update_policy_details.py b/src/oci/identity/models/update_policy_details.py index 23702c5aab..a4ce9e5015 100644 --- a/src/oci/identity/models/update_policy_details.py +++ b/src/oci/identity/models/update_policy_details.py @@ -11,7 +11,7 @@ class UpdatePolicyDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdatePolicyDetails object with values from values from keyword arguments. + Initializes a new UpdatePolicyDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_saml2_identity_provider_details.py b/src/oci/identity/models/update_saml2_identity_provider_details.py index aeedf33d75..84963f7ed0 100644 --- a/src/oci/identity/models/update_saml2_identity_provider_details.py +++ b/src/oci/identity/models/update_saml2_identity_provider_details.py @@ -11,7 +11,7 @@ class UpdateSaml2IdentityProviderDetails(UpdateIdentityProviderDetails): def __init__(self, **kwargs): """ - Initializes a new UpdateSaml2IdentityProviderDetails object with values from values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.UpdateSaml2IdentityProviderDetails.protocol` attribute + Initializes a new UpdateSaml2IdentityProviderDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.identity.models.UpdateSaml2IdentityProviderDetails.protocol` attribute of this class is ``SAML2`` and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class): diff --git a/src/oci/identity/models/update_smtp_credential_details.py b/src/oci/identity/models/update_smtp_credential_details.py index 5d951dc055..61c6f7f9ab 100644 --- a/src/oci/identity/models/update_smtp_credential_details.py +++ b/src/oci/identity/models/update_smtp_credential_details.py @@ -11,7 +11,7 @@ class UpdateSmtpCredentialDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateSmtpCredentialDetails object with values from values from keyword arguments. + Initializes a new UpdateSmtpCredentialDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_state_details.py b/src/oci/identity/models/update_state_details.py index 1d73bba3df..2722d80040 100644 --- a/src/oci/identity/models/update_state_details.py +++ b/src/oci/identity/models/update_state_details.py @@ -11,7 +11,7 @@ class UpdateStateDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateStateDetails object with values from values from keyword arguments. + Initializes a new UpdateStateDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param blocked: diff --git a/src/oci/identity/models/update_swift_password_details.py b/src/oci/identity/models/update_swift_password_details.py index 97ccd3d557..5fecf8269a 100644 --- a/src/oci/identity/models/update_swift_password_details.py +++ b/src/oci/identity/models/update_swift_password_details.py @@ -11,7 +11,7 @@ class UpdateSwiftPasswordDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateSwiftPasswordDetails object with values from values from keyword arguments. + Initializes a new UpdateSwiftPasswordDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_tag_details.py b/src/oci/identity/models/update_tag_details.py index a94b60bf70..f20663addf 100644 --- a/src/oci/identity/models/update_tag_details.py +++ b/src/oci/identity/models/update_tag_details.py @@ -11,7 +11,7 @@ class UpdateTagDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateTagDetails object with values from values from keyword arguments. + Initializes a new UpdateTagDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_tag_namespace_details.py b/src/oci/identity/models/update_tag_namespace_details.py index 3e67a631e5..d20792d6cb 100644 --- a/src/oci/identity/models/update_tag_namespace_details.py +++ b/src/oci/identity/models/update_tag_namespace_details.py @@ -11,7 +11,7 @@ class UpdateTagNamespaceDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateTagNamespaceDetails object with values from values from keyword arguments. + Initializes a new UpdateTagNamespaceDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/update_user_details.py b/src/oci/identity/models/update_user_details.py index 382907bd50..0e57a246b1 100644 --- a/src/oci/identity/models/update_user_details.py +++ b/src/oci/identity/models/update_user_details.py @@ -11,7 +11,7 @@ class UpdateUserDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateUserDetails object with values from values from keyword arguments. + Initializes a new UpdateUserDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param description: diff --git a/src/oci/identity/models/user.py b/src/oci/identity/models/user.py index 350f3dd0fe..f38d03545a 100644 --- a/src/oci/identity/models/user.py +++ b/src/oci/identity/models/user.py @@ -11,7 +11,7 @@ class User(object): def __init__(self, **kwargs): """ - Initializes a new User object with values from values from keyword arguments. + Initializes a new User object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/identity/models/user_group_membership.py b/src/oci/identity/models/user_group_membership.py index d83e3503f6..2d93ed9db8 100644 --- a/src/oci/identity/models/user_group_membership.py +++ b/src/oci/identity/models/user_group_membership.py @@ -11,7 +11,7 @@ class UserGroupMembership(object): def __init__(self, **kwargs): """ - Initializes a new UserGroupMembership object with values from values from keyword arguments. + Initializes a new UserGroupMembership object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/load_balancer/load_balancer_client.py b/src/oci/load_balancer/load_balancer_client.py index 9917fe6f1b..ad50f4b574 100644 --- a/src/oci/load_balancer/load_balancer_client.py +++ b/src/oci/load_balancer/load_balancer_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("load_balancer", config, signer, load_balancer_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def create_backend(self, create_backend_details, load_balancer_id, backend_set_name, **kwargs): """ @@ -98,10 +99,14 @@ def create_backend(self, create_backend_details, load_balancer_id, backend_set_n } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -176,10 +181,14 @@ def create_backend_set(self, create_backend_set_details, load_balancer_id, **kwa } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -254,10 +263,14 @@ def create_certificate(self, create_certificate_details, load_balancer_id, **kwa } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -332,10 +345,14 @@ def create_listener(self, create_listener_details, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -426,10 +443,14 @@ def create_load_balancer(self, create_load_balancer_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -505,10 +526,14 @@ def create_path_route_set(self, create_path_route_set_details, load_balancer_id, } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -583,8 +608,12 @@ def delete_backend(self, load_balancer_id, backend_set_name, backend_name, **kwa } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -653,8 +682,12 @@ def delete_backend_set(self, load_balancer_id, backend_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -721,8 +754,12 @@ def delete_certificate(self, load_balancer_id, certificate_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -789,8 +826,12 @@ def delete_listener(self, load_balancer_id, listener_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -851,8 +892,12 @@ def delete_load_balancer(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -922,8 +967,12 @@ def delete_path_route_set(self, load_balancer_id, path_route_set_name, **kwargs) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -996,8 +1045,12 @@ def get_backend(self, load_balancer_id, backend_set_name, backend_name, **kwargs } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1072,8 +1125,12 @@ def get_backend_health(self, load_balancer_id, backend_set_name, backend_name, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1142,8 +1199,12 @@ def get_backend_set(self, load_balancer_id, backend_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1212,8 +1273,12 @@ def get_backend_set_health(self, load_balancer_id, backend_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1282,8 +1347,12 @@ def get_health_checker(self, load_balancer_id, backend_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1346,8 +1415,12 @@ def get_load_balancer(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1410,8 +1483,12 @@ def get_load_balancer_health(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1480,8 +1557,12 @@ def get_path_route_set(self, load_balancer_id, path_route_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1544,8 +1625,12 @@ def get_work_request(self, work_request_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1608,8 +1693,12 @@ def list_backend_sets(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1678,8 +1767,12 @@ def list_backends(self, load_balancer_id, backend_set_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1742,8 +1835,12 @@ def list_certificates(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1815,8 +1912,12 @@ def list_load_balancer_healths(self, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1943,8 +2044,12 @@ def list_load_balancers(self, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2008,8 +2113,12 @@ def list_path_route_sets(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2081,8 +2190,12 @@ def list_policies(self, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2154,8 +2267,12 @@ def list_protocols(self, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2227,8 +2344,12 @@ def list_shapes(self, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2309,8 +2430,12 @@ def list_work_requests(self, load_balancer_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2399,10 +2524,14 @@ def update_backend(self, update_backend_details, load_balancer_id, backend_set_n } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2483,10 +2612,14 @@ def update_backend_set(self, update_backend_set_details, load_balancer_id, backe } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2567,10 +2700,14 @@ def update_health_checker(self, health_checker, load_balancer_id, backend_set_na } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2651,10 +2788,14 @@ def update_listener(self, update_listener_details, load_balancer_id, listener_na } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2729,10 +2870,14 @@ def update_load_balancer(self, update_load_balancer_details, load_balancer_id, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2818,10 +2963,14 @@ def update_path_route_set(self, update_path_route_set_details, load_balancer_id, } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - if not isinstance(kwargs['retry_strategy'], retry.NoneRetryStrategy): + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): self.base_client.add_opc_retry_token_if_needed(header_params) - return kwargs['retry_strategy'].make_retrying_call( + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/load_balancer/models/backend.py b/src/oci/load_balancer/models/backend.py index a23603c258..4b4ac4aa9f 100644 --- a/src/oci/load_balancer/models/backend.py +++ b/src/oci/load_balancer/models/backend.py @@ -11,7 +11,7 @@ class Backend(object): def __init__(self, **kwargs): """ - Initializes a new Backend object with values from values from keyword arguments. + Initializes a new Backend object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup: diff --git a/src/oci/load_balancer/models/backend_details.py b/src/oci/load_balancer/models/backend_details.py index 5f243300e0..538eaac840 100644 --- a/src/oci/load_balancer/models/backend_details.py +++ b/src/oci/load_balancer/models/backend_details.py @@ -11,7 +11,7 @@ class BackendDetails(object): def __init__(self, **kwargs): """ - Initializes a new BackendDetails object with values from values from keyword arguments. + Initializes a new BackendDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup: diff --git a/src/oci/load_balancer/models/backend_health.py b/src/oci/load_balancer/models/backend_health.py index 18e1ab4ff7..4b7377e6a2 100644 --- a/src/oci/load_balancer/models/backend_health.py +++ b/src/oci/load_balancer/models/backend_health.py @@ -11,7 +11,7 @@ class BackendHealth(object): def __init__(self, **kwargs): """ - Initializes a new BackendHealth object with values from values from keyword arguments. + Initializes a new BackendHealth object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param health_check_results: diff --git a/src/oci/load_balancer/models/backend_set.py b/src/oci/load_balancer/models/backend_set.py index 81ea184306..e69218c181 100644 --- a/src/oci/load_balancer/models/backend_set.py +++ b/src/oci/load_balancer/models/backend_set.py @@ -11,7 +11,7 @@ class BackendSet(object): def __init__(self, **kwargs): """ - Initializes a new BackendSet object with values from values from keyword arguments. + Initializes a new BackendSet object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backends: diff --git a/src/oci/load_balancer/models/backend_set_details.py b/src/oci/load_balancer/models/backend_set_details.py index 52e68f5451..e2ed497cb9 100644 --- a/src/oci/load_balancer/models/backend_set_details.py +++ b/src/oci/load_balancer/models/backend_set_details.py @@ -11,7 +11,7 @@ class BackendSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new BackendSetDetails object with values from values from keyword arguments. + Initializes a new BackendSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backends: diff --git a/src/oci/load_balancer/models/backend_set_health.py b/src/oci/load_balancer/models/backend_set_health.py index dbd9f81e19..f76e86c776 100644 --- a/src/oci/load_balancer/models/backend_set_health.py +++ b/src/oci/load_balancer/models/backend_set_health.py @@ -11,7 +11,7 @@ class BackendSetHealth(object): def __init__(self, **kwargs): """ - Initializes a new BackendSetHealth object with values from values from keyword arguments. + Initializes a new BackendSetHealth object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param critical_state_backend_names: diff --git a/src/oci/load_balancer/models/certificate.py b/src/oci/load_balancer/models/certificate.py index 9013e138db..0badd3039b 100644 --- a/src/oci/load_balancer/models/certificate.py +++ b/src/oci/load_balancer/models/certificate.py @@ -11,7 +11,7 @@ class Certificate(object): def __init__(self, **kwargs): """ - Initializes a new Certificate object with values from values from keyword arguments. + Initializes a new Certificate object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ca_certificate: diff --git a/src/oci/load_balancer/models/certificate_details.py b/src/oci/load_balancer/models/certificate_details.py index 20510285a9..4197e8bfee 100644 --- a/src/oci/load_balancer/models/certificate_details.py +++ b/src/oci/load_balancer/models/certificate_details.py @@ -11,7 +11,7 @@ class CertificateDetails(object): def __init__(self, **kwargs): """ - Initializes a new CertificateDetails object with values from values from keyword arguments. + Initializes a new CertificateDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ca_certificate: diff --git a/src/oci/load_balancer/models/connection_configuration.py b/src/oci/load_balancer/models/connection_configuration.py index 632ec60122..a78efd699f 100644 --- a/src/oci/load_balancer/models/connection_configuration.py +++ b/src/oci/load_balancer/models/connection_configuration.py @@ -11,7 +11,7 @@ class ConnectionConfiguration(object): def __init__(self, **kwargs): """ - Initializes a new ConnectionConfiguration object with values from values from keyword arguments. + Initializes a new ConnectionConfiguration object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param idle_timeout: diff --git a/src/oci/load_balancer/models/create_backend_details.py b/src/oci/load_balancer/models/create_backend_details.py index 96a1e70839..f25d9f5c61 100644 --- a/src/oci/load_balancer/models/create_backend_details.py +++ b/src/oci/load_balancer/models/create_backend_details.py @@ -11,7 +11,7 @@ class CreateBackendDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateBackendDetails object with values from values from keyword arguments. + Initializes a new CreateBackendDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup: diff --git a/src/oci/load_balancer/models/create_backend_set_details.py b/src/oci/load_balancer/models/create_backend_set_details.py index ff40e71c70..27dc0d3532 100644 --- a/src/oci/load_balancer/models/create_backend_set_details.py +++ b/src/oci/load_balancer/models/create_backend_set_details.py @@ -11,7 +11,7 @@ class CreateBackendSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateBackendSetDetails object with values from values from keyword arguments. + Initializes a new CreateBackendSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backends: diff --git a/src/oci/load_balancer/models/create_certificate_details.py b/src/oci/load_balancer/models/create_certificate_details.py index cd912580bd..f8c0f87b7a 100644 --- a/src/oci/load_balancer/models/create_certificate_details.py +++ b/src/oci/load_balancer/models/create_certificate_details.py @@ -11,7 +11,7 @@ class CreateCertificateDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateCertificateDetails object with values from values from keyword arguments. + Initializes a new CreateCertificateDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ca_certificate: diff --git a/src/oci/load_balancer/models/create_listener_details.py b/src/oci/load_balancer/models/create_listener_details.py index 215611018b..c1d088fc24 100644 --- a/src/oci/load_balancer/models/create_listener_details.py +++ b/src/oci/load_balancer/models/create_listener_details.py @@ -11,7 +11,7 @@ class CreateListenerDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateListenerDetails object with values from values from keyword arguments. + Initializes a new CreateListenerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param connection_configuration: diff --git a/src/oci/load_balancer/models/create_load_balancer_details.py b/src/oci/load_balancer/models/create_load_balancer_details.py index ec9f19e0b3..61c41e1ba6 100644 --- a/src/oci/load_balancer/models/create_load_balancer_details.py +++ b/src/oci/load_balancer/models/create_load_balancer_details.py @@ -11,7 +11,7 @@ class CreateLoadBalancerDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateLoadBalancerDetails object with values from values from keyword arguments. + Initializes a new CreateLoadBalancerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backend_sets: diff --git a/src/oci/load_balancer/models/create_path_route_set_details.py b/src/oci/load_balancer/models/create_path_route_set_details.py index f78ab78edc..362fbac5fd 100644 --- a/src/oci/load_balancer/models/create_path_route_set_details.py +++ b/src/oci/load_balancer/models/create_path_route_set_details.py @@ -11,7 +11,7 @@ class CreatePathRouteSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreatePathRouteSetDetails object with values from values from keyword arguments. + Initializes a new CreatePathRouteSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/load_balancer/models/health_check_result.py b/src/oci/load_balancer/models/health_check_result.py index 86d395faf3..117defa090 100644 --- a/src/oci/load_balancer/models/health_check_result.py +++ b/src/oci/load_balancer/models/health_check_result.py @@ -11,7 +11,7 @@ class HealthCheckResult(object): def __init__(self, **kwargs): """ - Initializes a new HealthCheckResult object with values from values from keyword arguments. + Initializes a new HealthCheckResult object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param health_check_status: diff --git a/src/oci/load_balancer/models/health_checker.py b/src/oci/load_balancer/models/health_checker.py index 8a9e53a646..93dc235301 100644 --- a/src/oci/load_balancer/models/health_checker.py +++ b/src/oci/load_balancer/models/health_checker.py @@ -11,7 +11,7 @@ class HealthChecker(object): def __init__(self, **kwargs): """ - Initializes a new HealthChecker object with values from values from keyword arguments. + Initializes a new HealthChecker object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param interval_in_millis: diff --git a/src/oci/load_balancer/models/health_checker_details.py b/src/oci/load_balancer/models/health_checker_details.py index a85d29cbe4..182c947206 100644 --- a/src/oci/load_balancer/models/health_checker_details.py +++ b/src/oci/load_balancer/models/health_checker_details.py @@ -11,7 +11,7 @@ class HealthCheckerDetails(object): def __init__(self, **kwargs): """ - Initializes a new HealthCheckerDetails object with values from values from keyword arguments. + Initializes a new HealthCheckerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param interval_in_millis: diff --git a/src/oci/load_balancer/models/ip_address.py b/src/oci/load_balancer/models/ip_address.py index 63ebf596b6..62739a1489 100644 --- a/src/oci/load_balancer/models/ip_address.py +++ b/src/oci/load_balancer/models/ip_address.py @@ -11,7 +11,7 @@ class IpAddress(object): def __init__(self, **kwargs): """ - Initializes a new IpAddress object with values from values from keyword arguments. + Initializes a new IpAddress object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param ip_address: diff --git a/src/oci/load_balancer/models/listener.py b/src/oci/load_balancer/models/listener.py index 16c19c2611..394e652953 100644 --- a/src/oci/load_balancer/models/listener.py +++ b/src/oci/load_balancer/models/listener.py @@ -11,7 +11,7 @@ class Listener(object): def __init__(self, **kwargs): """ - Initializes a new Listener object with values from values from keyword arguments. + Initializes a new Listener object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param connection_configuration: diff --git a/src/oci/load_balancer/models/listener_details.py b/src/oci/load_balancer/models/listener_details.py index 677fe50ddf..7672a8e24d 100644 --- a/src/oci/load_balancer/models/listener_details.py +++ b/src/oci/load_balancer/models/listener_details.py @@ -11,7 +11,7 @@ class ListenerDetails(object): def __init__(self, **kwargs): """ - Initializes a new ListenerDetails object with values from values from keyword arguments. + Initializes a new ListenerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param connection_configuration: diff --git a/src/oci/load_balancer/models/load_balancer.py b/src/oci/load_balancer/models/load_balancer.py index ddf0d678e9..1124cdde60 100644 --- a/src/oci/load_balancer/models/load_balancer.py +++ b/src/oci/load_balancer/models/load_balancer.py @@ -11,7 +11,7 @@ class LoadBalancer(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancer object with values from values from keyword arguments. + Initializes a new LoadBalancer object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backend_sets: diff --git a/src/oci/load_balancer/models/load_balancer_health.py b/src/oci/load_balancer/models/load_balancer_health.py index 085c08344d..ed2965cbf6 100644 --- a/src/oci/load_balancer/models/load_balancer_health.py +++ b/src/oci/load_balancer/models/load_balancer_health.py @@ -11,7 +11,7 @@ class LoadBalancerHealth(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancerHealth object with values from values from keyword arguments. + Initializes a new LoadBalancerHealth object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param critical_state_backend_set_names: diff --git a/src/oci/load_balancer/models/load_balancer_health_summary.py b/src/oci/load_balancer/models/load_balancer_health_summary.py index 356bb9ae77..96fba21021 100644 --- a/src/oci/load_balancer/models/load_balancer_health_summary.py +++ b/src/oci/load_balancer/models/load_balancer_health_summary.py @@ -11,7 +11,7 @@ class LoadBalancerHealthSummary(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancerHealthSummary object with values from values from keyword arguments. + Initializes a new LoadBalancerHealthSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param load_balancer_id: diff --git a/src/oci/load_balancer/models/load_balancer_policy.py b/src/oci/load_balancer/models/load_balancer_policy.py index 3ff8d644f3..76842c0993 100644 --- a/src/oci/load_balancer/models/load_balancer_policy.py +++ b/src/oci/load_balancer/models/load_balancer_policy.py @@ -11,7 +11,7 @@ class LoadBalancerPolicy(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancerPolicy object with values from values from keyword arguments. + Initializes a new LoadBalancerPolicy object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/load_balancer/models/load_balancer_protocol.py b/src/oci/load_balancer/models/load_balancer_protocol.py index 2ba0c3e482..9efa321b69 100644 --- a/src/oci/load_balancer/models/load_balancer_protocol.py +++ b/src/oci/load_balancer/models/load_balancer_protocol.py @@ -11,7 +11,7 @@ class LoadBalancerProtocol(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancerProtocol object with values from values from keyword arguments. + Initializes a new LoadBalancerProtocol object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/load_balancer/models/load_balancer_shape.py b/src/oci/load_balancer/models/load_balancer_shape.py index 8e708d2660..cab0318964 100644 --- a/src/oci/load_balancer/models/load_balancer_shape.py +++ b/src/oci/load_balancer/models/load_balancer_shape.py @@ -11,7 +11,7 @@ class LoadBalancerShape(object): def __init__(self, **kwargs): """ - Initializes a new LoadBalancerShape object with values from values from keyword arguments. + Initializes a new LoadBalancerShape object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/load_balancer/models/path_match_type.py b/src/oci/load_balancer/models/path_match_type.py index 0b8a9fd409..389ac34d5f 100644 --- a/src/oci/load_balancer/models/path_match_type.py +++ b/src/oci/load_balancer/models/path_match_type.py @@ -11,7 +11,7 @@ class PathMatchType(object): def __init__(self, **kwargs): """ - Initializes a new PathMatchType object with values from values from keyword arguments. + Initializes a new PathMatchType object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param match_type: diff --git a/src/oci/load_balancer/models/path_route.py b/src/oci/load_balancer/models/path_route.py index ee2e5b6732..9ea99a251a 100644 --- a/src/oci/load_balancer/models/path_route.py +++ b/src/oci/load_balancer/models/path_route.py @@ -11,7 +11,7 @@ class PathRoute(object): def __init__(self, **kwargs): """ - Initializes a new PathRoute object with values from values from keyword arguments. + Initializes a new PathRoute object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backend_set_name: diff --git a/src/oci/load_balancer/models/path_route_set.py b/src/oci/load_balancer/models/path_route_set.py index 55fc6b7340..c4ca81b7dd 100644 --- a/src/oci/load_balancer/models/path_route_set.py +++ b/src/oci/load_balancer/models/path_route_set.py @@ -11,7 +11,7 @@ class PathRouteSet(object): def __init__(self, **kwargs): """ - Initializes a new PathRouteSet object with values from values from keyword arguments. + Initializes a new PathRouteSet object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/load_balancer/models/path_route_set_details.py b/src/oci/load_balancer/models/path_route_set_details.py index 95613c73af..fccaeef1e6 100644 --- a/src/oci/load_balancer/models/path_route_set_details.py +++ b/src/oci/load_balancer/models/path_route_set_details.py @@ -11,7 +11,7 @@ class PathRouteSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new PathRouteSetDetails object with values from values from keyword arguments. + Initializes a new PathRouteSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param path_routes: diff --git a/src/oci/load_balancer/models/session_persistence_configuration_details.py b/src/oci/load_balancer/models/session_persistence_configuration_details.py index c7b844762b..8760e65122 100644 --- a/src/oci/load_balancer/models/session_persistence_configuration_details.py +++ b/src/oci/load_balancer/models/session_persistence_configuration_details.py @@ -11,7 +11,7 @@ class SessionPersistenceConfigurationDetails(object): def __init__(self, **kwargs): """ - Initializes a new SessionPersistenceConfigurationDetails object with values from values from keyword arguments. + Initializes a new SessionPersistenceConfigurationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param cookie_name: diff --git a/src/oci/load_balancer/models/ssl_configuration.py b/src/oci/load_balancer/models/ssl_configuration.py index 844db10274..bc980b48a1 100644 --- a/src/oci/load_balancer/models/ssl_configuration.py +++ b/src/oci/load_balancer/models/ssl_configuration.py @@ -11,7 +11,7 @@ class SSLConfiguration(object): def __init__(self, **kwargs): """ - Initializes a new SSLConfiguration object with values from values from keyword arguments. + Initializes a new SSLConfiguration object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param certificate_name: diff --git a/src/oci/load_balancer/models/ssl_configuration_details.py b/src/oci/load_balancer/models/ssl_configuration_details.py index e889461524..34b237290e 100644 --- a/src/oci/load_balancer/models/ssl_configuration_details.py +++ b/src/oci/load_balancer/models/ssl_configuration_details.py @@ -11,7 +11,7 @@ class SSLConfigurationDetails(object): def __init__(self, **kwargs): """ - Initializes a new SSLConfigurationDetails object with values from values from keyword arguments. + Initializes a new SSLConfigurationDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param certificate_name: diff --git a/src/oci/load_balancer/models/update_backend_details.py b/src/oci/load_balancer/models/update_backend_details.py index 1edecb683b..6b16ce90bb 100644 --- a/src/oci/load_balancer/models/update_backend_details.py +++ b/src/oci/load_balancer/models/update_backend_details.py @@ -11,7 +11,7 @@ class UpdateBackendDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateBackendDetails object with values from values from keyword arguments. + Initializes a new UpdateBackendDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backup: diff --git a/src/oci/load_balancer/models/update_backend_set_details.py b/src/oci/load_balancer/models/update_backend_set_details.py index 9e7569b4d8..ad42225c18 100644 --- a/src/oci/load_balancer/models/update_backend_set_details.py +++ b/src/oci/load_balancer/models/update_backend_set_details.py @@ -11,7 +11,7 @@ class UpdateBackendSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateBackendSetDetails object with values from values from keyword arguments. + Initializes a new UpdateBackendSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param backends: diff --git a/src/oci/load_balancer/models/update_health_checker_details.py b/src/oci/load_balancer/models/update_health_checker_details.py index ab220289c2..a9b66cabb1 100644 --- a/src/oci/load_balancer/models/update_health_checker_details.py +++ b/src/oci/load_balancer/models/update_health_checker_details.py @@ -11,7 +11,7 @@ class UpdateHealthCheckerDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateHealthCheckerDetails object with values from values from keyword arguments. + Initializes a new UpdateHealthCheckerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param interval_in_millis: diff --git a/src/oci/load_balancer/models/update_listener_details.py b/src/oci/load_balancer/models/update_listener_details.py index 30d40f3f3a..faaefe16b6 100644 --- a/src/oci/load_balancer/models/update_listener_details.py +++ b/src/oci/load_balancer/models/update_listener_details.py @@ -11,7 +11,7 @@ class UpdateListenerDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateListenerDetails object with values from values from keyword arguments. + Initializes a new UpdateListenerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param connection_configuration: diff --git a/src/oci/load_balancer/models/update_load_balancer_details.py b/src/oci/load_balancer/models/update_load_balancer_details.py index 7b4d8d016d..99db90c32d 100644 --- a/src/oci/load_balancer/models/update_load_balancer_details.py +++ b/src/oci/load_balancer/models/update_load_balancer_details.py @@ -11,7 +11,7 @@ class UpdateLoadBalancerDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateLoadBalancerDetails object with values from values from keyword arguments. + Initializes a new UpdateLoadBalancerDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param display_name: diff --git a/src/oci/load_balancer/models/update_path_route_set_details.py b/src/oci/load_balancer/models/update_path_route_set_details.py index 53fd9dfcc9..dc67ad4e3e 100644 --- a/src/oci/load_balancer/models/update_path_route_set_details.py +++ b/src/oci/load_balancer/models/update_path_route_set_details.py @@ -11,7 +11,7 @@ class UpdatePathRouteSetDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdatePathRouteSetDetails object with values from values from keyword arguments. + Initializes a new UpdatePathRouteSetDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param path_routes: diff --git a/src/oci/load_balancer/models/work_request.py b/src/oci/load_balancer/models/work_request.py index 26f9fb3df9..f679adf38b 100644 --- a/src/oci/load_balancer/models/work_request.py +++ b/src/oci/load_balancer/models/work_request.py @@ -11,7 +11,7 @@ class WorkRequest(object): def __init__(self, **kwargs): """ - Initializes a new WorkRequest object with values from values from keyword arguments. + Initializes a new WorkRequest object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param error_details: diff --git a/src/oci/load_balancer/models/work_request_error.py b/src/oci/load_balancer/models/work_request_error.py index 234e5f963b..bf555e26c3 100644 --- a/src/oci/load_balancer/models/work_request_error.py +++ b/src/oci/load_balancer/models/work_request_error.py @@ -11,7 +11,7 @@ class WorkRequestError(object): def __init__(self, **kwargs): """ - Initializes a new WorkRequestError object with values from values from keyword arguments. + Initializes a new WorkRequestError object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param error_code: diff --git a/src/oci/object_storage/models/bucket.py b/src/oci/object_storage/models/bucket.py index 5faf594fdd..f7984c5475 100644 --- a/src/oci/object_storage/models/bucket.py +++ b/src/oci/object_storage/models/bucket.py @@ -11,7 +11,7 @@ class Bucket(object): def __init__(self, **kwargs): """ - Initializes a new Bucket object with values from values from keyword arguments. + Initializes a new Bucket object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param namespace: diff --git a/src/oci/object_storage/models/bucket_summary.py b/src/oci/object_storage/models/bucket_summary.py index 6eae66ba30..3836e9c60a 100644 --- a/src/oci/object_storage/models/bucket_summary.py +++ b/src/oci/object_storage/models/bucket_summary.py @@ -11,7 +11,7 @@ class BucketSummary(object): def __init__(self, **kwargs): """ - Initializes a new BucketSummary object with values from values from keyword arguments. + Initializes a new BucketSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param namespace: diff --git a/src/oci/object_storage/models/commit_multipart_upload_details.py b/src/oci/object_storage/models/commit_multipart_upload_details.py index 0d13a06678..4cd5598be6 100644 --- a/src/oci/object_storage/models/commit_multipart_upload_details.py +++ b/src/oci/object_storage/models/commit_multipart_upload_details.py @@ -11,7 +11,7 @@ class CommitMultipartUploadDetails(object): def __init__(self, **kwargs): """ - Initializes a new CommitMultipartUploadDetails object with values from values from keyword arguments. + Initializes a new CommitMultipartUploadDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param parts_to_commit: diff --git a/src/oci/object_storage/models/commit_multipart_upload_part_details.py b/src/oci/object_storage/models/commit_multipart_upload_part_details.py index 3f9b54db08..6cf1594d8f 100644 --- a/src/oci/object_storage/models/commit_multipart_upload_part_details.py +++ b/src/oci/object_storage/models/commit_multipart_upload_part_details.py @@ -11,7 +11,7 @@ class CommitMultipartUploadPartDetails(object): def __init__(self, **kwargs): """ - Initializes a new CommitMultipartUploadPartDetails object with values from values from keyword arguments. + Initializes a new CommitMultipartUploadPartDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param part_num: diff --git a/src/oci/object_storage/models/create_bucket_details.py b/src/oci/object_storage/models/create_bucket_details.py index 5b0f4d4461..d24c9429ba 100644 --- a/src/oci/object_storage/models/create_bucket_details.py +++ b/src/oci/object_storage/models/create_bucket_details.py @@ -11,7 +11,7 @@ class CreateBucketDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateBucketDetails object with values from values from keyword arguments. + Initializes a new CreateBucketDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/object_storage/models/create_multipart_upload_details.py b/src/oci/object_storage/models/create_multipart_upload_details.py index 81629bfd13..e8968041e8 100644 --- a/src/oci/object_storage/models/create_multipart_upload_details.py +++ b/src/oci/object_storage/models/create_multipart_upload_details.py @@ -11,7 +11,7 @@ class CreateMultipartUploadDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreateMultipartUploadDetails object with values from values from keyword arguments. + Initializes a new CreateMultipartUploadDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param object: diff --git a/src/oci/object_storage/models/create_preauthenticated_request_details.py b/src/oci/object_storage/models/create_preauthenticated_request_details.py index 0f95bcd5cd..c25d482bd7 100644 --- a/src/oci/object_storage/models/create_preauthenticated_request_details.py +++ b/src/oci/object_storage/models/create_preauthenticated_request_details.py @@ -11,7 +11,7 @@ class CreatePreauthenticatedRequestDetails(object): def __init__(self, **kwargs): """ - Initializes a new CreatePreauthenticatedRequestDetails object with values from values from keyword arguments. + Initializes a new CreatePreauthenticatedRequestDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/object_storage/models/list_objects.py b/src/oci/object_storage/models/list_objects.py index 63491e0084..da4934a79c 100644 --- a/src/oci/object_storage/models/list_objects.py +++ b/src/oci/object_storage/models/list_objects.py @@ -11,7 +11,7 @@ class ListObjects(object): def __init__(self, **kwargs): """ - Initializes a new ListObjects object with values from values from keyword arguments. + Initializes a new ListObjects object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param objects: diff --git a/src/oci/object_storage/models/multipart_upload.py b/src/oci/object_storage/models/multipart_upload.py index 2accc992a8..5cefa729a3 100644 --- a/src/oci/object_storage/models/multipart_upload.py +++ b/src/oci/object_storage/models/multipart_upload.py @@ -11,7 +11,7 @@ class MultipartUpload(object): def __init__(self, **kwargs): """ - Initializes a new MultipartUpload object with values from values from keyword arguments. + Initializes a new MultipartUpload object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param namespace: diff --git a/src/oci/object_storage/models/multipart_upload_part_summary.py b/src/oci/object_storage/models/multipart_upload_part_summary.py index 3425c456ea..321b79015d 100644 --- a/src/oci/object_storage/models/multipart_upload_part_summary.py +++ b/src/oci/object_storage/models/multipart_upload_part_summary.py @@ -11,7 +11,7 @@ class MultipartUploadPartSummary(object): def __init__(self, **kwargs): """ - Initializes a new MultipartUploadPartSummary object with values from values from keyword arguments. + Initializes a new MultipartUploadPartSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param etag: diff --git a/src/oci/object_storage/models/namespace_metadata.py b/src/oci/object_storage/models/namespace_metadata.py index b5adb72d97..37cf12a153 100644 --- a/src/oci/object_storage/models/namespace_metadata.py +++ b/src/oci/object_storage/models/namespace_metadata.py @@ -11,7 +11,7 @@ class NamespaceMetadata(object): def __init__(self, **kwargs): """ - Initializes a new NamespaceMetadata object with values from values from keyword arguments. + Initializes a new NamespaceMetadata object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param namespace: diff --git a/src/oci/object_storage/models/object_summary.py b/src/oci/object_storage/models/object_summary.py index 795668e570..356b6eb417 100644 --- a/src/oci/object_storage/models/object_summary.py +++ b/src/oci/object_storage/models/object_summary.py @@ -11,7 +11,7 @@ class ObjectSummary(object): def __init__(self, **kwargs): """ - Initializes a new ObjectSummary object with values from values from keyword arguments. + Initializes a new ObjectSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param name: diff --git a/src/oci/object_storage/models/preauthenticated_request.py b/src/oci/object_storage/models/preauthenticated_request.py index 864708eb78..d93f7891cc 100644 --- a/src/oci/object_storage/models/preauthenticated_request.py +++ b/src/oci/object_storage/models/preauthenticated_request.py @@ -11,7 +11,7 @@ class PreauthenticatedRequest(object): def __init__(self, **kwargs): """ - Initializes a new PreauthenticatedRequest object with values from values from keyword arguments. + Initializes a new PreauthenticatedRequest object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/object_storage/models/preauthenticated_request_summary.py b/src/oci/object_storage/models/preauthenticated_request_summary.py index 432f9d39d1..248b9d4437 100644 --- a/src/oci/object_storage/models/preauthenticated_request_summary.py +++ b/src/oci/object_storage/models/preauthenticated_request_summary.py @@ -11,7 +11,7 @@ class PreauthenticatedRequestSummary(object): def __init__(self, **kwargs): """ - Initializes a new PreauthenticatedRequestSummary object with values from values from keyword arguments. + Initializes a new PreauthenticatedRequestSummary object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param id: diff --git a/src/oci/object_storage/models/rename_object_details.py b/src/oci/object_storage/models/rename_object_details.py index 66ec5a3ff4..a7f7d53ffc 100644 --- a/src/oci/object_storage/models/rename_object_details.py +++ b/src/oci/object_storage/models/rename_object_details.py @@ -11,7 +11,7 @@ class RenameObjectDetails(object): def __init__(self, **kwargs): """ - Initializes a new RenameObjectDetails object with values from values from keyword arguments. + Initializes a new RenameObjectDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param source_name: diff --git a/src/oci/object_storage/models/restore_objects_details.py b/src/oci/object_storage/models/restore_objects_details.py index d4252c1c76..bc97bfb9b7 100644 --- a/src/oci/object_storage/models/restore_objects_details.py +++ b/src/oci/object_storage/models/restore_objects_details.py @@ -11,7 +11,7 @@ class RestoreObjectsDetails(object): def __init__(self, **kwargs): """ - Initializes a new RestoreObjectsDetails object with values from values from keyword arguments. + Initializes a new RestoreObjectsDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param object_name: diff --git a/src/oci/object_storage/models/update_bucket_details.py b/src/oci/object_storage/models/update_bucket_details.py index 16e6548f44..94c019a793 100644 --- a/src/oci/object_storage/models/update_bucket_details.py +++ b/src/oci/object_storage/models/update_bucket_details.py @@ -11,7 +11,7 @@ class UpdateBucketDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateBucketDetails object with values from values from keyword arguments. + Initializes a new UpdateBucketDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param namespace: diff --git a/src/oci/object_storage/models/update_namespace_metadata_details.py b/src/oci/object_storage/models/update_namespace_metadata_details.py index 1c045cc71b..8604b038a2 100644 --- a/src/oci/object_storage/models/update_namespace_metadata_details.py +++ b/src/oci/object_storage/models/update_namespace_metadata_details.py @@ -11,7 +11,7 @@ class UpdateNamespaceMetadataDetails(object): def __init__(self, **kwargs): """ - Initializes a new UpdateNamespaceMetadataDetails object with values from values from keyword arguments. + Initializes a new UpdateNamespaceMetadataDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): :param default_s3_compartment_id: diff --git a/src/oci/object_storage/object_storage_client.py b/src/oci/object_storage/object_storage_client.py index 5cd6a9f05d..f644b6abab 100644 --- a/src/oci/object_storage/object_storage_client.py +++ b/src/oci/object_storage/object_storage_client.py @@ -31,6 +31,7 @@ def __init__(self, config, **kwargs): private_key_content=config.get("key_content") ) self.base_client = BaseClient("object_storage", config, signer, object_storage_type_mapping) + self.retry_strategy = kwargs.get('retry_strategy') def abort_multipart_upload(self, namespace_name, bucket_name, object_name, upload_id, **kwargs): """ @@ -95,8 +96,12 @@ def abort_multipart_upload(self, namespace_name, bucket_name, object_name, uploa } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -189,8 +194,12 @@ def commit_multipart_upload(self, namespace_name, bucket_name, object_name, uplo } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -255,8 +264,12 @@ def create_bucket(self, namespace_name, create_bucket_details, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -338,8 +351,12 @@ def create_multipart_upload(self, namespace_name, bucket_name, create_multipart_ } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -409,8 +426,12 @@ def create_preauthenticated_request(self, namespace_name, bucket_name, create_pr } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -483,8 +504,12 @@ def delete_bucket(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -558,8 +583,12 @@ def delete_object(self, namespace_name, bucket_name, object_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -627,8 +656,12 @@ def delete_preauthenticated_request(self, namespace_name, bucket_name, par_id, * } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -703,8 +736,12 @@ def get_bucket(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -752,8 +789,12 @@ def get_namespace(self, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -816,8 +857,12 @@ def get_namespace_metadata(self, namespace_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -907,8 +952,12 @@ def get_object(self, namespace_name, bucket_name, object_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -978,8 +1027,12 @@ def get_preauthenticated_request(self, namespace_name, bucket_name, par_id, **kw } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1056,8 +1109,12 @@ def head_bucket(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1137,8 +1194,12 @@ def head_object(self, namespace_name, bucket_name, object_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1238,8 +1299,12 @@ def list_buckets(self, namespace_name, compartment_id, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1329,8 +1394,12 @@ def list_multipart_upload_parts(self, namespace_name, bucket_name, object_name, } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1411,8 +1480,12 @@ def list_multipart_uploads(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1528,8 +1601,12 @@ def list_objects(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1615,8 +1692,12 @@ def list_preauthenticated_requests(self, namespace_name, bucket_name, **kwargs): } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1747,8 +1828,12 @@ def put_object(self, namespace_name, bucket_name, object_name, put_object_body, if requests.utils.super_len(put_object_body) == 0: header_params['Content-Length'] = '0' + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1818,8 +1903,12 @@ def rename_object(self, namespace_name, bucket_name, rename_object_details, **kw } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1888,8 +1977,12 @@ def restore_objects(self, namespace_name, bucket_name, restore_objects_details, } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -1963,8 +2056,12 @@ def update_bucket(self, namespace_name, bucket_name, update_bucket_details, **kw } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2032,8 +2129,12 @@ def update_namespace_metadata(self, namespace_name, update_namespace_metadata_de } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing} + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, @@ -2154,8 +2255,12 @@ def upload_part(self, namespace_name, bucket_name, object_name, upload_id, uploa if requests.utils.super_len(upload_part_body) == 0: header_params['Content-Length'] = '0' + retry_strategy = self.retry_strategy if kwargs.get('retry_strategy'): - return kwargs['retry_strategy'].make_retrying_call( + retry_strategy = kwargs.get('retry_strategy') + + if retry_strategy: + return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, diff --git a/src/oci/regions.py b/src/oci/regions.py index ddfd74be3a..2f36abaa43 100644 --- a/src/oci/regions.py +++ b/src/oci/regions.py @@ -6,12 +6,14 @@ REGIONS_SHORT_NAMES = { 'phx': 'us-phoenix-1', 'iad': 'us-ashburn-1', - 'fra': 'eu-frankfurt-1' + 'fra': 'eu-frankfurt-1', + 'lhr': 'uk-london-1' } REGIONS = [ "us-phoenix-1", "us-ashburn-1", - "eu-frankfurt-1" + "eu-frankfurt-1", + "uk-london-1" ] SERVICE_ENDPOINTS = service_endpoints.SERVICE_ENDPOINTS SERVICE_ENDPOINTS['auth'] = 'https://auth.{domain}' diff --git a/src/oci/retry/retry.py b/src/oci/retry/retry.py index b510d9e01b..015a076bff 100644 --- a/src/oci/retry/retry.py +++ b/src/oci/retry/retry.py @@ -202,7 +202,7 @@ def get_retry_strategy(self): checker_container=checker_container ) else: - raise RuntimeError('Unrecognized backup type: {}. Expected one of: {}'.format(self.backoff_type, VALID_BACKOFF_TYPES)) + raise ValueError('Unrecognized backoff type: {}. Expected one of: {}'.format(self.backoff_type, VALID_BACKOFF_TYPES)) class NoneRetryStrategy(object): diff --git a/src/oci/version.py b/src/oci/version.py index e6eb13ed95..938cb74886 100644 --- a/src/oci/version.py +++ b/src/oci/version.py @@ -1,4 +1,4 @@ # coding: utf-8 # Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. -__version__ = "1.3.16" +__version__ = "1.3.17" diff --git a/tests/util.py b/tests/util.py index 396120e78f..3251808dca 100644 --- a/tests/util.py +++ b/tests/util.py @@ -64,8 +64,12 @@ def validate_service_error(error, status, code, message): assert error.code == code assert error.message.startswith(message) assert error.headers is not None - assert error.headers.get('opc-request-id') is not None - assert len(error.headers.get('opc-request-id')) == 98 + assert error.request_id.strip() + + if error.headers.get('opc-request-id'): + assert len(error.headers.get('opc-request-id')) == 98 + else: + assert len(error.request_id) == 32 # Check to string for info in [str(status), code, "opc-request-id", message]: